Find the answer to your Linux question:
Results 1 to 8 of 8
Set up a server with Bind, Dovecote, Apache etc. Registered a domain and made all the necessary things for it to work. The server can send/receive mail on my domain, ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2009
    Posts
    59

    How to test if bind9 is really working?


    Set up a server with Bind, Dovecote, Apache etc. Registered a domain and made all the necessary things for it to work.

    The server can send/receive mail on my domain, but when I try to look up the site I have it returns a lookup failure. I know Apache is working as I can browse the site when I used my ip address but I can't when I use the domain name.

    Anyone got a few tricks I could try to dumb down and find the possible failures I did when setting this up?

  2. #2
    Super Moderator Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,864
    You can use 'nslookup' - if you execute it on its own it'll give you a simple shell. Give it the command 'server' followed by an IP address and it'll make all its lookups to that server. You can then type in host names and watch them resolved by the machine you're looking at.
    Linux user #126863 - see http://linuxcounter.net/

  3. #3
    Just Joined!
    Join Date
    Oct 2009
    Posts
    59
    Thanks for the info, didn't know I could run nslookup without an ip.
    Tried nslookup with the global ip address, and it returned:
    Code:
    > Google
    Server: 194.1.130.117
    Address: 194.1.130.117#53
    
    ** server can't find www.google.com.andreansky.eu: SERVFAIL
    Now if I use my local ip address as the server name, it works and returns positive lookbacks.

    Code:
    > Google
    Server: 192.168.77.87
    Address: 192.168.77.87#53
    
    Non-authoritative answer:
    Google canonical name = Google.
    Name: Google
    Address: 74.125.87.99
    Name: Google
    Address: 74.125.87.104

    What does that mean for me?

  4. #4
    Super Moderator Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,864
    Looks like it's working - perhaps you should try it with a local address too? Your own DNS server is the only one that will be able to do the name resolution for those.

    The 'Non-authoritative answer:' bit means it's picked up the information out of its cache rather than going and asking other name servers to look this up. This is normal behaviour, used to speed up name searches across the internet.
    Linux user #126863 - see http://linuxcounter.net/

  5. #5
    Just Joined!
    Join Date
    Oct 2009
    Posts
    59
    I tried disabling bind9 and trying nslookup and it worked even when bind was not running. Odd.

    Can it get DNS entries from the cache even when the server is not running?

  6. #6
    Super Moderator Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,864
    No, the server should time out. Something else is going on. Is the named daemon running even though you've turned off the bind service? Are you sure you've got the right IP addresses?
    Linux user #126863 - see http://linuxcounter.net/

  7. #7
    Just Joined!
    Join Date
    Oct 2009
    Posts
    59
    The ip address is correct. When I run ps it show this, which is odd as bind should be stopped.
    Code:
    root@BigAA:~# ps -A|grep named
    13054 ?        00:00:00 named
    I'm stopping bind through init.d
    Code:
    root@BigAA:~# /etc/init.d/bind9 stop

  8. #8
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    It all depends on where you are doing your lookups from. If you are doing lookups from the DNS server itself ensure that the resolv.conf file is pointing to the ip address of the DNS server.

    The DNS server/process isn't stopped as you haven't stopped it. Look at your output. The process is called named and you should be using named to stop it.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •