问题原文
原帖链接 · meksof · CC BY-SA 3.0
I have a domain named example.com. I want to set two mail servers on this domain.
The main purpose to set these mail servers is to have two different mail server, as if we have two different domains => so it is not one main server and the other one for backup.
An MX record for domain example.com is already existing (all mails sent to [email omitted] are delivered to smtp.example.com), so we have
@ 3600 IN MX 1 smtp.example.com
The A records are set like this:
@ 600 IN A 12.12.12.12
smtp 3600 IN A 13.13.13.13
relay 3600 IN A 14.14.14.14</pre>
Can we add new MX records for the second mail server?
For example, we set up a new subdomain relay.example.com that points to our new mail server (at ip 14.14.14.14). So that all mail that are sent to [email omitted] will be sent to relay.example.com.
已采纳解答
原帖链接 · Nils Toedtmann · CC BY-SA 3.0
This should do it:
@ 3600 IN A 12.12.12.12 ; irrelevant for mail routing
@ 3600 IN MX 1 smtp.example.com.
smtp 3600 IN A 13.13.13.13
relay 3600 IN MX 1 relay.example.com.
relay 3600 IN A 14.14.14.14
Notes:
- The last MX record is not strictly required (according to the standards, if there is no MX record for a domain then its A record is tried as a fallback - but some MTAs might not like that)
- Don't forget the terminating dot at then end of fully qualified records in your zonefile!
To avoid confusion, here a clarifying variant that would send all mail targeted at @subdom.example.com to the MTA relay.example.com:
subdom 3600 IN MX 1 relay.example.com.
relay 3600 IN A 14.14.14.14
摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。
