is currently not <<< 550-permitted to relay through this server

tridean

Registered
May 14, 2007
2
0
151
Hi,

I am bew to this forum but found it while trying to solve an issue. I'd contact my host but this is outside their hours.

I have two accounts with my host, but both accounts emails are all getting the following bounce message every time someone tries to send an emial to one of them

The original message was received at Mon, 14 May 2007 17:07:24 +1000 from d220-238-107-196.dsl.vic.optusnet.com.au [220.238.107.196]

----- The following addresses had permanent fatal errors ----- <[email protected]>
(reason: 550-mail28.syd.optusnet.com.au [211.29.133.169]:57404 is currently not)

----- Transcript of session follows ----- ... while talking to financialmarketfisherman.com.:
>>> DATA
<<< 550-mail28.syd.optusnet.com.au [211.29.133.169]:57404 is currently not <<< 550-permitted to relay through this server. Perhaps you have not logged into <<< 550-the pop/imap server in the last 30 minutes or do not have SMTP <<< 550 Authentication turned on in your email client.
550 5.1.1 <[email protected]>... User unknown <<< 503 valid RCPT command must precede DATA


Does anyone know what I can do to fix this. Everythoing was fine until about 2-3 days ago, but we didn't notice until today, but it all clicked when we realized what was going on and why we had had no contact for 2-3 days

Thanks for any help
Dean
 

orware

Member
Jul 27, 2005
24
0
151
Always check /etc/localdomains when having email problems

I just learned this myself.

Check the text file /etc/localdomains and check to make sure the domains having problems are present in the list. If not, then add them to the list save the file and then Restart Exim for the changes to take effect.

You can access the file easily either by using Jonathan's free ConfigServer Explorer (www.configserver.com) software or via the shell using vi or pico.

Hope that helps!

-Omar
 

ajsinclair

Registered
Apr 9, 2005
1
0
151
works for me

I was having the same problem, and this solution worked for me...

but how can I prevent this from happening again? Email was working fine until last night when I upgraded cpanel. How does the "localdomains" file get updated normally?
 

oleanhst

Active Member
Sep 25, 2004
33
0
156
I am having the same issue, it seems like it is reverting back to a cached file or something. I will have to keep an eye on this file
 

skullbox15

Registered
Jun 5, 2007
1
0
151
It seemed to happen to me when I ran the "fix mailbox permissions" option in Cpanel. I've learned to stay away from that.

Also, you will want to REMOVE any domain that mail hosted elsewhere. For example, I had my primary domain (orlandotechworks.com) hosted on one of our Cpanel boxes. The website ran there, but our mail server is an exchange server in a different data center. I started having a problem with customers emailing us that were hosted on the same server.

Solution, we removed orlandotechworks.com from the /etc/localhosts file and everything was fine. Our sys admin figured out the mail was actually being delivered to accounts on the Cpanel server that we used before going to exchange.

The accounts still existed, so when I checked the mail, all the "missing" messages were there.

Something to keep an eye on.
 

smachol

Well-Known Member
Oct 19, 2001
57
0
306
Check the text file /etc/localdomains and check to make sure the domains having problems are present in the list. If not, then add them to the list save the file and then Restart Exim for the changes to take effect.
Found this from a search and it was a life-saver. Thanks!

The only difference is that I did not have to restart exim after adding the domain. Other than that it worleed perfectly. :)
 

mtindor

Well-Known Member
Sep 14, 2004
1,417
82
178
inside a catfish
cPanel Access Level
Root Administrator
Just like Skullbox15, it happened to me a few times when running 'fix mailbox permissions' - so I don't bother to fix mailbox permissions anymore. I may if something wasn't working, but then I'd be sure to back up /etc/localdomains and /etc/remotedomains beforehand.

Something to keep in mind (for the original poster) is this:

/etc/localdomains - lists the domains the server handles mail for
/etc/remotedomains - lists the domains the server does NOT handle mail for but which it is handling web/dns

You shouldn't find a host in both of those. If your domain disappeared from /etc/localdomains, it may have been put into /etc/remotedomains. So besides making sure it is put back in /etc/localdomains you shoudl make sure it is not present in /etc/remotedomains.

MIke
 

brianoz

Well-Known Member
Mar 13, 2004
1,146
7
168
Melbourne, Australia
cPanel Access Level
Root Administrator
You shouldn't find a host in both of those. If your domain disappeared from /etc/localdomains, it may have been put into /etc/remotedomains. So besides making sure it is put back in /etc/localdomains you shoudl make sure it is not present in /etc/remotedomains.
As far as I remember, just as Mike says, if it's in remotedomains it will be automatically removed from localdomains for you at regular intervals. :cool:
 

mtindor

Well-Known Member
Sep 14, 2004
1,417
82
178
inside a catfish
cPanel Access Level
Root Administrator
As far as I remember, just as Mike says, if it's in remotedomains it will be automatically removed from localdomains for you at regular intervals. :cool:
I remember it taking me a few weeks before I caught on to that as well - not fun when things suddenly just revert back heh.

Mike
 

aloeroot

Registered
Jul 9, 2010
2
0
51
Ontario
Happened when adding a subdomain

This just happened to me after I added a subdomain to the server; the subdomain was added to etc/localdomains immediately after the last entry, and not on the expected new line. This had the effect of creating a line such as:

yourdomain.comsubdomain.com

in my localdomains file, and triggered the relaying error for yourdomain.com. I added a carriage return, restarted exim and all is well. Strange!
 

Kamillo

Registered
Nov 29, 2010
1
0
51
London, UK
This worked for me (sorted by Hostgator tech support):

Hello,

Could you please try to send email now? It seems that your domain was set to a "Remote Domain" which would cause the server to reject email and try to use remote email servers (which in this case did not exist). I have corrected this issue for you at this time and email should work correctly for you.

If are have any questions or if there is anything else we can assist you with, please let us know.

Sincerely,
Linux Systems Administrator
HostGator.com LLC
Support Knowledgebase: HostGator.com Support Portal
 

Cindu

Well-Known Member
Feb 7, 2011
46
0
56
Hello,

Check whether the domain is present in the /etc/remotedomains. If so remove it and place it in the /etc/localdomains.
 

crazyaboutlinux

Well-Known Member
Nov 3, 2007
939
1
66
the domains is using Multiple MX
10 Priority is set to remote server (email.domain.com) And
30 priority is set to local server (mail.domain.com)

what to do in this case ??

we have selected "Automatically Detect Configuration: Local (recommended) more » "

previously it was set to Remote Mail Exchanger more »

then i have changed it to "Automatically Detect Configuration: Local (recommended) more » "
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
You'd need to set the cPanel machine as a secondary MX for it. The setting you've selected isn't the correct one. It should be "Backup Mail Exchanger" which is what the cPanel machine is functioning to do. The domain needs to be placed into /etc/secondarymx file and into /etc/remotedomains file. cPanel will check for the primary MX whenever the primary MX is online, but queue emails onto the cPanel machine when that primary MX isn't online.
 

crazyaboutlinux

Well-Known Member
Nov 3, 2007
939
1
66
You'd need to set the cPanel machine as a secondary MX for it. The setting you've selected isn't the correct one. It should be "Backup Mail Exchanger" which is what the cPanel machine is functioning to do. The domain needs to be placed into /etc/secondarymx file and into /etc/remotedomains file. cPanel will check for the primary MX whenever the primary MX is online, but queue emails onto the cPanel machine when that primary MX isn't online.
Hi Tristan,

So i just need to set from ""Automatically Detect Configuration: Local (recommended) more » " TO ""Backup Mail Exchanger"

is it OK ??
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
40
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
Hi Nilesh,

You should change it to "Backup Mail Exchanger" for the option correct. If that doesn't work, then create the file /etc/secondarymx and put the domain into it. Also, ensure the domain is removed from /etc/localdomains and in /etc/remotedomains files.

Restart exim after making these changes.

Thanks.