server can't find domain.com: NXDOMAIN

Discussion in 'Installation/Configuration' started by dexjul, Dec 20, 2007.

  1. dexjul

    dexjul New Member

    Hello,

    I installed binds I follow this http://www.ubuntugeek.com/dns-server-setup-using-bind-in-ubuntu.html.

    I think there is something wrong in my config.

    Kindly check this.

    Code:
    dexter@dexter-laptop:/etc/apache2$ dig docjul.com
    
    ; <<>> DiG 9.3.4 <<>> docjul.com
    ;; global options:  printcmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 59881
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0
    
    ;; QUESTION SECTION:
    ;docjul.com.                    IN      A
    
    ;; AUTHORITY SECTION:
    com.                    231     IN      SOA     a.gtld-servers.net. nstld.verisign-grs.com. 1198054478 1800 900 604800 900
    
    ;; Query time: 10 msec
    ;; SERVER: 58.69.254.106#53(58.69.254.106)
    ;; WHEN: Wed Dec 19 17:06:11 2007
    ;; MSG SIZE  rcvd: 101

    Code:
    dexter@dexter-laptop:/etc/apache2$ nslookup docjul.com
    Server:         58.69.254.106
    Address:        58.69.254.106#53
    
    ** server can't find docjul.com: NXDOMAIN

    docjul.com.db
    Code:
    // replace example.com with your domain name. do not forget the . after the domain name!
    // Also, replace ns1 with the name of your DNS server
    docjul.com. IN SOA ns1.docjul. admin.docjul.com. (
    // Do not modify the following lines!
    2007031001
    28800
    3600
    604800
    38400
    )
    
    // Replace the following line as necessary:
    // ns1 = DNS Server name
    // mail = mail server name
    // example.com = domain name
    
    docjul.com. IN NS ns1.docjul.com.
    docjul.com. IN MX 10 mail.docjul.com.
    docjul.com. IN A 124.83.19.155
    
    // Replace the IP address with the right IP addresses.
    www IN A 124.83.19.155
    mta IN A 124.83.19.155
    ns1 IN A 124.83.19.155
    rev.0.0.124.in-addr.arpa
    Code:
    //replace example.com with yoour domain name, ns1 with your DNS server name.
    // The number before IN PTR example.com is the machine address of the DNS server. in my case, it’s 1, as my IP address is #192.168.0.1.
    @ IN SOA ns1.docjul.com. admin.docjul.com. (
    2007031001;
    28800;
    604800;
    604800;
    86400
    )
    
    IN NS ns1.docjul.com.
    1 IN PTR docjul.com
     
  2. falko

    falko Super Moderator Howtoforge Staff

    Does
    Code:
    dig @localhost docjul.com
    work?
     
  3. edge

    edge Active Member Moderator

    dexjul,

    A bit off topic, but maybe you can post the fix to your Hotmail problem here?
    Lot's of people here are having the same problem as you did have, and they (like you) would love to have it working.
     
  4. dexjul

    dexjul New Member

    Thanks falko, but still the same. Do you have any idea?
     
  5. falko

    falko Super Moderator Howtoforge Staff

    Is BIND running? What's the output of
    Code:
    netstat -tap
    ? Any errors in your logs?
     
  6. dexjul

    dexjul New Member

    Here's the output of netstat -tap

    Code:
    dexter@dexter-laptop:/var/log$ netstat -tap
    (Not all processes could be identified, non-owned process info
     will not be shown, you would have to be root to see it all.)
    Active Internet connections (servers and established)
    Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name   
    tcp        0      0 localhost:2208          *:*                     LISTEN     -                   
    tcp        0      0 *:mysql                 *:*                     LISTEN     -                   
    tcp        0      0 *:netbios-ssn           *:*                     LISTEN     -                   
    tcp        0      0 *:www                   *:*                     LISTEN     -                   
    tcp        0      0 192.168.242.1:domain    *:*                     LISTEN     -                   
    tcp        0      0 192.168.186.1:domain    *:*                     LISTEN     -                   
    tcp        0      0 124.83.30.228.pl:domain *:*                     LISTEN     -                   
    tcp        0      0 localhost:domain        *:*                     LISTEN     -                   
    tcp        0      0 localhost:ipp           *:*                     LISTEN     -                   
    tcp        0      0 localhost:953           *:*                     LISTEN     -                   
    tcp        0      0 *:microsoft-ds          *:*                     LISTEN     -                   
    tcp        0      0 localhost:2207          *:*                     LISTEN     -                   
    
    tcp        0      0 124.83.30.228.pld:42231 cs36.msg.dcn.yahoo:mmcc ESTABLISHED6223/gaim           
    tcp6       0      0 *:5900                  *:*                     LISTEN     6040/vino-server    
    tcp6       0      0 *:domain                *:*                     LISTEN     -                   
    tcp6       0      0 *:ftp                   *:*                     LISTEN     -                   
    tcp6       0      0 *:ssh                   *:*                     LISTEN     -                   
    tcp6       0      0 ip6-localhost:953       *:*                     LISTEN     -                   
    
    binds is running

    Code:
    dexter@dexter-laptop:/var/log$ sudo /etc/init.d/bind9 stop
     * Stopping domain name service... bind                                                                               [ OK ] 
    dexter@dexter-laptop:/var/log$ sudo /etc/init.d/bind9 start
     * Starting domain name service... bind                                                                               [ OK ] 
    
    Where can I find log for binds?

    Thank you.
     
  7. falko

    falko Super Moderator Howtoforge Staff

    Take a look at /var/log/syslog.
     
  8. skhaos

    skhaos New Member

    Merry Christmas... oh and adjust "admin" to reflect your bind user.

    Code:
    
    $TTL	86400	
    @ 	IN 	SOA 	admin	ns1.docjul.com. (
    20081112001	; Serial
    28800	: Refresh (s)
    3600	; Retry (s)
    604800	; Expiration (s)
    38400	; Negative Cache TTL (s)
    )
    ;
    @	IN 	NS 	ns1
    ns1	IN 	A 	124.83.19.155
    www 	IN 	CNAME	ns1
    mta 	IN 	CNAME 	ns1
    mail 	IN 	MX 	INSERT IP HERE
    
    
    You'll want to double check your reverse lookup too it seems. Update your zone file like this, and then restart bind. Please post your syslog after doing this.
     
    Last edited: Nov 12, 2008
  9. skhaos

    skhaos New Member

    According to DNS and BIND, 5th Edition by O'Reilly Media, 2007:

    "The second name (al.movie.edu.) is the mail address of the person in charge of the zone if you replace the first "." with an "@". Often you'll see root, postmaster, or hostmaster as the email address. Nameservers won't use this address; it's meant for human consumption. If you have a problem with a zone, you can send a message to the listed email address."

    So, I stand corrected.
     
  10. thisara

    thisara New Member

    Nxdomain

    My named on /etc/named
    /var/named
    my zone file on /var/named/chroot/var/named/data/


    [root@fcts data]# dig fcts.in

    ; <<>> DiG 9.3.6-P1-RedHat-9.3.6-4.P1.el5_4.2 <<>> fcts.in
    ;; global options: printcmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 48711
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

    ;; QUESTION SECTION:
    ;fcts.in. IN A

    ;; AUTHORITY SECTION:
    in. 900 IN SOA a0.cctld.afilias-nst.info. noc.afilias-nst.info. 2008492742 600 900 2592000 86400

    ;; Query time: 103 msec
    ;; SERVER: 192.168.1.10#53(192.168.1.10)
    ;; WHEN: Sat Apr 3 13:58:55 2010
    ;; MSG SIZE rcvd: 90


    /etc/hosts

    127.0.0.1 localhost.localdomain localhost
    ::1 localhost6.localdomain6 localhost6
    192.168.1.10 fcts.in fcts


    [root@fcts data]# nslookup fcts.in
    Server: 192.168.1.10
    Address: 192.168.1.10#53

    ** server can't find fcts.in: NXDOMAIN


    [root@fcts data]# nslookup
    > 192.168.1.10
    Server: 192.168.1.10
    Address: 192.168.1.10#53

    ** server can't find 10.1.168.192.in-addr.arpa.: NXDOMAIN
    > fcts.in
    Server: 192.168.1.10
    Address: 192.168.1.10#53

    ** server can't find fcts.in: NXDOMAIN


    How to get rid out this problem
     
  11. falko

    falko Super Moderator Howtoforge Staff

    What's the output of
    Code:
    dig @localhost fcts.in
    ?
     
  12. morfeus

    morfeus New Member

    I had the same problem but i got it out .
    I was missing a "." (point) in dns after domain name domain.com.

    hope it helps!
     
  13. backpacker77

    backpacker77 New Member

    Hi,

    What was the file where you missed the "." please ??

    I try to fix the same problem :(
     
  14. falko

    falko Super Moderator Howtoforge Staff

    Do you use BIND? Then check /etc/named.conf or /etc/bind/named.conf (depends on your distribution) and then the zone files that are included in this file.
     
  15. inky

    inky New Member

    Hello, you have missed your nameserver in SOA record. Also host mta its not a mail that you are want to be your MX.

    here is fixed zone file:
    Code:
    $TTL 86400
    docjul.com.	IN	SOA	[B]ns1.docjul.com.[/B] admin.docjul.com.      (
                                                    2007031001 ;Serial Number
                                                    28800 ;refresh
                                                    3600 ;retry
                                                    604800 ;expire
                                                    38400 ;minimum
    
    docjul.com.	IN	NS		ns1.docjul.com.
    docjul.com.	IN	A		124.83.19.155
    docjul.com.	IN	MX	10	mail.docjul.com.
    ns1		IN	A		124.83.19.155
    mail		IN	CNAME	docjul.com.
    www		IN	CNAME	docjul.com.
    mta		IN	A		124.83.19.155
    
    
     
  16. misterm

    misterm Member HowtoForge Supporter

    I have the same worries as you, with ISPConfig, but I is not the same config file pri.domain.com

    MM:confused::confused:
     
  17. till

    till Super Moderator Staff Member ISPConfig Developer

    You missed to add the A-Records for the nameservers and the domain.
     
  18. misterm

    misterm Member HowtoForge Supporter

    Till Ok, I found

    Hello Till
    I forgot the hostname in the hosts file server.

    Here

    cordially

    MM
     
  19. JP_linux

    JP_linux New Member

    NXDOMAIN problem,

    Good morning,:(

    I don't understand where and why I encounterd an error if I follow some instructions. In the next rounds I will be posted all settup, maybe somebody can help me. First of all I want to specify that I installed bind9 on virtualbox under platform of linux CentOS 6.3. The base platform where is installed virtual machine is linux Ubuntu. So:

    > vi /etc/named.conf
    options {
    listen-on port 53 { 127.0.0.1; };
    listen-on-v6 port 53 { ::1; };
    directory "/var/named";
    dump-file "/var/named/data/cache_dump.db";
    statistics-file "/var/named/data/named_stats.txt";
    memstatistics-file "/var/named/data/named_mem_stats.txt";
    allow-query { localhost; };
    query-source address * port 53;
    recursion yes;

    dnssec-enable yes;
    dnssec-validation yes;
    dnssec-lookaside auto;

    /* Path to ISC DLV key */
    bindkeys-file "/etc/named.iscdlv.key";
    managed-keys-directory "/var/named/dynamic";
    };

    logging {
    channel default_debug {
    file "data/named.run";
    severity dynamic;
    };
    };

    zone "." IN {
    type hint;
    file "named.ca";
    };
    zone "my_site.com" {
    type master;
    file "my_site.com.fwd";
    };
    zone "2.0.10.in-addr.arpa" {
    type master;
    file "my_site.com.rev";
    };

    include "/etc/named.rfc1912.zones";
    include "/etc/named.root.key";

    >vi my_site.com.fwd

    $ORIGIN my_site.com.

    $TTL 3D

    @ SOA serverCAE. root.my_site.com. (12 4h 1h 1w 1h)

    @ IN NS serverCAE.

    serverCAE. IN A 10.0.2.15

    www IN A 10.0.2.15

    >vi my_site.com.rev

    $ORIGIN 2.0.10.in-addr.arpa.

    $TTL 3D

    @ SOA serverCAE. root.my_site.com. (12 4h 1h 1w 1h)

    @ IN NS serverCAE.

    211 IN PTR serverCAE.

    > service named restart
    OK
    OK

    >cat /etc/resolve.conf

    nameserver 10.0.2.15

    > nslookup www.my_site.com

    Server: 10.0.2.2
    Address: 10.0.2.2#53

    ** server can't find www.my_site.com: SERVFAIL

    > nslookup 10.0.2.15

    Server: 10.0.2.2
    Address: 10.0.2.2#53

    ** server can't find 15.2.0.10.in-addr.arpa.: NXDOMAIN

    > dig @www.my_site.com
    dig: couldn't get address for 'www.my_site.com': not found

    > dig @10.0.2.15

    ; <<>> DiG 9.8.2rc1-RedHat-9.8.2-0.10.rc1.el6_3.5 <<>> @10.0.2.15
    ; (1 server found)
    ;; global options: +cmd
    ;; connection timed out; no servers could be reached

    Thats all.
    Somebody can help me with some ideea or sugestion about manner in which I can made functional bind9? Any sugestion, ideea or tutorial which can help me is blessing.

    Thank you in advance for support.
     

Share This Page