Subject: Re: sendmail problems
To: Steven M. Bellovin <smb@cs.columbia.edu>
From: Jan Danielsson <jan.m.danielsson@gmail.com>
List: netbsd-users
Date: 02/04/2007 10:43:28
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enigC51A4B2841E627D47D72C340
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Steven M. Bellovin wrote:
[---]
> You can do several things. (I understand your problem; I had analogous=
> issues with some old scripts of mine.)
>=20
> First option -- rewrite your script. Sed is the easy way to do certain=
> things, but with a bit of effort you can use shell, expr, and/or ed
> instead. (You may also need to mount /tmp early or create something
> like /var/tmp as a temporary file place.
This is probably what I really *want* to do. I like the idea of being
able to learn the "low level" tools so I don't have to rely on high
level tools like Python or Perl. Actually, I thought that was what I was
doing when I decided to use "sed". :-)
I have found that /bin/sh does have some pretty nifty parsing
functions. Hm... expr.. I hadn't thought of it. I used it to add two
numbers once, but other than that.. Neat!
> Second -- change your /etc/rc.conf file to add /usr to
> critical_filesystems_local -- see /etc/defaults/rc.conf for details.
> This is probably the easiest solution for folks who don't
> mount /usr via NFS. (Alternatively, you could edit the REQUIRES: line
> in /etc/rc.d/dhclient so that it invokes mountcritremote first. But
> that might cause a dependency loop; I haven't tried it.)
This was what I decided to do -- for now. I added /usr to
critical_filesystems_local, as suggested by Geert Hendrickx, and it works=
=2E
I should probably sit down and go through the rc system once and for
all. This isn't the first time I'm positively surprised by how simple
things are to do with it.
> Third -- and this depends on why you need your ISP's notion of your
> hostname -- get your own domain, and use DNS Dynamic Update to point
> your machine's name to your current IP address. If you need a script
> to do that -- and you might -- you can probably put it
> in /etc/rc.local, unless you think that your mailer is going to get
> busy too soon. There is some reason to think this might not work; it's=
> possible that some anti-spam filters might be concerned that your
> hostname doesn't match what the PTR record says.
This is actually what I have been trying to do for quite a while now,
but no matter how I try to "fool" sendmail, it seems to be two steps
ahead. I never got it to accept any other hostname than the one
"assigned" by the ISP.
--=20
Kind regards,
Jan Danielsson
--------------enigC51A4B2841E627D47D72C340
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (NetBSD)
iD8DBQFFxarHbgs4ia4rq9IRCggMAKCI7Xkz19e5F+C4gdrZHNf7z3Z80gCgkYwC
RNgsXNfpyHXwRscVvYH2AZg=
=+r/5
-----END PGP SIGNATURE-----
--------------enigC51A4B2841E627D47D72C340--