[Pkg-exim4-users] Secondary MX with virtual domain config
x_debian-exim4-users_x at nospam.pz.podzone.net
x_debian-exim4-users_x at nospam.pz.podzone.net
Sat Jan 29 16:31:55 UTC 2011
Hi,
I am trying to configure exim for so called 'virtual' domains, but
with a primary/secondary MX scenario. In fact I'm not so sure this is
strictly correct usage of primary/secondary terminolgy but I hope it's
clear.
The stock solution appears to be the "vdom_aliases" router (below), as
variously quoted in howto's and internet postings. However afaict,
this only caters for single server operation and my attempts to morph
this to work satisfactorilly on a secondary MX have failed so far.
I have previously used the hubbed_hosts router (below) on the
secondary MX, together with callout to the primary to check for valid
recipient. This doesn't work so well I think if the primary MX is
down.
So I think the solution is to modify the hubbed_hosts router so that
it will consult a local configuration (as the vdom_aliases router
does) to validate the recipient addr.
The primary MX would then run the vdom_aliases router as per normal,
with it's local configuration of /etc/exim4/virtual/... files.
My efforts to figure this out have so far not come to much. I'm
hoping someone can point me in the right direction please?
I'm happy if the solution requires files to be synched between MXs, or
a hybrid solution where /etc/exim4/virtual/... is first used for
vaildation and /etc/exim4/hubbed_hosts is then used for routing.
-- 150_exim4-config_hubbed_hosts --
hubbed_hosts:
debug_print = "R: hubbed_hosts for $domain"
driver = manualroute
domains = "${if exists{CONFDIR/hubbed_hosts}\
{partial-lsearch;CONFDIR/hubbed_hosts}\
fail}"
same_domain_copy_routing = yes
route_data = ${lookup{$domain}partial-lsearch{CONFDIR/hubbed_hosts}}
transport = remote_smtp
-- 350_local-config_vdom_aliases --
vdom_aliases:
driver = redirect
allow_defer
allow_fail
domains = dsearch;/etc/exim4/virtual
data = ${expand:${lookup{$local_part}lsearch*@{/etc/exim4/virtual/$domain}}}
retry_use_local_part
pipe_transport = address_pipe
file_transport = address_file
no_more
My references on this have so far been the (Red) Exim book, and -
http://www.debian-administration.org/articles/140
http://wiki.nerdylorrin.net/wiki/Wiki.jsp?page=EximVirtualDomains
Thanks in advance for any help or advice received.
Charlie
More information about the Pkg-exim4-users
mailing list