Results 1 to 2 of 2

Thread: external mail server and php mail function

  1. #1
    Registered Member
    Join Date
    Jun 2007
    Posts
    9

    Default external mail server and php mail function

    Hello,

    I have a client that uses another server as mail server, He have no problem with this because he had done the changes on his own domain dns pool configuration adding subdomains point to another ip, and all works perfectly, he have a server to emails and my server for hosting pages...

    But the problem is i have a php script that want to send email notifications to a mail account on the same domain, but obviously the other server.

    I have set Remote Mail Exchanger and dns pool like this


    I have create a new A entrie called correo point to the ip of the mail server as show on the attachment.

    But when i run the php script that send an email notification to someone@redesip.es the mail server does not recevie anything...

    Thanks if someone can help me a little
    Last edited by yoseman; 05-04-2012 at 08:00 AM.

  2. #2
    Registered Member
    Join Date
    Sep 2004
    Location
    inside a catfish
    Posts
    1,164
    cPanel/WHM Access Level

    Root Administrator

    Default Re: external mail server and php mail function

    Make sure the domain in question is in /etc/remotedomains and is NOT in /etc/localdomains.

    redesip.es should be in /etc/remotedomains
    redesip.es should not be in /etc/localdomains

    Additionally, it is bad practice [and can break reliable email] to point your MX record to a hostname that is a CNAME.

    NO:

    Code:
    redesip.es.    IN   MX    0   mail.redesip.es.
    mail.redesip.es.   IN   CNAME    correo.redesip.es.
    YES:
    Code:
    redesip.es.    IN   MX    0   mail.redesip.es
    mail.redesip.es.   IN   A     188.138.107.176
    
    OR
    
    redesip.es.    IN   MX    0   correo.redesip.es.
    correo.redesip.es.    IN   A    188.138.107.176
    Mike

Similar Threads

  1. Replies: 3
    Last Post: 02-19-2014, 01:47 PM
  2. E-mail not going on same server sites using php mail() function
    By muzaffar in forum E-mail Discussions
    Replies: 1
    Last Post: 06-29-2009, 12:48 PM
  3. php mail() function not sending mail
    By fuzzymonkey in forum E-mail Discussions
    Replies: 3
    Last Post: 02-26-2006, 10:49 AM
bargain