I have a subdomain subdomain.mydomain with two servers server1.subdomain.mydomain and server2.subdomain.mydomain running CentOS 5.5. server1 runs a Postfix server for subdomain.mydomain that acts as a second level SMTP server, i.e., it does relay through another server relay.mydomain (on a higher level domain mydomain).
I need to set up another Postfix on server2 to act as a backup server for server1, so that server2 relays to server1 all mail sent through server2.
I have been digging through the Postfix documentation site and found a section named Configuring Postfix as primary or backup MX host for a remote site, but it is too brief and not very clear.
How can I set up the Postfix service on server2 to relay to/backup server1?
What I have understood from the previous link to Postfix documentation is that I have to set up the following:
On server1 (main server)
relay_domainsmust be equal torelay.mydomaintransport_mapsmust be equal tohash:/etc/postfix/transport/etc/postfix/transportmust contain the linesubdomaing.mydomain relay:[relay.mydomain](and brackets are mandatory for Postfix not to perform MX lookup)
On server2 (backup server)
subdomain.mydomainmust not be listed inmydestinationsmtpd_recipient_restrictionsmust be equal topermit_mynetworks reject_unauth_destinationrelay_recipient_mapsmust be equal tohash:/etc/postfix/relay_recipients/etc/postfix/relay_recipientsmust contain a line of the formuser@subdomain.mydomain xfor every mailboxuserin the system
However, this does not work. When I start the Postfix server on server2 and connect using telnet, Postfix does not send any message (no welcome message and no response to any command).