[wplug-bsd] new install: postfix

Bill Moran wmoran at potentialtech.com
Tue Jul 20 09:33:51 EDT 2004


Brandon Kuczenski <brandon at 301south.net> wrote:

> On Tue, 20 Jul 2004, Bill Moran wrote:
> > > I modified /etc/rc.conf to include:  
> > > sendmail_enable="NO"
> > 
> > This should be:
> > sendmail_enable="NONE"
> > 
> 
> This definitely eliminated the bootup problem and postfix seems to be 
> running (though I can't say 'normally' just yet).

One thing at a time ...

> > > and then created a link in /usr/local/etc/rc.d: 
> > > # ln -s /usr/local/sbin/postfix postfix.sh
> > 
> > A little unconventional, but it should work.
> 
> Since I want to do things the right way, what is it?

Unfortunately, I don't know if there's a "right way" in this case just
yet.  As crazy as it sounds, replacing sendmail is still considered a
radical venture ...

The three possible techniques in FreeBSD at this time (that I'm aware of,
anyway, there may be more):
1) What you did.
2) Creating an actual shell script in /usr/local/etc/rc.d ... this is
   almost the same as #1, except if you use rcng, you can do some spiffy
   stuff in the script like have FreeBSD automagically figure out what
   order services need to be started in (i.e., you may not want to start
   Postfix until sasl is started ...)
3) Believe it or not, the /etc/rc.sendmail script is designed to start
   _any_ mail server, not just sendmail.  Thus, by tweaking values in
   /etc/rc.conf, you can actually have it start from the script that
   used to start sendmail.  The settings are:
sendmail_enable="YES"
sendmail_flags="-bd"
sendmail_outbound_enable="NO"
sendmail_submit_enable="NO"
sendmail_msp_queue_enable="NO"
   (If you do this, be sure to remove the symlink in /usr/local/etc/rc.d)

Any of these techniques, done correctly, should result in the same net
effect.

> > /var/log/maillog is a good place to look.  Check the output of "sockstat -4"
> > to see if the Postfix process "master" is listening on port 25.  General
> > system stuff will be in /var/log/messages, just like on Linux.
> 
> Ah, sockstat looks like it will be useful (doesn't exist on linux).  For
> example, syslogd should only be listening on localhost:514 and not *:514
> right?

There's probably no reason for syslog to be listening on any port at all,
you can stop it by adding 'syslogd_flags="-ss"' in /etc/rc.conf

> Anyway, master is there on *:25 like it should be.

That's good.

> However, inter-host mail delivery seems to have some snags.  I can send
> mail from root at ocean to b at mud, using PINE, iff I set the smtp-server
> setting to '301south.net', but not 'ocean.301south.net' which perplexes me
> (it tells me that there's no such host as ocean.301south.net, even though
> that's exactly what the local hostname is).  For the sake of my users, I 
> want to minimize the required configuration of PINE (to zero, ideally) so 
> this will have to be worked out, but for now it's okay.

As someone else pointed out, I can't resolve ocean.301south.net either.

> However, I have sent a whole bunch of mail, from b at mud and from 
> b at ocean, to root at ocean, and none of it has shown up anywhere nor gotten 
> bounced.  I am pretty perplexed about that.

What does postqueue -p tell you?  If the queue is empty, then your mail
is going _somewhere_.  It's possible that local delivery is not set up
as you expect, and your mail programs are looking in a different location
than Posfix is?  (I'm kind of grasping at straws ...)

> I am closing up for the night because I have gotten the system -- say -- 
> 25% working and, frankly, that feels pretty good.  But I'll be back on it 
> tomorrow.

Be sure to have a look through /var/log/maillog ... occasionally, the
errors in there will tell you exactly what to reconfigure.

> Thanks for reading and being patient with my frustration -- I'm working on 
> toning it down.

Nah ... if it's not worth getting mad about, it's not worth doing at all.

-- 
Bill Moran
Potential Technologies
http://www.potentialtech.com



More information about the wplug-bsd mailing list