Know your ISP.

User #182066   421 posts
Forum Regular

I wanted my emails to be sent to a different server than the website was being hosted on, so i changed the mx record and mail A record. for some unknown reason some, not ALL of the phpmailers that we have on our website are delivering the emails to the server that the website is being hosted on and is not delivering them to where the mx records state. is there a reason for this or have i set up the dns records the incorrect way? It looks as though the phpmailer is sending the email straight to the same server instead of looking up the mx(mail) records.

posted 2008-May-19, 12am AEST
User #3103   2117 posts
Whirlpool Forums Addict

DNS Cache? Maybe try and flush it on the server/double check the server resolves/restart any mailer script you have.

posted 2008-May-19, 12am AEST
User #126725   101 posts
Forum Regular

If the mail server is running on the same physical host as the one running phpmailer, you might find that you need to remove some configuration information that makes it think that it is authorative for your email account/domain as it won't even bother checking MX records if its configuration tells it that it is authorative.

This may involve removing it via your control panel software on that server.

posted 2008-May-19, 4am AEST
User #79416   20 posts
Forum Regular

*nix server

if so then any email being generated on the server will be delivered locally no matter what settings you have for the account.

Only way to change that is to have your host remove the domain from /etc/localdomains and have it added to /etc/remotedomains

That way when the email is generated it will do a lookup outside the server to see where to deliver it.

posted 2008-May-20, 8pm AEST
User #182066   421 posts
Forum Regular

yeah, that sounds like the problem trigger as the emails that are not being delivered properly are being generated by the phpmailer on our website.. i asked my host and they said it was to do with the nameserver not working on cpanel... i do not understand that explanation at all.

posted 2008-May-20, 8pm AEST
edited 2008-May-20, 8pm AEST
User #43352   1499 posts
Whirlpool Enthusiast

Since its cPanel its probably using Exim, under that assumption if your domain is in /etc/localdomains it must be removed for it to attempy delivery to the MX records.

posted 2008-May-23, 2pm AEST
User #43352   1499 posts
Whirlpool Enthusiast

Since its cPanel its probably using Exim, under that assumption if your domain is in /etc/localdomains it must be removed for it to attempy delivery to the MX records.

posted 2008-May-23, 2pm AEST
User #182066   421 posts
Forum Regular

thank you all.. yes, it is cpanel with unix and i agree, the domain should be moved. this is most likely the problem.

posted 2008-May-24, 10am AEST
User #39126   102 posts
Forum Regular

The usual solution is to use the cPanel menu item "Edit MX" to change your MX record, not sure what you used.

When you use "Edit MX" it removes the domain from /etc/localdomains and puts it in /etc/remotedomains - at least it does on cpanel 11.

posted 2008-May-24, 11pm AEST
User #43352   1499 posts
Whirlpool Enthusiast

brianoz writes...

When you use "Edit MX" it removes the domain from /etc/localdomains and puts it in /etc/remotedomains - at least it does on cpanel 11.

Further to that - if you go to the edit DNS zone section and select the domain, towards the bottom is a check box that can remove it from local domains.

posted 2008-May-25, 2am AEST
User #182066   421 posts
Forum Regular

ahhhhh... ok.... actually, i only used edit dns zones in cpanel and changed the mx records there. i failed to tick the box to remove the domain from local.. thanks for the `heads up`.

the checkbox that reads "Always accept mail locally even if the primary mx does not ...." is not checked and has never been checked.
so.... i made sure of that so maybe there is a problem.

posted 2008-May-25, 10am AEST
edited 2008-May-25, 11am AEST
Hosted by
WebCentral Australia
Big numbers
950,182 threads
16,717,378 posts
1,961,824 whims sent
2,994 wiki topics
238 ISPs listed
8,022 broadband plans
797 modems & routers
39,260 features filled