From owner-freebsd-questions Fri Nov 16 5:36:40 2001 Delivered-To: freebsd-questions@freebsd.org Received: from 217-126-145-95.uc.nombres.ttd.es (217-126-145-95.uc.nombres.ttd.es [217.126.145.95]) by hub.freebsd.org (Postfix) with ESMTP id 5348637B405 for ; Fri, 16 Nov 2001 05:36:37 -0800 (PST) Received: by unicorn.ea4els.ampr.org (Postfix, from userid 1001) id A8D5B314C; Fri, 16 Nov 2001 11:55:47 +0100 (CET) To: freebsd-questions@freebsd.org Subject: Re: sendmail doesn't like changed nameservers References: <20011115184242.GA43009@keyslapper.org> From: Simon J Mudd Date: 16 Nov 2001 11:55:47 +0100 In-Reply-To: leblanc+freebsd@keyslapper.org's message of "Thu, 15 Nov 2001 18:42:16 +0000 (UTC)" Message-ID: <86lmh7htn0.fsf@unicorn.ea4els.ampr.org> Lines: 42 X-Mailer: Gnus v5.7/Emacs 20.7 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG leblanc+freebsd@keyslapper.org (Louis LeBlanc) writes: > What I can't figure out is how to get sendmail to pick up the > nameserver change on the fly. I wound up having to kill sendmail from > /etc/mail/ using make stop. I then had to ps -ax for the remaining > sendmail processes and kill them explicitly. Otherwise I kept getting > resolve errors in /var/log/maillog. Most MTAs, and I don't think sendmail is an exception, don't use a specific nameserver themselves. That depends on what have configured in /etc/resolv.conf. I assume that you are still using the old ip setup before? In any case it is often more convenient to setup named locally and let it do all the work, rather than rely on your provider's name server changing ip addresses. If you do this you can set up resolv.conf to have 3 name servers, the first one it would use would be your local named, and the others could be the ones setup by your dhcp client script. > Is it possible to get sendmail to do this more gracefully from a > script? What is the general consensus for calling 'killall -HUP > sendmail'? If that is BAD, let me know so I don't do it :). The problem isn't sendmail, it's the name resolution, and the way this works is setup in /etc/resolv.conf (and a couple of other files). I think you are blaming the wrong tool here. > Anyway, I don't think I lost any mail (maybe a couple), but I would > like this to be automated so I don't really need to know when I get a > change in my dhcp lease. I'd look at the chcp client script and see how to setup the name server to use, or better still setup named properly so you don't _need_ to use your providers own name server. Simon -- Simon J Mudd, Tel: +34-91-408 4878, Mobile: +34-605-085 219 Madrid, Spain. email: sjmudd@pobox.com, Postfix RPM Packager To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message