DNS problem

Discussion in 'ISPConfig 3 Priority Support' started by ababneh, Jun 29, 2013.

  1. ababneh

    ababneh New Member

    I have a VPS freshly set up using: The Perfect Server - Ubuntu 12.04 LTS (nginx, BIND, Dovecot, ISPConfig 3)

    So far I am still trying to figure out how to get rid of the error:

    root@server:/etc/bind# ls
    Code:
    bind.keys  db.empty    named.conf.default-zones     rndc.key
    db.0       db.local    named.conf.local             slave
    db.127     db.root     named.conf.options           zones.rfc1918
    db.255     named.conf  pri.ns1.example.com.err
    the contents of the error file:

    Code:
    $TTL        3600
    @       IN      SOA     ns1.example.com. mail.example.com. (
                            2013062812       ; serial, todays date + todays serial #
                            7200              ; refresh, seconds
                            540              ; retry, seconds
                            604800              ; expire, seconds
                            86400 )            ; minimum, seconds
    ;
    
    example.com. 3600 A        173.333.222.105
    example.com. 3600      MX    10   mail.example.com.
    example.com. 3600      NS        ns1.example.com.
    example.com. 3600      NS        ns2.example.com.
    mail 3600 A        173.333.222.105
    ns1 86400 A        173.333.222.105
    ns2 86400 A        173.333.222.105
    www 3600 A        173.333.222.105
    I also tried this

    Code:
    root@server:/# dig @localhost example.com
    
    ; <<>> DiG 9.8.1-P1 <<>> @localhost example.com
    ; (1 server found)
    ;; global options: +cmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 54614
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0
    
    ;; QUESTION SECTION:
    ;example.               IN      A
    
    ;; Query time: 0 msec
    ;; SERVER: 127.0.0.1#53(127.0.0.1)
    ;; WHEN: Fri Jun 28 22:41:11 2013
    ;; MSG SIZE  rcvd: 33
    
    And

    Code:
    root@server:/# dig @localhost ns1.example.com
    
    ; <<>> DiG 9.8.1-P1 <<>> @localhost ns1.example.com
    ; (1 server found)
    ;; global options: +cmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 22830
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0
    
    ;; QUESTION SECTION:
    ;ns1.example.com.           IN      A
    
    ;; Query time: 0 msec
    ;; SERVER: 127.0.0.1#53(127.0.0.1)
    ;; WHEN: Fri Jun 28 22:44:56 2013
    ;; MSG SIZE  rcvd: 37
    
    I checked /var/log/syslog and it is empty.

    I can access the site via the ip address but when I point the browser to example.com I get "server not found" (on Firefox) and "This webpage is not available" (on chrome).


    Any help with resolving this issue is appreciated.
     
  2. ababneh

    ababneh New Member

    Here is snapshots from ispconfig panel

    [​IMG]

    [​IMG]
     
  3. ababneh

    ababneh New Member

  4. ababneh

    ababneh New Member

    still no luck

    domain has yet to be resolved. Any ideas from the community wold be very helpful! any1?
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    Take a look into the syslog in /var/log, bind is logging all zone errors there.
     
  6. ababneh

    ababneh New Member

    There are many log files as shown below

    Code:
    root@server:/var/log# ls
    alternatives.log    dmesg.0                lastlog         nginx
    alternatives.log.1  dmesg.1.gz             mail.*          ntpstats
    apache2             dmesg.2.gz             mail.err        php5-fpm.log
    apt                 dmesg.3.gz             mail.log        pure-ftpd
    aptitude            dmesg.4.gz             mail.log.1      pycentral.log
    auth.log            dpkg.log               mailman         rkhunter.log
    auth.log.1          dpkg.log.1             messages        rkhunter.log.1
    boot                fail2ban.log           mysql           rkhunter.log.old
    boot.log            fail2ban.log.1         mysql.err       syslog
    btmp                faillog                mysql.log       udev
    btmp.1              fsck                   mysql.log.1.gz  upstart
    clamav              ispconfig              mysql.log.2.gz  wtmp
    dbconfig-common     ispconfig_install.log  mysql.log.3.gz  wtmp.1
    debug               kern.log               mysql.log.4.gz
    dmesg               kern.log.1             news
    
    I looked at syslog and it was empty, what log file I am to look at?
    Thanks
     
  7. ababneh

    ababneh New Member

    Anyone with knowledge in ispconfig out there to try help me out here??


    :confused::confused:
     
  8. tahunasky

    tahunasky Member

    Do you have the server that bind is running on set up as a dns server in your /etc/network/interface flie ?

    auto eth0
    iface eth0 inet static
    address 173.333.222.105
    netmask 255.255.255.0
    network X.X.X.X
    broadcast 173.333.222.255
    gateway X.X.X.X
    dns-nameservers 127.0.0.1 8.8.8.8 8.8.4.4

    If you dont have 127.0.0.1 added, bind will only look up the external dns servers (eg: 8.8.8.8 and 8.8.4.4 in above case. ) to get an IP address and act as a dns cache. So any local records will not be looked up.

    check /etc/resolv.conf and see what the nameserver settings are.
     
    Last edited: Jul 24, 2013
  9. ababneh

    ababneh New Member

    Thanks for the reply. I am certain that you pin pointed where the problem is, but so far I couldn't correct it.

    So here is what I found: by running nano /etc/network/interfaces I got

    Code:
    auto lo
    iface lo inet loopback
    auto eth0
    iface eth0 inet static
        address 173.333.222.105
        gateway 173.333.222.97
        netmask 255.255.255.240
    and by running nano /etc/resolv.conf I got:
    Code:
    nameserver 208.xx.xxx.170
    nameserver 64.xx.xx.2
    where did these name servers ips come from?

    anyway I changed my network/interface to:

    Code:
    auto lo
    iface lo inet loopback
    auto eth0
    iface eth0 inet static
        address 173.333.222.105
        gateway 173.333.222.97
        netmask 255.255.255.240
        network 173.333.222.0
       boradcast 173.333.222.255
    
       dns-nameservers 127.0.0.1 208.xx.xxx.170 64.xx.xx.2
    then restarted networking /etc/init.d/networking restart
    but still site is not resolved yet!

    could you plz point out what I am doing wrong ??

    Thanks again
     
  10. Turbanator

    Turbanator Member HowtoForge Supporter

    What are those dns server you have listed, are they for your local isp? For testing you may want to use the 8.8.8.8 and 8.8.4.4 (those are google dns).

    Can you post your server config Dns tab?

    In Sever config, make sure to set your gateway even though I doubt it'll make a big difference.

    Also, when you say you cannot resolv the website, are you testing inside the network or from the outside? (makes a big difference).
     
  11. Turbanator

    Turbanator Member HowtoForge Supporter

    also pleas post your bind config and specifically what is the parameter for listen-on.
     
  12. till

    till Super Moderator Staff Member ISPConfig Developer

    Please take a look at the syslog file. There is just one file with that name in this directory
     
  13. ababneh

    ababneh New Member


    Here is my Server Config tab
    [​IMG]

    The snapshot was taken before I set the gateway to 173.333.222.97 (didn't make a difference).

    I rechecked /etc/resolv.conf and now it shows this:


    Code:
    # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
    #     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
    nameserver 127.0.0.1
    my /etc/network/interfaces looks like:

    Code:
    auto lo
    iface lo inet loopback
    auto eth0
    iface eth0 inet static
        address 173.333.222.105
        gateway 173.333.222.97
        netmask 255.255.255.240
        network 173.224.222.0
       boradcast 173.224.222.255
       dns-nameservers 127.0.0.1 8.8.8.8 8.8.4.4
    
    
    I am testing from outside the network. ip address resolves, but not www.site.com
     
  14. ababneh

    ababneh New Member

    Code:
    
    options {
            directory "/var/cache/bind";
    
            // If there is a firewall between you and nameservers you want
            // to talk to, you may need to fix the firewall to allow multiple
            // ports to talk.  See http://www.kb.cert.org/vuls/id/800113
    
            // If your ISP provided one or more IP addresses for stable
            // nameservers, you probably want to use them as forwarders.
            // Uncomment the following block, and insert the addresses replacing
            // the all-0's placeholder.
    
            // forwarders {
            //      0.0.0.0;
            // };
    
            //========================================================================
            // If BIND logs error messages about the root key being expired,
            // you will need to update your keys.  See https://www.isc.org/bind-keys
            //========================================================================
            dnssec-validation auto;
    
            auth-nxdomain no;    # conform to RFC1035
            listen-on-v6 { any; };
    };
    
    

    /etc/bind/named.conf.local is empty file
     
  15. ababneh

    ababneh New Member

    I looked at syslog file and it is blank (0 lines)
     
  16. till

    till Super Moderator Staff Member ISPConfig Developer

    And you were logged in as root user while lookin into that file?
     
  17. ababneh

    ababneh New Member

    Yes.

    Could you look into my server and ispconfig setting? I could pm you my server info.


    Thanks
     
  18. Turbanator

    Turbanator Member HowtoForge Supporter

    Just to make sure, you have ns1.example.com registered with a glue record at your name register right?

    Also, please post your server config->DNS tab.
     
  19. ababneh

    ababneh New Member

    Yes my name servers ns1 and ns2 are registered with a glue record (used them
    before ispconfig on kloxo and worked)

    here is my dns server config

    [​IMG]


    Thanks
     
  20. Turbanator

    Turbanator Member HowtoForge Supporter

    what's your output of:

    /etc/init.d/rsyslog status

    ?
     

Share This Page