From owner-freebsd-questions Thu Aug 14 22:30:53 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id WAA09096 for questions-outgoing; Thu, 14 Aug 1997 22:30:53 -0700 (PDT) Received: from suntan.tandem.com (suntan.tandem.com [192.216.221.8]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id WAA09091 for ; Thu, 14 Aug 1997 22:30:51 -0700 (PDT) From: grog@lemis.com Received: from papillon.lemis.com by suntan.tandem.com (8.6.12/suntan5.970212) id WAA13982; Thu, 14 Aug 1997 22:30:48 -0700 Received: (grog@localhost) by papillon.lemis.com (8.8.4/8.6.12) id RAA00709; Thu, 14 Aug 1997 17:58:58 +0900 (JST) Message-Id: <199708140858.RAA00709@papillon.lemis.com> Subject: Re: ppp -auto and sendmail as a delivery agent In-Reply-To: <3.0.2.32.19970812131739.009fb690@mism.ad.ic.ac.uk> from David Goddard at "Aug 12, 97 01:17:39 pm" To: d.m.goddard@ic.ac.uk (David Goddard) Date: Thu, 14 Aug 1997 17:58:56 +0900 (JST) Cc: questions@FreeBSD.org (FreeBSD Questions) Organisation: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8250 Fax: +61-8-8388-8250 Mobile: +61-41-739-7062 WWW-Home-Page: http://www.lemis.com/~grog X-Mailer: ELM [version 2.4ME+ PL32 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk David Goddard writes: > Hi, > > I know this is a variation on a FAQ, but trawls though the archives and > docs haven't produced definitive answers. > > I'm running ppp -auto to handle my networking (works fine) on by 2.2 > box, and I'd like to check my mail with poplicent (ugh) and send it > with sendmail (no probs there). > > During startup, sendmail (called from rc.local with -bd flag only) sends a > packet to the network, causing ppp to dial. I find this strange as there > is no q flag. I've disabled sendmail because of this - is this an > appropriate approach for achieving my aim or is there some other way of > preventing it from sending a packet (ie. should I have sendmail running as > a daemon for outgoing mail delivery to work properly)? I would have > thought that I don't need the sendmail daemon, but I have had slight > problems... sendmail is almost certainly performing some kind of DNS lookup, though I can't imagine what it would be at startup time. To find out, disable the automatic start of sendmail. After booting, first start tcpdump as follows, then sendmail. You'll need BPF in your kernel to run tcpdump, but hey, you've got to boot anyway. # tcpdump -i tun0 port domain tcpdump: listening on zp0 17:51:27.208660 202.48.26.104.domain > 202.48.19.204.domain: 43493+ A? foobar. (24) 17:51:30.797746 202.48.19.204.domain > 202.48.26.104.domain: 43493 NXDomain* 0/1/0 (85) (DF) 17:51:37.800225 202.48.26.104.domain > 202.48.19.204.domain: 43494+ A? foo.bar. (25) 17:51:41.988811 202.48.19.204.domain > 202.48.26.104.domain: 43494 NXDomain* 0/1/0 (98) (DF) 17:51:52.532274 202.48.26.104.domain > 202.48.19.204.domain: 43495+ (27) 17:51:53.666527 202.48.19.204.domain > 202.48.26.104.domain: 43495* 0/1/0 (76) (DF) 17:52:03.533327 202.48.26.104.domain > 202.48.19.204.domain: 43496+ (29) 17:52:05.775661 202.48.19.204.domain > 202.48.26.104.domain: 43496* 1/4/4 (204) (DF) The first pairs of messages show an address lookup (A?), and a reply saying 'no such domain'. The others are some other kind of lookup. > A possibly related problem is that when I try and send mail to a local user > (ie. mail dmg or mail dmg@localhost), it brings up the ppp link and sends > it to the internet (sendmail is currently configured not to queue mail, I'm > going to get round to that Real Soon Now). Yup, that'll be the same thing. > Before I set up ppp -auto (and disabled the sendmail daemon), there > was no problem with this (or is this a red herring?). More like a red herring. The name server lookup will time out--instead of bringing up the link, it'll take a minute to give up on resolving the name. > I suspect that what is happening is that the mail is being > interpreted as being sent to dmg@dmg.cc.ic.ac.uk (ie. me at full name of my > host as defnined in sysconfig) which is then being sent over PPP (because I > have no sendmail daemon listening on my box?), munged by Imperial's mail > system to dmg@ic.ac.uk and delivered to my POP mailbox. That's a possibility, but sendmail is clever enough (if you have the right sendmail.cf) to recognize where the mail needs to go. It doesn't need another sendmail on your system. But it's possible that sendmail.cf is wrong. > If I need to go RTFM a bit more, point me in the right direction please :-) Take a look at sendmail.cf. One possibility is the following pair of lines. You should have something similar in your sendmail.cf. # Don't insist that the BIND name server be running to resolve names # OI Note that this says "don't insist". You might still have problems. When I was running over a demand dialup link, I solved this by compiling sendmail to ignore DNS altogether. I think there's some comment in the Makefile; otherwise it should be in README or something like that. Greg