Slightly OT: mta.sh problem

Glenn Steen glenn.steen at gmail.com
Thu May 31 10:20:02 IST 2007


On 31/05/07, Jim Coates <jimc at laridian.com> wrote:
> > -----Original Message-----
> > From: mailscanner-bounces at lists.mailscanner.info
> > [mailto:mailscanner-bounces at lists.mailscanner.info] On Behalf Of James
> > Sent: Wednesday, May 30, 2007 9:21 PM
> > To: MailScanner discussion
> > Subject: Re: Slightly OT: mta.sh problem
> >
> >
> > Jim Coates wrote:
> > > James,
> > >
> > > Thanks... we actually found the problem.  Turned out they
> > had upgraded
> > > MailScanner, but hadn't yet configured the mta.sh script.  It was
> > > working fine, because it hadn't been restarted, but once
> > they did it
> > > failed.
> > >
> > > We got the script configured and all is well now.
> > >
> > > I do however still have one issue... I used the
> > DaemonPortOption that
> > > binds outbound IPs to the same one used for inbound.  This works
> > > great, except for mail submitted by things such as php
> > mail, because
> > > it uses 127.0.0.1/localhost.  Sendmail complains that it
> > can't bind to
> > > that address for outbound mail (which I understand).
> > >
> > > How can I tell Sendmail to use a different outbound IP for the
> > > localhost mail?
> > >
> > > Thanks,
> > > Jim
> > >
> > >
> >
> > Good question. So far I haven't needed to bind sendmail to
> > IP's the way
> > you have. Can you post what your DaemonPortOptions are and I
> > can try and
> > experiment?
> >
> > James
> > --
> > MailScanner mailing list
> > mailscanner at lists.mailscanner.info
> > http://lists.mailscanner.info/mailman/listinfo/mailscanner
> >
> > Before posting, read http://wiki.mailscanner.info/posting
> >
> > Support MailScanner development - buy the book off the website!
> >
>
> Here is the string:
>
> DAEMON_OPTIONS(`Name=IPv4, Family=inet, Modifiers=bh')
>
> connections made from 123.123.123.1 go out 123.123.123.1 - great!
> connections made from 123.123.123.2 go out 123.123.123.2 - great!
> connections from 127.0.0.1 get lost because they can't get out of the
> machine
>
>
> Thanks,
> Jim
>
A workaround, but not really a solution, would be to use something
that doesn't rely on 127.0.0.1 and/or the sendmail command. For PHP,
you could instruct mail factory (PEAR, if you use it) to talk to one
of the IF addresses instead of the loopback/localhost one.
Perhaps also use Jef Poskanzer's mini_sendmail
(http://www.acme.com/software/mini_sendmail/) instead of the sendmail
command ....
# mini_sendmail -h
usage:  mini_sendmail [-f<name>] [-t] [-s<server>] [-p<port>]
[-T<timeout>] [-v] [address ...]
#
... As you can see, you can specify server/IP address to connect to etc.

Cheers
-- 
-- Glenn
email: glenn < dot > steen < at > gmail < dot > com
work: glenn < dot > steen < at > ap1 < dot > se


More information about the MailScanner mailing list