[geeks] configuring new mail server: need information on private LAN setup

Charles Shannon Hendrix shannon at widomaker.com
Fri Mar 23 17:23:40 CDT 2007


Charles Shannon Hendrix wrote:
> On Thu, 22 Mar 2007 17:09:32 -0400 (EDT)
> adh at an.bradford.ma.us (Sandwich Maker) wrote:
> 
>> " From: Charles Shannon Hendrix <shannon at widomaker.com>
>> " 
>> " I've been using the same sendmail configuration for years, and I need to
>> " make some changes to it.  Over the years I've somehow misplaced my m4
>> " configuration files, even the printouts I made as backup.
>> " 
>> " My setup is based on the NetBSD documentation's sendmail setup for a
>> " private LAN with an ISP as a smarthost (which is gone now).
>> " 
>> " Since I won't find the same documents as others, I thought I'd post here
>> " for favorite documentation or pointers to make sure I catch up on the
>> " collective wisdom for this kind of configuration.
>>
>> i for one would like to see what you come up with.
> 
> Here is what I have so far:
> 
> divert(-1)dnl
> include(`../m4/cf.m4')
> VERSIONID(`20070322.001')
> OSTYPE(bsd4.4)dnl
> GENERICS_DOMAIN(escape.goid.lan escape)
> FEATURE(genericstable)dnl
> FEATURE(masquerade_envelope)dnl
> define(SMART_HOST,smtp:mail.widomaker.com)
> FEATURE(redirect)dnl
> FEATURE(nocanonify)dnl
> FEATURE(`accept_unresolvable_domains')dnl
> FEATURE(`accept_unqualified_senders')dnl
> define(`SMTP_MAILER_FLAGS',`e')dnl
> define(`confCON_EXPENSIVE',`True')dnl
> define(`confTO_QUEUEWARN', `4h')dnl
> define(`PROCMAIL_MAILER_PATH', /usr/pkg/bin/procmail)dnl
> FEATURE(local_procmail)dnl
> MAILER(procmail)dnl
> 
> dnl # The following two mailers must always be defined
> MAILER(local)dnl
> 
> It mostly works.
> 
> Problems:
> 
> I cannot send mail from my mail server.  It tries to relay through my ISP
> smart host which times out, and then through my ISP's backup smart host,
> which also times out.

This happened because I'm stupid.

I didn't have a network route to the MX hosts.

The remaining problem I'm having is this:

If I send mail from a machine on my LAN, it goes to my mail server, which
relays it through my ISP smarthost, ultimately one of two MX hosts.  Works great.

However, if I send mail from the mail server itself, it doesn't rewrite the
from address, so the email bounces because the user is unknown (i.e. the
address is an unroutable domain).

-- 
shannon           | There is no such thing as security.  Life is either
                  | bold adventure, or it is nothing.
                  |         -- Helen Keller



More information about the geeks mailing list