PageViews: 41,796 hits / 498 nets
home updates download manual documents feedback search
DeleGateIcon

Reference Manual of DeleGate

SIMPLE PLAIN SHTML
DeleGate reference manual version 9.9 / MX_routing
[CTX] [ALL]
MX:server[:domain]
Specify the SMTP server toward which mails (bound for the domain) are forwarded. The server can be specified based on the destination address of the E-mail to be relayed (it is the address indicated in the RCPT command on the SMTP protocol). The character "*" in server is replaced with the domain part of a E-mail address as "foo@domain". The prefix "-MX." to a domain name as "-MX.domain" represents the mail-exchange server of the domain (which is retrieved by DNS as the MX record of the domain or host).
The default specification is SMTPCONF="MX:{-MX.*,*}" which means trying the MX first, and if it failed, then try direct connection to the domain as a hostname.

Examples:
SMTPCONF="MX:smtpserver" -- use the smtpserver as the upstream SMTP server
SMTPCONF="MX:{smtpserver1,smtpserver2}" -- try the SMTP servers in the order
SMTPCONF="MX:{-MX.*,*}" -- the default configuration
SMTPCONF="MX:{-MX.*,*,smtpserver}" -- adding a backup SMTP server
SMTPCONF="MX:{*,-MX.*}:*.localdomain" -- forward directly to the host if it's in localdomain
SMTPCONF="MX:smtpserver:{*.dom1,*dom2}" -- a server for the specified domains