Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 14th August 2012, 00:15
MaddinXx MaddinXx is offline
Senior Member
 
Join Date: Jul 2011
Location: Switzerland
Posts: 197
Thanks: 25
Thanked 60 Times in 44 Posts
Default 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
__________________
Rackster Internet Services's presences:
Official | Open Source | Github | Facebook | Twitter
Reply With Quote
Sponsored Links
  #2  
Old 14th August 2012, 19:25
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,732 Times in 2,569 Posts
Default

You must not use CNAMEs for MX records. MX records must always point to A records.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 14th August 2012, 21:14
MaddinXx MaddinXx is offline
Senior Member
 
Join Date: Jul 2011
Location: Switzerland
Posts: 197
Thanks: 25
Thanked 60 Times in 44 Posts
Default

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.
__________________
Rackster Internet Services's presences:
Official | Open Source | Github | Facebook | Twitter
Reply With Quote
  #4  
Old 15th August 2012, 14:20
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,732 Times in 2,569 Posts
Default

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.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 15th August 2012, 14:49
MaddinXx MaddinXx is offline
Senior Member
 
Join Date: Jul 2011
Location: Switzerland
Posts: 197
Thanks: 25
Thanked 60 Times in 44 Posts
Default

Hi falko

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



and

__________________
Rackster Internet Services's presences:
Official | Open Source | Github | Facebook | Twitter
Reply With Quote
  #6  
Old 16th August 2012, 10:16
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,732 Times in 2,569 Posts
Default

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?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #7  
Old 16th August 2012, 10:57
MaddinXx MaddinXx is offline
Senior Member
 
Join Date: Jul 2011
Location: Switzerland
Posts: 197
Thanks: 25
Thanked 60 Times in 44 Posts
Default

Quote:
Originally Posted by falko View Post
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
__________________
Rackster Internet Services's presences:
Official | Open Source | Github | Facebook | Twitter
Reply With Quote
  #8  
Old 18th August 2012, 00:12
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,732 Times in 2,569 Posts
Default

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.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
The Following User Says Thank You to falko For This Useful Post:
MaddinXx (18th August 2012)
  #9  
Old 18th August 2012, 00:14
MaddinXx MaddinXx is offline
Senior Member
 
Join Date: Jul 2011
Location: Switzerland
Posts: 197
Thanks: 25
Thanked 60 Times in 44 Posts
 
Default

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

Thank you falko!
__________________
Rackster Internet Services's presences:
Official | Open Source | Github | Facebook | Twitter
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Online Backup : What do you use and how do you setup it ? XZed Technical 5 4th January 2010 18:02
Squid Proxy Caching on Linux obzerver Installation/Configuration 4 13th August 2008 19:51
Google Apps dayjahone General 19 29th March 2008 17:25
DNS Configuration Problems VMartins Installation/Configuration 10 24th July 2007 14:40
Unable send receive emails vassilis3 Installation/Configuration 15 19th May 2007 14:34


All times are GMT +2. The time now is 18:13.


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