HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Server Operation (http://www.howtoforge.com/forums/forumdisplay.php?f=5)
-   -   Backup MX - DNS "Fallback" (http://www.howtoforge.com/forums/showthread.php?t=58248)

MaddinXx 14th August 2012 00:15

Backup MX - DNS "Fallback"
 
Hello everyone

Today I tried setting up a MX backup server running ISPConfig.

I just created a regular "ISPConfig mailserver" and configured the mail transport according to posts found in the forums here, as well as relay access.

However I don't get the point on how to configure the DNS.

I have MX 1 with Prio. 10 and MX 2 with Prio. 20 as well as a CNAME mail.domain.tld pointing to MX 1.

Sending mails through MX 1 FQDN or CNAME works well.
Sending through domain.tld (without mail CNAME) doesn't work (no SMTP server found).

So MX 2 doesn't work at all.

Is their something I have to do with the DNS? Normally, it should work sending mails "to" domain.tld as it's suposed to lookup the MX records, or do I miss understand this?

Thanks for your help!
MaddinXx

falko 14th August 2012 19:25

You must not use CNAMEs for MX records. MX records must always point to A records.

MaddinXx 14th August 2012 21:14

Hi falko

Well, at the very end they do point to A records. What I have is:

mail.domain.tld -> CNAME to -> mail.alpha.otherdomain.tld
mail.alpha.otherdomain.tld -> MX -> Prio. 10
mail.beta.otherdomain.tld -> MX -> Prio. 20

mail.alpha.otherdomain.tld -> A -> to mailserver IP
mail.beta.otherdomain.tld -> A -> to 2nd mailserver IP

Both mailservers are running on other servers than the webserver.

falko 15th August 2012 14:20

Why do you use an MX record for mail.domain.tld? it should be domain.tld unless you use email addresses like user@mail.domain.tld.

MaddinXx 15th August 2012 14:49

Hi falko

The CNAME is for the tld itself. I've attached the two DNS zones:

http://www.img-teufel.de/thumbs/Bild...c8244aejpg.jpg

and

http://www.img-teufel.de/thumbs/Bild...013ba1cjpg.jpg

falko 16th August 2012 10:16

The DNS records look ok.

Quote:

Sending mails through MX 1 FQDN or CNAME works well.
Sending through domain.tld (without mail CNAME) doesn't work (no SMTP server found).
For my understanding: sending mails or receiving mails - where is the problem?

MaddinXx 16th August 2012 10:57

Quote:

Originally Posted by falko (Post 283763)
For my understanding: sending mails or receiving mails - where is the problem?

Like this, sending mails is only possible via the 1st mailserver and there is no fallback to the 2nd one, if the 1st fails.

Why?
- Because it only works with the CNAME (which points to one server (1st))

So the email client doesn't find out that there are two servers he can try.

But, a question aside, because probably I misunderstood the functionality of a backup MX.

Shouldn't it be possible with this setup to:

- If someone sends an email to info[ @ ]rackster, his mailserver checks if my 1st server is up. If yes -> send to it, if no -> send to the 2nd. As soon as the 1st is up again, 2nd -> sending to 1st -> to the email address finally.

- If I want to send an email, check if 1st server is up -> if not, send via the 2nd.

Thank you falko :)

falko 18th August 2012 00:12

The backup MX is for receiving mails only. Your mail client will use the configured mail server for sending mails, it doesn't check if there's a fallback if the mail server is down.

MaddinXx 18th August 2012 00:14

Ah and again we can see how wrong "knowledge" can lead to confusion.
I'll retry than I guess :)

Thank you falko!


All times are GMT +2. The time now is 12:52.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.