Re: [exim] Sending mail from different IP per domain

トップ ページ
このメッセージを削除
このメッセージに返信
著者: Wicus Ross
日付:  
To: Mike Cardwell
CC: exim-users
題目: Re: [exim] Sending mail from different IP per domain
Thank you for the reply.

Its resolving to the last alias on the eth0 device.

I ran the update-exim4.config.template and I restarted exim.

transport/30_exim4-config_remote_smtp

remote_smtp:
debug_print = "T: remote_smtp for $local_part@$domain"
driver = smtp
interface = ${lookup{$host_address}lsearch*{/etc/exim4/interface}}
helo_data = ${lookup{$host_address}lsearch*{/etc/exim4/helo_data}}

/etc/exim4/interface:
mydomain.com: eth0:1

/etc/exim4/helo_data:
mydomain.com: a.b.c.d

On 7/5/07, Mike Cardwell <exim-users@???> wrote:
> Wicus Ross wrote:
>
> > I'm a novice when it regarding the running and configuring of Exim or
> > Exim 4 for that matter. I'm running Ubuntu 6.10 Server.
> >
> > I have a machine that has 3 IP aliases on eth0. Each alias represents
> > a website. One of the sites wish to send emails. I would prefer it if
> > the email would originate from the IP address that is associated with
> > that site.
> >
> > I have searched the forums and found atleast one post that relates to
> > mine (http://www.exim.org/mail-archives/exim-users/Week-of-Mon-20060918/msg00090.html).
> >
> > I tried to implement the suggested solution:
> > http://www.exim.org/mail-archives/exim-users/Week-of-Mon-20060918/msg00116.html.
> > Unfortunately it doesn't seem to have the effect I'm hoping for or I'm
> > at fault. My server identifies itself as the default host ie. what is
> > stipulated in the hostname file.
> >
> > Is this possible or I'm on the wrong track?
>
> You need to find your remote_smtp transport and set the "interface"
> parameter on it. Eg:
>
> remote_smtp:
>    driver    = smtp
>    interface = ${if SOMECONDITION{ip1}{ip2}}

>
> If you start to get a lot more ips/domains, you might want to change the
> conditional to be a file lookup.
>
> You might want to look into the "helo_data" configuration option also.
>
> Mike
>
> --
> ## List details at http://www.exim.org/mailman/listinfo/exim-users
> ## Exim details at http://www.exim.org/
> ## Please use the Wiki with this list - http://www.exim.org/eximwiki/
>