Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

sender_dependent_relayhost_maps on Postfix 2.4.0

523 views
Skip to first unread message

Mark Watts

unread,
Jul 3, 2007, 6:20:47 AM7/3/07
to

I'm trying to get sender_dependent_relayhost_maps working so that I can relay mail <from> a particular domain through another server.
When I use the config below, I get the following in my mail logs:


==> errors <==
Jul 3 11:15:02 mwatts.eris.qinetiq.com postfix/smtp[30137]: fatal: unknown service: [128.98.10.175]/tcp

==> info <==
Jul 3 11:15:02 mwatts.eris.qinetiq.com postfix/smtpd[30133]: connect from localhost[127.0.0.1]
Jul 3 11:15:02 mwatts.eris.qinetiq.com postfix/smtpd[30133]: B690429E54: client=localhost[127.0.0.1]
Jul 3 11:15:02 mwatts.eris.qinetiq.com postfix/cleanup[30136]: B690429E54: message-id=<20070703111...@foo.eris.qinetiq.com>
Jul 3 11:15:02 mwatts.eris.qinetiq.com postfix/qmgr[29863]: B690429E54: from=<f...@foo.eris.qinetiq.com>, size=548, nrcpt=1 (queue active)
Jul 3 11:15:02 mwatts.eris.qinetiq.com postfix/smtpd[30133]: disconnect from localhost[127.0.0.1]
Jul 3 11:15:03 mwatts.eris.qinetiq.com postfix/error[30138]: B690429E54: to=<m.w...@linux-corner.info>, relay=none, delay=1, delays=0.01/1/0/0.01, dsn=4.3.0, status=deferred (unknown mail transport error)

==> warnings <==
Jul 3 11:15:03 mwatts.eris.qinetiq.com postfix/qmgr[29863]: warning: private/smtp socket: malformed response
Jul 3 11:15:03 mwatts.eris.qinetiq.com postfix/qmgr[29863]: warning: transport smtp failure -- see a previous warning/fatal/panic logfile record for the problem description
Jul 3 11:15:03 mwatts.eris.qinetiq.com postfix/master[29224]: warning: process /usr/lib/postfix/smtp pid 30137 exit status 1
Jul 3 11:15:03 mwatts.eris.qinetiq.com postfix/master[29224]: warning: /usr/lib/postfix/smtp: bad command startup -- throttling

/etc/postfix/sender_maps:
f...@foo.eris.qinetiq.com 128.98.10.175

I've also tried:
f...@foo.eris.qinetiq.com smtp:[128.98.10.175]

What am I doing wrong?


postconf -n:
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/lib/postfix
delay_warning_time = 4h
forward_path = $home/.forward
home_mailbox = Maildir/
html_directory = /usr/share/doc/postfix-2.4.0/html
inet_interfaces = all
mail_owner = postfix
mailbox_size_limit = 1024000000
mailq_path = /usr/bin/mailq
manpage_directory = /usr/share/man
message_size_limit = 102400000
mydestination = localhost $myhostname
myhostname = mwatts.eris.qinetiq.com
mynetworks_style = host
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.4.0/README_FILES
relayhost = 128.98.2.2
sample_directory = /etc/postfix
sender_dependent_relayhost_maps = hash:/etc/postfix/sender_maps
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_banner = $myhostname ESMTP $mail_name ($mail_version) (Mandriva Linux)
smtpd_sasl_path = smtpd
unknown_local_recipient_reject_code = 550


--
Mark Watts BSc RHCE MBCS
Senior Systems Engineer
QinetiQ Trusted Information Management
Trusted Solutions and Services Group
GPG Key: http://keyserver.veridis.com:11371/search?q=0x455420ED

Robert Schetterer

unread,
Jul 3, 2007, 6:40:44 AM7/3/07
to
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mark Watts schrieb:

hi,
i use

@maildomainname servername

i.e.

@example.com serverrelay.example.net

in sender_dependent_relayhost_maps

this works like charme
- --
Mit freundlichen Gruessen
Best Regards

Robert Schetterer

https://www.schetterer.org
Germany
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iD8DBQFGiiesfGH2AvR16oERAjf1AJ9ZqQc9Z3vG5N0XXKEItJs6MUwxRwCfRDLf
Hmv+Tk9a9rktJr0LlFWLNwA=
=gO5e
-----END PGP SIGNATURE-----

Mark Watts

unread,
Jul 3, 2007, 6:51:52 AM7/3/07
to

> @maildomainname servername
>
> i.e.
>
> @example.com serverrelay.example.net
>
> in sender_dependent_relayhost_maps
>
> this works like charme

Seems as though I tried everything except the obvious :)

Thanks.

Sandy Drobic

unread,
Jul 3, 2007, 6:02:51 PM7/3/07
to
Mark Watts wrote:
>> @maildomainname servername
>>
>> i.e.
>>
>> @example.com serverrelay.example.net
>>
>> in sender_dependent_relayhost_maps
>>
>> this works like charme
>
> Seems as though I tried everything except the obvious :)

Are you sure that you really need sender_dependent_relayhost_maps?

It is usually only needed, if you have more than one sender address that
wants to auth against one destination server.

This is the configuration that I tested just today:

/etc/postfix/main.cf:
sender_dependent_relayhost_maps = hash:/etc/postfix/sender_relayhost
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/smtp_relayhost_auth
smtp_sasl_security_options = noanonymous
smtp_sender_dependent_authentication = yes

/etc/postfix/sender_relayhost
#format: sender-address relayhost
us...@gmx.de [mail.gmx.de]
us...@gmx.de [mail.gmx.de]

/etc/postfix/smtp_relayhost_auth:
#format: sender-address username:password
us...@gmx.de us...@gmx.de:password1
us...@gmx.de us...@gmx.de:password2

Now I am scratching my head trying to find a real-world application for it...


--
Sandy

List replies only please!
Please address PMs to: news-reply2 (@) japantest (.) homelinux (.) com

Robert Schetterer

unread,
Jul 3, 2007, 7:17:23 PM7/3/07
to
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Sandy Drobic schrieb:

Hi Sandy, i use it for a kind of hiding
a mailserver after anonther one,
youre right , this is only usefull
in rare situations,
In my case it has perfomance reasons cause one domain is heavy
bombed by spam connects.

- --
Mit freundlichen Gruessen
Best Regards

Robert Schetterer

https://www.schetterer.org
Germany
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iD8DBQFGitkDfGH2AvR16oERAgFeAJ44k4/aQGZ5pSx4Bl5ML0eaBr4j7wCffFAC
eHBLUl9wPmLWxZWgTpsrHsQ=
=vtEC
-----END PGP SIGNATURE-----

0 new messages