Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 15 Feb 1998 11:48:49 -0600 (CST)
From:      Bruce Albrecht <bruce@zuhause.mn.org>
To:        Brian Somers <brian@Awfulhak.org>
Cc:        questions@FreeBSD.ORG
Subject:   Re: ppp.linkdown, sendmail and named 
Message-ID:  <199802151748.LAA02468@zuhause.mn.org>
In-Reply-To: <199802151007.KAA10714@awfulhak.org>
References:  <199802150309.VAA00754@zuhause.mn.org> <199802151007.KAA10714@awfulhak.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Brian Somers writes:
 > > It looks to me like sendmail is trying to do a reverse DNS lookup on my
 > > PPP gateway, which causes my system to dial up the ISP when I receive
 > > mail through UUCP.  Is there anything I can put in the ppp.linkdown
 > > that might prevent this from happening?
 > 
 > There's some stuff in http://www.FreeBSD.org/FAQ/userppp.html about 
 > this.  Your options are limited.  The only real way is to create your 
 > own DNS and resolve stuff like this for sendmail.
 > 
 > You may also want to use ``deferred'' delivery mode in sendmail, but 
 > this will screw up any spam filtering you've got, and will also avoid 
 > processing incoming mail (which is ok if you're popping it anyway).

I think I figured out a solution.  I had the following two commands in 
the setup for the -auto system:
 set ifaddr 10.0.2.15/0 128.128.128.128/0
 add 0 0 128.128.128.128

and 128.128.128.128 was not an address for which my name server was
authoritative.  I added a dummy entry for 10.0.2.20 to my name server
db, and then changed the two lines to:
 set ifaddr 10.0.2.15/0 10.0.2.20/0
 add 0 0 10.0.2.20
and all is well.  Even after reading most of the O'Reilly cricket
book, it took a bunch of debugging of my errors in my DNS database,
and changing my a few things in my ppp configuration.  Basically, the
couple of rules one needs to know (and I hadn't seen explained in any
of the FAQs):

When you're setting up the rules for an auto-dial system with dynamic
IP addressing in ppp.conf, and it's bringing up the link every time
sendmail runs because it's doing name lookups, you need to create a
local nameserver, and make sure you have the following specified in
your ppp.conf file for the system:

 set ifaddr <myaddr>/0 <remoteaddr>/0
 add 0 0 <remoteaddr>

where <myaddr> and <remoteaddr> are 4 octect addresses which are
authoratively defined in your local name server's databases, and the
following should be in the ppp.linkup:

MYADDR:
 delete ALL
 add 0 0 HISADDR

and the following should be in the ppp.linkdown to remove the reverse
DNS lookup by sendmail for the old gateway after the link goes
down. <myaddr> and <remoteaddr> should be the same as the ones
specified in ppp.conf.

MYADDR:
 delete ALL
 set ifaddr <myaddr>/0 <remoteaddr>/0
 add 0 0 <remoteaddr>

I've found that it's invaluable to turn on logging for named as well
as ppp when debugging this.  My first problem for unexpected ppp
linkups was that named was not finding authoritative answers for
machines in my subdomain, and then after I fixed the errors in by
named databases, I realized sendmail was doing reverse name lookups of
the gateway, and modified my ppp configuration so that the dummy
address for the gateway was something (a non-existant machine, in my
case) in my domain.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199802151748.LAA02468>