Virtualmin + postfix + ldap + mail relaying plugin

2 posts / 0 new
Last post
#1 Wed, 09/07/2011 - 05:52
Peter

Virtualmin + postfix + ldap + mail relaying plugin

I have a long-running virtualmin installation with ldap/postfix/dovecot configured just fine.

I recently had the need to froward all mail for a single domain from the server to another server and not deliver locally.

To this end, I installed the "mail relaying" plugin and configured it according to the documentation. Virtualmin reports that everything is ok.

However, inbound mail is not relayed - it is returned as bounced:

Sep 7 11:19:29 fryp postfix/error[13795]: E209E800209: to=user-relaydomain.com@hostingserver.com, orig_to=user@relaydomain.com, relay=none, delay=0.03, delays=0.03/0/0/0, dsn=5.0.0, status=bounced (User unknown in virtual alias table)

Ldap log shows:

Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=50 SRCH base="dc=virtual,dc=hostingserver,dc=com" scope=2 deref=0 filter="(mailLocalAddress=user@relaydomain.com)" Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=50 SRCH attr=mailRoutingAddress Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=50 SEARCH RESULT tag=101 err=0 nentries=1 text= Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=51 SRCH base="dc=virtual,dc=hostingserver,dc=com" scope=2 deref=0 filter="(mailLocalAddress=user-relaydomain.com@hostingserver.com)" Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=51 SRCH attr=mailRoutingAddress Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=51 SEARCH RESULT tag=101 err=0 nentries=0 text= Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=52 SRCH base="dc=virtual,dc=hostingserver,dc=com" scope=2 deref=0 filter="(mailLocalAddress=user-relaydomain.com)" Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=52 SRCH attr=mailRoutingAddress Sep 7 11:23:31 hostingserver slapd[13821]: conn=53 op=52 SEARCH RESULT tag=101 err=0 nentries=0 text=

Seems like postfix is still getting the domain as local from ldap via the virtual map, which according to the postfix documentation takes priority over the transport map (i.e. if you've got something in both virtual and transport (or relay for that matter) virtual (local delivery) takes precedence).

So, looks like virtualmin hasn't done what's necessary in obscuring the domain from postfix to permit relaying of these addresses.

Anyone any ideas....?

Mon, 09/12/2011 - 13:37
Joe
Joe's picture

File a bug. LDAP gets far less testing than local users, so it's probably an oversight.

--

Check out the forum guidelines!

Topic locked