The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

External an local mailserver -> 550 error

Discussion in 'E-mail Discussions' started by Tagor, Jan 20, 2006.

  1. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    External and local mailserver -> 550 error

    Hi,

    I have a domain which uses a external and local mailserver. This is how my config looks like:
    MX 10 some.external.ip.address
    MX 20 127.0.0.1

    Now I removed this domain from /etc/localdomains and added it to /etc/remotedomains. However now the second MX entry doesn't work. I get the following error:
    I think this is because the domain isn't in /etc/localdomains. Is there a way to have e-mail delivered externally and a failover which is locally?
     
    #1 Tagor, Jan 20, 2006
    Last edited: Jan 20, 2006
  2. elliotcooper

    elliotcooper Well-Known Member
    PartnerNOC

    Joined:
    May 18, 2005
    Messages:
    56
    Likes Received:
    0
    Trophy Points:
    6
    I think that the best thing to do here will be to drop using the IP addresses in the MX records, as you shouldn't be doing that anyway, and create a second A record that resolves to an IP on your server and use that in the failover MX record.

    So you should first create two A records like:

    mail1.yourdomain.com A some.external.ip.address
    mail2.yourdomain.com A IP.that.the.cpanel.account.for.the.domain.is.configured.to.use

    Then set the MX records as follows:

    yourdomain.com MX 10 mail1.yourdomain.com
    yourdomain.com MX 20 mail2.yourdomain.com

    If you keep the domain out of the /etc/localdomains then the server will deliver the mail as per the MX records which should end putting it in the local mail box if the primary MX is unreahable.

    I haven't tried this so I don't know that it will work but it would be the first thing that I would try.
     
  3. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    I tried that already. It causes two problems. First it doesn't deliver the local e-mail and second it returns the above error.
     
  4. AdminWAY

    AdminWAY Member

    Joined:
    Feb 15, 2005
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    Hi,

    Have you tried going into WHM, under the Exim Configuration disable the setting "Verify the existence of email senders".
     
  5. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    As said if I do the options above it still delivers locally.
     
  6. elliotcooper

    elliotcooper Well-Known Member
    PartnerNOC

    Joined:
    May 18, 2005
    Messages:
    56
    Likes Received:
    0
    Trophy Points:
    6
    How exactly are you generating the error that you list in your origional post? It looks like you are generating it using the Mail Test on http://www.dnsreport.com/. It look like the dnsreport server is attempting to initiate a connection on port 25 which the server is denying because it uses pop before smtp. You cannot initiate a connection on port 25 unless you have, in the last 30 minutes, logged into a pop account on the server from the same IP. Doing this from dnsreport is not going to give you a valid error report.

    Do you get the same error when you attempt to relay mail through the server from an IP that you have used to collect mail from in the last 30 mintues?

    What happens if you send a message to one of these problemm addresses from a web mail account?
     
    #6 elliotcooper, Jan 20, 2006
    Last edited: Jan 20, 2006
  7. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    You cannot do what you're looking to do there, that's not the function of a backup MX. The MX scores are only a suggestions as to where an email server shoudl attempt to deliver to first if it can get to that server, otherwise it will attempt delivery to the other server.

    Most SMTP servers then require you to allow relaying on both MX servers with one setup to actually receive the email. You cann have any MX record set to a local server and not allow relaying on that server for that domain.

    What you definitely cannot have is this:

    MX 20 127.0.0.1

    Since that means that anyone sending email to that domain is being told to deliver email to itself and never send off server.

    You need to read up more on what backup MX is for and how it works.
     
  8. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    Sorry, I accidentally wrote '127.0.0.1', actually I use the ip address of the server on that record. Is this correct?

    MX 10 some.external.ip.address
    MX 20 ip.address.of.server

    I guess this will take over the job if the first mail server can't be reached?

    By the way for some reason the mail delivery to the external server now works. But I get that error message on DNSstuff. I am wondering if the mail backup server now also works?
     
  9. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    I noticed the following error when someone tried to deliver a message on the backup mailserver:

    2006-01-21 00:22:59 H=host86-130-69-48.range86-130.btcentralplus.com (mail-backup.xxx.com) [xx.xxx.xx.xx]:4145 I=[xx.xx.xx.xx]:25 F=<nzhgudeouwn@hotmail.com> rejected RCPT <xxx@xxx.com>: host86-130-69-48.range86-130.btcentralplus.com (mail-backup.xxx.com) [86.130.69.48]:4145 is currently not permitted to relay through this server. Perhaps you have not logged into the pop/imap server in the last 30 minutes or do not have SMTP Authentication turned on in your email client.
     
  10. Murtaza_t

    Murtaza_t Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    476
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    cPanel Access Level:
    Website Owner
    You should either use your domain name or the hostname of the server instead of using the IP address in backup MX entry, as most of the times it fails to pickup the IP.
     
  11. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    Ok, thanks a lot, I will try that :)
     
  12. Tagor

    Tagor Well-Known Member

    Joined:
    Mar 6, 2004
    Messages:
    193
    Likes Received:
    0
    Trophy Points:
    16
    After trying that, I still get the 550 error.

    Anyone?
     
  13. rhenderson

    rhenderson Well-Known Member

    Joined:
    Apr 21, 2005
    Messages:
    785
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Oklahoma
    cPanel Access Level:
    Root Administrator
    Smtp

    We had a customer with the same problem, had them check the tick box in thier email client that the server requires authentication and resolved the problem.
     
Loading...

Share This Page