Have wondered how is it possible to set this up ..

Say for domain 123.com - MX records are setup as follows :

123.com MX preference = 10, mail exchanger = mail.123.com
123.com MX preference = 20, mail exchanger = mail.backup123.com

mail.123.com internet address =
mail.backup123.com internet address =

For this setup, everything a mail is being sent to [email protected] - the mail will first be delivered to mail.123.com @

however, in event of mail.123.com being down i.e switch off - the mail will in turn be delivered to mail.backup123.com @

I have seen this system working ... but my question is on the setup....

What are the requirements to set this up ?
Any special requirements required for the server @ ?
Any special requirements requred for the server @ ?

Could any one point to the some information on this ?

How does mail accepted be mail.backup123.com @ get routed back to mail.123.com @ so that the user eventually gets the email ?