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.

Reverse DNS problem

Discussion in 'Bind / DNS / Nameserver Issues' started by danej, Jan 3, 2006.

  1. danej

    danej Active Member

    Joined:
    Dec 5, 2003
    Messages:
    28
    Likes Received:
    0
    Trophy Points:
    1
    Here is my file configuration for named and their respective zone files.

    Reverse DNS was not working and I had set these up. With this configuation, RDNS works, but it messes up other things like if I want to add a new account in whm, my main IP I use (118) is no longer a choice. I also can ping www.domain.com, but I can ping domain.com. Domain.com is what I use for NS and the server name. I have the IP range 118-121.

    Thanks for any suggestions.

    named.conf
    --------------

    zone "148.xxx.xxx.in-addr.arpa" IN {
    type master;
    file "/var/named/148.xxx.xxx.db";
    allow-update { none; };
    };

    zone "cp.domain.com" {
    type master;
    file "/var/named/cp.domain.com.db";
    };

    zone "domain.com" {
    type master;
    file "/var/named/domain.com.db";
    };


    148.xxx.xxx.db
    ---------------

    @ 14400 IN SOA ns1.domain.com. my.email.com. ( 2004021026 ; serial, todays date+todays
    28800 ; refresh, seconds
    7200 ; retry, seconds
    3600000 ; expire, seconds
    86400 ) ; minimum, seconds

    IN NS ns1.domain.com.
    IN NS ns2.domain.com.

    118 IN PTR domain.com.
    119 IN PTR domain.com.
    ;120 IN PTR domain.com.
    ;121 IN PTR domain.com.


    cp.domain.com.db
    ---------------

    @ 14400 IN SOA ns1.domain.com. my.email.com. (
    1069439442 ; serial, todays date+todays
    28800 ; refresh, seconds
    7200 ; retry, seconds
    3600000 ; expire, seconds
    86400 ) ; minimum, seconds

    cp.domain.com. 14400 IN NS ns1.domain.com.
    cp.domain.com. 14400 IN NS ns2.domain.com.
    cp.domain.com. 14400 IN A xxx.xxx.148.118

    localhost.cp.domain.com. 14400 IN A 127.0.0.1

    cp.domain.com. 14400 IN MX 0 cp.domain.com.

    ;118 IN PTR domain.com.
    ;119 IN PTR domain.com.
    ;120 IN PTR domain.com.
    ;121 IN PTR domain.com.

    domain.com.db
    ---------------

    @ 14400 IN SOA ns1.domain.com. my.email.com. ( 2004021026 ; serial, todays date+todays
    28800 ; refresh, seconds
    7200 ; retry, seconds
    3600000 ; expire, seconds
    86400 ) ; minimum, seconds

    domain.com. 14400 IN NS ns1.domain.com.
    domain.com. 14400 IN NS ns2.domain.com.
    domain.com. 14400 IN A xxx.xxx.148.118

    localhost.domain.com. 14400 IN A 127.0.0.1

    domain.com. 14400 IN MX 0 domain.com.

    mail 14400 IN CNAME domain.com.
    www 14400 IN CNAME xxx.xxx.148.118
    ftp 14400 IN A xxx.xxx.148.118
    secure 14400 IN A xxx.xxx.148.118
    www.secure 14400 IN A xxx.xxx.148.118
    ns1.domain.com. 14400 IN A xxx.xxx.148.118
    ns2.domain.com. 14400 IN A xxx.xxx.148.119
     
  2. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    You should only have one zone file for domain.com and add A record for subdomains. Delet the zone file cp.domain.com.

    Has the authority for rDNS definitely been delegated to you by the IP block owner, or is that you?
     
  3. danej

    danej Active Member

    Joined:
    Dec 5, 2003
    Messages:
    28
    Likes Received:
    0
    Trophy Points:
    1
    Updated Zone Files

    Ok, I deleted cp and included it in the domain.com.db file as an A record. Yes, it has definately been delegated and the reverse lookup works fine now. I guess the only change that I'm not sure how it happened was the "create a new account" script in whm.

    Under "Ip Address" it used to list 118-121 and all of my domains are on the 118 for now. But after I did these changes to do the reverse DNS, 118 is no longer in the list. I'm not sure where whm pulls the list of ip's from.

    Under "Main Shared Virtual Host IP" it is listed as xxx.xxx.148.118 on the edit setup page.

    I could not find a good example for rDNS files (as aol doesn't accept the mail if you don't have it), so I'll post it just for an example. So anyone getting bounced email for 554 error this was the solution.

    here are the zone files as updated:

    148.xxx.xxx.db
    ---------------

    @ 14400 IN SOA ns1.domain.com. my.email.com. ( 2004021026 ; serial, todays date+todays
    28800 ; refresh, seconds
    7200 ; retry, seconds
    3600000 ; expire, seconds
    86400 ) ; minimum, seconds

    IN NS ns1.domain.com.
    IN NS ns2.domain.com.

    118 IN PTR domain.com.
    119 IN PTR domain.com.
    120 IN PTR domain.com.
    121 IN PTR domain.com.

    domain.com.db
    ---------------

    @ 14400 IN SOA ns1.domain.com. my.email.com. ( 2004021026 ; serial, todays date+todays
    28800 ; refresh, seconds
    7200 ; retry, seconds
    3600000 ; expire, seconds
    86400 ) ; minimum, seconds

    domain.com. 14400 IN NS ns1.domain.com.
    domain.com. 14400 IN NS ns2.domain.com.
    domain.com. 14400 IN A xxx.xxx.148.118

    localhost.domain.com. 14400 IN A 127.0.0.1

    domain.com. 14400 IN MX 0 domain.com.

    mail 14400 IN CNAME domain.com.
    www 14400 IN CNAME domain.com.
    ftp 14400 IN A xxx.xxx.148.118
    secure 14400 IN A xxx.xxx.148.118
    www.secure 14400 IN A xxx.xxx.148.118
    cp 14400 IN A xxx.xxx.148.118
    www.cp 14400 IN A xxx.xxx.148.118
    ns1.domain.com. 14400 IN A xxx.xxx.148.118
    ns2.domain.com. 14400 IN A xxx.xxx.148.119
     
Loading...

Share This Page