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.

DNS Setup Emails... Can't Figure Out Why!

Discussion in 'Bind / DNS / Nameserver Issues' started by baldidiot, Jul 6, 2011.

  1. baldidiot

    baldidiot Member

    Joined:
    Jul 6, 2011
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    So once a day I get the:

    "IMPORTANT: Do not ignore this email.

    Your hostname (***) could not be resolved to an IP address."

    Type email. I've tried everything I can think of, but nothing seems to satisfy it. If you check the IP of the hostname it does in fact resolve to the IP of the VPS. The /etc/hosts file is also set up correctly.

    I tried searching but all of the solutions I found related to things I've already done. Any ideas?
     
  2. ChrisRHS

    ChrisRHS Well-Known Member

    Joined:
    Jul 12, 2006
    Messages:
    292
    Likes Received:
    5
    Trophy Points:
    18
    Hello there,

    Check your DNS service setup (resolv.conf), and make sure you are using working external servers.

    Chris
     
  3. ServerMascot

    ServerMascot Member

    Joined:
    Jan 17, 2011
    Messages:
    13
    Likes Received:
    1
    Trophy Points:
    1
    Hello ,

    Check the hostname of your server and check the A record of your server hostname from out side of the server. A record of the hostname should point to server default/main IP. In case if your server hostname is not pointing to any IP then please add a A record for the server hostname at your nameservers end. Also set the RDNS for the server IP to what is your hostname of the server to avoid any further issue related with emails etc..

    Once the server hostname has A record run the cpanel script /scripts/ipcheck it will send the email to the associated email address if there is any issue with the hostname of the server.
     
  4. baldidiot

    baldidiot Member

    Joined:
    Jul 6, 2011
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    Oops, I thought I had notification emails to replies. I guess not...

    Thanks for the responses guys. I'm using my hosting companies nameservers, not custom nameservers - this wouldn't make a difference, right?

    The resolv/conf file has the correct nameserver IP's, but should it be saying 'domain'? What is the correct setting for this?

    ####### Automatically generated by OnApp (2.0.rc6)
    domain
    nameserver 83.170.64.2
    nameserver 83.170.69.2


    Here's the /etc/hosts

    ####### Automatically generated by OnApp (2.0.rc6)
    127.0.0.1 localhost
    109.123.112.157 uk2.synaptic-media.com uk2
     
    #4 baldidiot, Jul 21, 2011
    Last edited: Jul 21, 2011
  5. cPanelTristan

    cPanelTristan Quality Assurance Analyst
    Staff Member

    Joined:
    Oct 2, 2010
    Messages:
    7,623
    Likes Received:
    21
    Trophy Points:
    38
    Location:
    somewhere over the rainbow
    cPanel Access Level:
    Root Administrator
    Change /etc/resolv.conf to use good working public resolvers:

    nameserver 8.8.8.8
    nameserver 8.8.4.4

    Those are Google's public resolvers. These would go above the ones you already have listed in the file.

    Of note, to see if the issue is actually the resolvers, simply try to dig the hostname on the machine itself:

    Code:
    dig +short uk2.synaptic-media.com
    If it isn't digging locally on the server, then it is almost always the resolvers in /etc/resolv.conf being cached or not working properly to resolve the hostname. Public resolvers are typically a better option over using those of the hosting provider.
     
  6. baldidiot

    baldidiot Member

    Joined:
    Jul 6, 2011
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    Thanks! Ok I've tried changing the resolvers to the ones you suggested. And when I tried to dig the hostname it returned:

    dig: parse of /etc/resolv.conf failed

    Is it to do with the "domain" part? Should this contain a reference to something rather than just saying "domain"?

    ####### Automatically generated by OnApp (2.0.rc6)
    domain
    nameserver 8.8.8.8
    nameserver 8.8.4.4
     
  7. cPanelTristan

    cPanelTristan Quality Assurance Analyst
    Staff Member

    Joined:
    Oct 2, 2010
    Messages:
    7,623
    Likes Received:
    21
    Trophy Points:
    38
    Location:
    somewhere over the rainbow
    cPanel Access Level:
    Root Administrator
    Yes, domain should contain the root domain if you have that line in /etc/resolv.conf file. I would simply suggest removing that line anyway, since it isn't required and only have the nameserver entries.
     
Loading...

Share This Page