External mail server problem.

benito

Well-Known Member
Jan 8, 2004
351
9
168
Mar del Plata - Argentina
cPanel Access Level
Root Administrator
Twitter
Hello !

I´m using in one domain an external mail server ( Google Apps ) and have this problem. Only when i send an email from another domain hosted in the same server, the email is routed directly to the same server where the domain is located insted going to the external mail server on google.

I have to do something to tell my server that this domain is not taking emails locally ?
 

mtindor

Well-Known Member
Sep 14, 2004
1,361
64
178
inside a catfish
cPanel Access Level
Root Administrator
Hello !

I´m using in one domain an external mail server ( Google Apps ) and have this problem. Only when i send an email from another domain hosted in the same server, the email is routed directly to the same server where the domain is located insted going to the external mail server on google.

I have to do something to tell my server that this domain is not taking emails locally ?
What you will want to do is this:

REMOVE the domain from /etc/localdomains
ADD the domain to /etc/remotedomains (if it isn't already in there)

I'm not sure if you'll have to restart Exim or not.

Mike
 

jmauro8ac

Registered
Jul 17, 2008
3
0
51
But if there is no local or remote folders

Hi, I try it, I have google apps too and no mail () function working but my etc directory just have my domain folder <mydomain.com> there is not any localdomains or remotedomains. I try creating this folder and placing my domain folder on the remotedomains but it just not work. Any idea?
 

verdon

Well-Known Member
Nov 1, 2003
917
10
168
Northern Ontario, Canada
cPanel Access Level
Root Administrator
Hi, I try it, I have google apps too and no mail () function working but my etc directory just have my domain folder <mydomain.com> there is not any localdomains or remotedomains. I try creating this folder and placing my domain folder on the remotedomains but it just not work. Any idea?
etc/localdomains and etc/remotedomains are files, not folders. Also, your user folder should be in /home not in /etc Are you sure you're using a cpanel server?
 

jmauro8ac

Registered
Jul 17, 2008
3
0
51
No, I'm using a common cpanel account

I have a reseller plan account that I admin with WHM. And I have ggogle apps on my common account at mydomain.com whit cpanel. So I guess that it is just on cpanel server. How can I get working google apps and mail () function. There is a "Relaying not permitted" error when I use the mail() function. Please help me. :confused:
 

cPanelDavidG

Technical Product Specialist
Nov 29, 2006
11,216
10
313
Houston, TX
cPanel Access Level
Root Administrator
I have a reseller plan account that I admin with WHM. And I have ggogle apps on my common account at mydomain.com whit cpanel. So I guess that it is just on cpanel server. How can I get working google apps and mail () function. There is a "Relaying not permitted" error when I use the mail() function. Please help me. :confused:
Your best bet would be to contact your hosting provider.
 

varunsolanki

Registered
Jan 8, 2011
1
0
51
I have the same problem. I'm using cpanel for the domain but as suggested above, my /etc folder is empty.

I checked in the other folders as well, but i could not find any file in which i could modify/comment the localdomain.
the folder structure in the site is as follows:
/access-logs
/etc
/logs
/mail
/public_ftp
/public_html
/tmp
/www

kindly advice
 

oshs

Well-Known Member
PartnerNOC
Sep 5, 2004
146
0
166
Hi,

Run this on the server after changing the MX records for any domain:

Code:
# /scripts/checkalldomainsmxs
You'll have to add the flag it specifies to force it.

Regards,
Suhail.
 

cPanelDavidG

Technical Product Specialist
Nov 29, 2006
11,216
10
313
Houston, TX
cPanel Access Level
Root Administrator
I have the same problem. I'm using cpanel for the domain but as suggested above, my /etc folder is empty.

I checked in the other folders as well, but i could not find any file in which i could modify/comment the localdomain.
the folder structure in the site is as follows:
/access-logs
/etc
/logs
/mail
/public_ftp
/public_html
/tmp
/www

kindly advice
It sounds like you are looking at /home/USERNAME/etc rather than /etc on the system. This can be the case if you are not the system administrator. If you do not have the password to username root, you will need to contact your hosting provider to help diagnose and resolve this issue.