MX record

It is possible to configure several MX records, typically pointing to an array of mail servers for load balancing and redundancy.

The priority field identifies which mailserver should be preferred - in this case the values are both 10, so mail would be expected to flow evenly to both onemail.example.com and twomail.example.com - a common configuration.

The sending agent then attempts to establish an SMTP connection, trying the host with the lowest "Priority" value first.

An SMTP client must be able to try (and retry) each of the relevant addresses in the list in order, until a delivery attempt succeeds.

[3] This method places the burden on the DNS rather than the SMTP-sender to perform the load balancing, which in this case will present a list of IP addresses in a specific order to the clients querying the A record of the mail exchanger.

Some domains will have several MX records, one of which is intended as a "backup" - with a higher preference number so that it would not normally be picked as the target for email delivery.

However, in the case of errors from the lower-numbered hosts, (perhaps due to an outage of some sort), sending email servers will deliver to the "backup" host - queue.example.com in the example below: If the backup server has direct access to user mailboxes, mail will proceed there, but otherwise will likely be queued on queue.example.com until the outage is resolved.

When servers indicate temporary failures, either by explicitly sending a 4xx error or by ending the connection unexpectedly (which must be treated as a 451 error, according to Section 3.8 of the RFC), Section 4.5.4.1 says: The sender MUST delay retrying a particular destination after one attempt has failed.However, when the sender retries, the RFC is silent about whether this should be to the same server, or a more "distant" MX record.

To provide reliable mail transmission, the SMTP client MUST be able to try (and retry) each of the relevant addresses in this list in order, until a delivery attempt succeeds.Some servers (such as Sendmail and Postfix 2.1 or later),[7] will attempt the next-furthest MX server after some types of temporary delivery failures, such as greeting failures.

Under the circumstances, MX without fallback to A would not have worked because of the substantial installed base of mail servers using A records.