Subject: Re: VPN+fetchmail+sendmail: Domain of sender address a@b.c does not
To: Matthias Scheler <tron@zhadum.org.uk>
From: Steven M. Bellovin <smb@cs.columbia.edu>
List: netbsd-users
Date: 02/08/2007 16:54:08
On Thu, 8 Feb 2007 21:24:04 +0000
Matthias Scheler <tron@zhadum.org.uk> wrote:

> On Thu, Feb 08, 2007 at 10:23:35PM +0200, Aleksey Cheusov wrote:
> > ... and it is fixed by '/etc/rc.d.sendmail restart|reload'.
> 
> Is there any reason that you don't add that command to
> "/etc/ppp/ip-up"?
> 
> > Question:
> > 1) why sendmail, once started, doesn't use updated /etc/resolv.conf?
> 
> Reading "/etc/resolv.conf" is (usually) managed by "libc" which never
> rereads it for performance reasons.
> 
> > 2) is it possible to configure it to do this?
> 
> Not that I'm aware of.
> 
> An alternative solution would be to run a local caching nameserver
> on your NetBSD and put "nameserver 127.0.0.1" into "/etc/resolv.conf".
> You could even teach "/etc/ppp/ip-up" to write a new "named.conf"
> which uses your ISP's nameservers as forwarders.
> 
I should post my scripts to do that.

But we might also want to adopt the OpenBSD solution.  Once a minute or
thereabouts, it checks to see if resolv.conf has changed; if so, it
rereads it.  (Stealing that code has been on my list for a while, but I
haven't gotten to it, mostly because I worked around it as above.)


		--Steve Bellovin, http://www.cs.columbia.edu/~smb