How to Setup a DNS Server in Ubuntu

Would you like to setup a DNS Server in Ubuntu? How about setting up a private internal domain name at home? Well, you’ve come to the right place. There are number of tutorials on the internet showing you how to setup a DNS Server with Ubuntu using Bind 9. So, why another how-to document? That’s a good question. I’ve decided I needed to write a simple tutorial that anyone with a little bit of Linux knowledge would be able to follow. In the process, I hope readers are also able to learn how DNS works. Ok, let’s jump right to it!

What is DNS?

First of all, let’s cover the basics. What is DNS? DNS stands for Domain Name Server. It’s a service that runs on a server that translates humanly recognizable domain names such as or into its assigned IP addresses. If the DNS server does not recognize the domain name being requested, it will forward the domain name request to another DNS server and so on until the name is resolved.

A typical DNS request is when someone is accessing a website. Let’s use the domain as an example. When a user clicks a Yahoo link or types the Yahoo URL on the address bar of the browser, the DNS server processes the domain request. If it doesn’t find on its DNS table, it will forward the request to another DNS server with a higher authority and so on until it finds a server with the URL entry. The IP address information is then sent back to the user’s browser. If the domain name is not found, a “server not found” message is displayed on the browser.


Enough with the DNS background. Let’s now start configuring our own DNS server. Let’s assume that we have the following: we want to create a private internal domain name called, our private internal network is 192.168.0.x and our router and gateway is set at Let’s assume all devices are going to be configured with static IP addresses. Normally, most computer systems nowadays are configured to automatically obtain IP addresses from the DHCP server/router. In this example, we will use static IP addresses to show how DNS works. Finally, we have 3 computers connected to our network:

  • Ubuntu Server, the DNS server –
  • Ubuntu Desktop –
  • PC –


1. To install the DNS server, we need to install Bind 9.

sudo apt-get install bind9

2. Let’s configure Bind. We need to touch 5 files.

We will edit 3 files.

  • /etc/bind/named.conf.local
  • /etc/bind/named.conf.options
  • /etc/resolv.conf

We will create 2 files.

  • /etc/bind/zones/
  • /etc/bind/zones/

A. First step. Lets add our domain zone –

sudo vi /etc/bind/named.conf.local
# Our domain zone
zone "" {
   type master;
   file "/etc/bind/zones/";
# For reverse DNS 
zone "" {
   type master;
   file "/etc/bind/zones/";

Save file. Exit.

We just created a new domain. Please note: later we will create two files named and files. Also, notice the reverse IP address sequence in the reverse DNS section.

B. Let’s add the DNS servers from your ISP. In my case, I’m using Comcast DNS servers. You can place the primary and secondary DNS servers here separated by semicolons.

sudo vi /etc/bind/named.conf.options
forwarders {;

Save file. Exit.

C. Now, let’s modify the resolv.conf file found in /etc and place the IP address of our DNS server which is set to

$ sudo vi /etc/resolv.conf

D. Now, let’s define the zones.

sudo mkdir /etc/bind/zones
sudo vi /etc/bind/zones/
@ IN SOA (
);  IN      NS
ubuntudesktop  IN      A
www            IN      CNAME      ubuntudesktop
pc             IN      A
gw             IN      A
                       TXT        "Network Gateway"

The TTL or time to live is set for 3 days
The nameserver is defined
ubuntudesktop, pc and gateway are entered as an A record
An alias of www is assigned to ubuntudesktop using CNAME

E. Let’s create a “” file for reverse lookup.

sudo vi /etc/bind/zones/
@       IN      SOA (
        IN      NS
1       IN      PTR
10      IN      PTR
11      IN      PTR

3. Let’s restart Bind to activate our latest changes.

sudo /etc/init.d/bind9 restart

4. Finally, let’s test our new domain and DNS entries.


$ dig


nslookup gw

5. That’s it.

106 thoughts on “How to Setup a DNS Server in Ubuntu

  1. Thanks… after three other how to’s this one worked fof my setup. I was going crazy trying to figure out why my internal ip’s wouldn’t resolve.

  2. I just study Linux. And I want to know how to set up DNs, Mail Sever and Web Server in my Linux(Only one pc or labtop).
    Thanks for reply,..

  3. Great work.
    Liked it loads, easy to understand.
    I have a question though:
    I have about 10 windows work station and two linux boxes. i want to be able to refer to each PC or System with its name. Say, i want to be able to ping them by their names e.g instead of pinging a system with it’s IP address, i want to ping it with it’s name; like thing : ping PC-ubuntu-desktop instead of ping How can i achieve this please.

  4. Hi Kay,

    1. First, you will need to assign a static ip addresses to all your workstations. The last thing you need is a host with a different ip address each time you are connected to the network.

    2. Second, you need to enter several A records to your zone file, e.g. /etc/bind/zones/ in this example.

    ubuntudesktop-1 IN A
    ubuntudesktop-2 IN A
    ubuntudesktop-3 IN A
    ubuntudesktop-4 IN A

    and so forth….

    3. For reverse lookup, make the appropriate entries to your reverse DNS file, in this example. Here, we are making a reverse DNS entry for ubuntudesktop-1 at ip

    11 IN PTR

    Don’t forget that period in the end of the domain.

    Hope that helps.

  5. Dear Ulysses,

    What do I need to do if I need to use the same DNS server for several subnets, such as:

    Would it work if I made a separate reverse dns entry in named.conf.local for each subnet and create a separate file for each entry?

  6. Yes, creating 3 reverse DNS entries in named.conf.local and making 3 separate reverse files in /etc/bind/zones/ should do the trick. Let me know how it goes.

  7. I haven’t gotten it to work. The actual subnets I am using are:

    I have the Ubuntu Server 7.10 named GutsyServer at:

    I have the Windows XP client named Client-B3 at:

    I wonder if I named the reverse-dns files correctly. If I want to use just one reverse-dns file for a network, could I just create a file named In the file I made reference to Client-B3 such:

    11.20 IN PTR

    Is that the correct way to do it?

    I have tried using two separate reverse-dns files, one for and one for, but I could not get it to work. In each file I stated the SOA. Is that correct? I wonder if that is the source of my error.

  8. I am able to do a tracert from Client-B3 to GutsyServer, but for some reason the browser will not work with the internet? It seems like internally the DNS server works, but will not work with the ISP’s DNS server? I made sure the forwarders are correct. Is there something else that needs to be configured?

  9. Daniel, I thought about this for a little bit. I haven’t use multiple multiple networks locally, much more use DNS across 2 or multiple networks. The rule is to always get your network working first. Make sure you can ping the DNS server from all the networks.

  10. I have already gotten the network working. When I use Windows 2003 Server everything works smoothly. When I use Ubuntu as a DNS Server I am able to resolve dns names from the server itself, including I checked it with nslookup. When I try to use nslookup from one of the clients that I’ve assigned to the DNS Server with the A command and the PTR command, I am successful. But when I do nslookup for from the client, I get a message saying that the query was denied. It seems that the ISP’s DNS servers are rejecting my DNS server’s request for a query when I do the request from a client. This is odd to me. I’ve looked at about a dozen tutorials. None of them address this issue. I wonder if there is something else involved rather than DNS, like perhaps ldap.

    In any case, thanks for the reply.


  11. I have a dns cache defined as “home”
    $TTL 3D
    @ IN SOA ns1.home. admin.home. (


    home. IN NS ns1.home.
    server1 IN A
    www IN CNAME server1
    and my reverse lookup is
    $TTL 3D
    @ IN SOA ns1.home. admin.home. (

    IN NS ns1.home.
    3 IN PTR server1.home.
    I have just installed apache and havent touched its default config yet. When I type

    server1.home –> it works (apache default page)
    but, when I type

    home –> Works (apache default page)
    server2.home — > Works (apache default page)


    When I type any other canonical, like server3.home or server100.home, it doesnt work.

    I have cleared cache in firefox, but still result is the same. From where is it finding server2 or just home?

    I am a bit confused, any tip would help. Thanks.

  12. I read the stuff about the ibuntu server and i think you did an excellent job.I have been for sometime now been working how to configure an ubuntu dns server.The stuff is very simple and i wish to say CONGRATULATIONS.I have learnt lots more from you.
    I want to know if you also do anything on configratioon of an ubuntu proxy server.
    Best wishes to you.You are just too wonderful.

  13. Hi Ulysses,

    I liked your tutorial about setting up DNS for a local network and followed directions to try and set up mine. Apparently I overlooked that it was for a local network so after a day of trying (and not getting it to work) I woke up the next day and realized I may need a tutorial for a web server rather than a local network. Duh! So, do you have a tutorial to set up DNS for a web server? If not can you point me one? I am trying to set up Apache on ubuntu on a server at home and want to handle my own DNS. I have a few towers and am wondering if I should setup DNS on the same tower I have my www files/Apache on, or set DNS up on a seperate tower? I have 5 static IP addresses I can use.

    Thanks Ulysses!!

  14. Ya hurre
    But can you tell me that how to add the ubuntu clients in the dns and how to add the windows machines in this domain e.g.

  15. I was wondering if i set up a dns server from home do i not need to register my domain name? or if can it work as a redirect service for people trying to access my site externally?

  16. dude, this is wonderfull im so glad and thankful that u wrote this. it worked perfectly.

    thanx a lot once again,

    take care

  17. If I was to have a purchased domain : and had it point to my home static IP address, would this work as a real host. Assuming I have apache installed and the firewall configured properly.

  18. Hello there,

    I have a question that maybe someone can help me. I try to setup a server (Ubuntu 8.04) to be mail, ftp, www, dns, dhcp server. The Linux Box has 2Networks card, one for ISP with public STatic IP :

    ETH1 : (ISP)
    eth1 IP :
    Subnet :
    gateway :

    DNS :

    ETH0 : (Internal)
    eth0 IP :
    subnet :
    gateway :

    DNS :

    Any idea to setup DNS and DHCP server, i don’t know nothing for now about Linux, i’m studying now.


  19. If I was to have a purchased domain : and had it point to my home static IP address, would this work as a real host. Assuming I have apache installed and the firewall configured properly.

  20. hi ulysses.
    I just want to make a simple thing. I’m really new to Linux.

    I got a static ipaddress in my dormitory. Here is what I got from TCP/IP properties on my windows.
    IP address
    subnest mask
    default gateway

    preferred DNS server:
    alternate DNS server:

    I have changed the third one (IP address, sbnt mask and gatwy) through this command sudo vi /etc/network/interfaces

    now, how can I put the on my ubuntu? where should I put it?

    Really thanks

  21. floating away:

    edit your /etc/resolv.conf file


    hope that helps.

  22. Thanks for the post, very straightforward – to the point. I’m in the process of setting up name servers for the first time and this is a big help – setting up a private system to play with. It’s great.

  23. I found this very useful. Now I want to take this one step further by setting up a load of forward aliases (for HTTP headers) to be used setup a number of IIS (web) sites on the same server which happens to be a KVM machine running win2003. so if my domain was “” should I able to ping ssp or mysite or team and if so what would be their qualified names.. I have tried to ping and it times out where as is ok

    win2003-01 IN A
    www IN CNAME win2003-01
    ssp IN CNAME win2003-01
    Mysite IN CNAME win2003-01
    team IN CNAME win2003-01

    Thanks in advance

    1. Daniel,

      Have you tried this format instead of an ip address?

      `subdomain1 IN CNAME`


      `ssp IN CNAME`

      It’s worth a try.

      1. Thanks for your help. In the end I just changed the order of the DNS servers and this worked. I think this article could do with an example windows client TCP/IP configuration which ensures I can resolve my local machine/aliases addresses as well as all my other www adresses.

        Also I guess we need to automatically start bind9 automatically on server power up. Have you done this?



  24. Would have been great if the following had been explained instead of just saying here it is, use it:


    @ IN SOA (
    ); IN NS
    ubuntudesktop IN A
    www IN CNAME ubuntudesktop
    pc IN A
    gw IN A
    TXT “Network Gateway”

    Unfortunately I didn’t learn anything from the tutorial except how to copy and paste 🙁

  25. Being on Linode, the service offers its own DNS server, and I know that many web hosts, VPS, and dedicated server companies also do the same. However there are real benefits in running your own DNS server, with editing speed and ease of use being one of them. Although for full disclosure I have decided to use Linode’s DNS service to reduce load on my own server. Nonetheless, this guide will go through the relatively simple process of setting up a DNS server in Ubuntu Linux.

    The first thing one needs to do is to install Bind. Bind is a file based DNS server that is pretty simple to use once you understand it; however there are multiple files to edit. When installed using sudo apt-get install bind9 a default configuration file is created for you as well.

    The second step is to update the /etc/bind/named.conf.local configuration file to add our zone. Our zone specifies what domains this DNS server is responsible for. For this tutorial I will use as the sample domain. Therefore in name.conf.local you will add both the zone definition as well as the reverse DNS entry for your IP. They should be written as:

    zone “” in {
    type master;
    file “/etc/bind/zones/”;
    allow-transfer { any;};

    zone “” {
    type master;
    file “/etc/bind/zones/”;

    Please remember to replace with your real domain name and (written in reverse) with your real IP address.

    The third, and optional step, is to configure some default DNS server options. The file used to do this is /etc/bind/named.conf.options The main settings that ought to be of interest are: forwarders, notify, and directory. Forwarders specify which DNS server should be used when your DNS server is queried for a domain that it is not responsible for. Notify specifies whether slave DNS servers should be notified of changes when they are made on this server. Directory specifies where DNS configuration files should be looked for if a full file parameter is not used in our zone entries in step two. Samples of three options are:

    forwarders {;; }
    notify { yes; }
    directory { “/dns/zones”; }

    The fourth step in our Ubuntu DNS server setup is creating our zone file. I am assuming that you did not specify a custom zone directory like the options example above. Therefore you will want to create your zone files in the folder /etc/bind/zones by just creating and filling it with entries such as:

    // TTL = Time to live for records on slave (2 days)
    // 2009030700 = Serial for Bind to check whether an update has occured
    // 6H = Time between refresh requests
    // 1H = Time between retry attempts
    // 1W = Expiry time for the record on slave
    // 1D = Amount of time an invalid response is stored on slave
    $TTL 2D
    @ IN SOA (

    // = Name server
    // = Mail server
    // = HTTP server
    // * = Wildcard entry IN NS IN MX 10
    ns1 IN A
    www IN A
    mail IN A
    * IN A

    The above zone definition file sets some basic servers and points them to the computer with the IP address You can host each service on a different IP if they are on different servers. You can also point to other name servers by using CNAME instead of A records. Please note that all domain names end with a “.”.

    While a reverse DNS zone file is optional, for things like mail servers if a reverse entry is not available it can be flagged as a possible spam server. So it is good practice to do it. For our example zone file the reverse would be in the file and look like:

    // TTL = Time to live for records on slave (2 days)
    // 2009030700 = Serial for Bind to check whether an update has occured
    // 6H = Time between refresh requests
    // 1H = Time between retry attempts
    // 1W = Expiry time for the record on slave
    // 1D = Amount of time an invalid response is stored on slave
    $TTL 2D
    @ IN SOA (

    IN NS
    1 IN PTR

    After the files have been created restart bind through the command /etc/init.d/bind9 restart and using the command dig @ to use your own DNS server to query the record If an answer is given (should look like your entry for www in the file) then everything is set up correctly. You should now update your domain name registar’s DNS records to point to your server.

  26. Instructions are clear and easy to follow. I set this up relatively quickly and am able to resolve by using the dns name setup in the config files. I dropped the firewall and added the linux IP to my Windows system dns entry under the network config. I’m trying to use the dns server on my windows box now but cant resolve unless I use the entire domain name. On my linux box I can ping gw but on my Windows box I have to ping in order for it to resolve. If I ping gw from my windows box it does not resolve. Does anyone know of an additional step needed to use the dns on all local computers without having to type in the entire domain name? Thanks in advance.

    1. Dennis, The only thing I can recommend is to make sure your Windows clients are pointing to your internal DNS. The other thing I did was added this: ‘ IN A’ in the zone file. Just replace the xxx with your ip address.

  27. Nice job on your website here. I too am attempting to build a site for my small home construction business. Its a long story, but I’m not very good at this techy stuff. I like the site theme you have used here and was wondering what it was named? I bought Brian Gardner’s theme but just gave up. I want to supplement my bills in the winter time and thought I could do it. Its a long road ahead. Anyway, I just stumbled across your article here and am glad to have met you. virtually of course :-).

  28. Hey! Thanks for not obeying standard practices, posting any warnings, or stating which systems versions you’re using.

    My computer, ubuntu 9.10, no longer goes online after following these instructions. It’s offline totally. Thanks, bud.

    TO ALL USERS: Use Webmin. I’ve been able to ‘mostly’ repair my system and set things back to defaults using webmin. I should have used webmin in the first place before taking advice from self-declared ‘guru’s.

      1. Hey, thanks for the reply 🙂

        My resolv.conf is (as expected) built automatically:
        $ sudo less /etc/resolv.conf
        # Generated by NetworkManager
        domain 532
        search 532

        ^ that nameserver 0.1 is the address of the router. 532 is the LAN’s SSID. Any pointers? I would think that’s right (not only because its automated) because the request should just be passed on to the nearest authority (the router), right?

    1. Hey, I’m going to start a thread on and stop abusing your comments area – sorry 🙁

      To answer your question, this is on a laptop (not a server) in a home network (not a business), so there’s no domain (no name servers or anything in this house). The whole network is setup fairly close to the defaults of our Dlink router. If you have any suggestions what I could look up to give me a lead, that’d be awesome! (ps, great article, I’m going to set up a domain just for kicks pretty soon)

  29. I think am stuck here, how come u get to configure you DNS over static IP? Secondly, am trying to set up one on with DHCP but can’t get it to work. I can’t even ping with the hostname. I need your help here.
    Do reply.

  30. Ulysses, thank you. I found them via google (didn’t expect it to be that easy), and discovered that they’re also in my router (linksys WRT54G) on the status tab.

  31. Hi Ulysses,

    I’ve got bind up and working thanks to your tutorial.
    I don’t know if it’s possible but can I define a single host that is not part of my domain?

    I’ve got a domain name which I can’t access local due to anti-spoofing on my firewall, so I would like my bind server to anwser a query for the address with the equivalent local ip.

    Does that make an sense?


      1. Ok,

        I have a “home” domain, lets say that I have bind setup and working for.

        I also have a legitimate domain (free D-DNS service) which allows me to access my server externally without needing a fixed ip address, this all works fine.
        However if I try to reach (external ip address) from my home network my router basically denies the request as it thinks it’s spoofed.

        What I would like is my local DNS to respond with the internal address (192.168.0.x) when I lookup from my home network rather than the authortative address from (external address), I suppose for my local DNS server to respond with a local ip instead of forwarding the request even though the domain name is different.

        Any clearer?


        1. Thanks for the clarification. Yes, it makes a whole lot of sense now. You can try several things. The first one is probably the easiest. #1 You can add to your hosts file. For example, if your server is, then you would add ‘’ to your hosts file. #2 You can add a second domain to your local DNS. It’s similar setup to how you did One last thing, make sure your resolv.conf is pointing your local DNS. It’s in my example above.

  32. Hi Ulysses,

    I’m avoiding the hosts file option as i would need to change it whenever I took my laptop out of the house…

    I did try adding to named.config.local which worked, however I don’t really want a “fake” master as I then can’t resolve any other addresses, or am I missing a trick here?

    Thanks again,

  33. Hi Ulysses,

    I followed exact steps but bind9 process failing to start.
    Could you please help me on this?

    Thanks in advance

  34. Hi,

    I am getting following error.

    please help me.


    ; <> DiG 9.7.0-P1 <>
    ;; global options: +cmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 10185
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0

    ; IN A

    ;; Query time: 0 msec
    ;; SERVER:
    ;; WHEN: Sat Nov 20 21:45:50 2010
    ;; MSG SIZE rcvd: 33

  35. Hi,

    I am getting following error.

    please help me.

    zone NS ‘’ has no address records (A or AAAA)
    zone not loaded due to errors.

  36. when i perform sudo /etc/init.d/bind9 restart
    command am getting an error , etc/default/bind9: 5: Syntax error: Unterminated quoted string

  37. when i perform sudo /etc/init.d/bind9 restart
    command am getting an error , etc/default/bind9: 5: Syntax error: Unterminated quoted string

    1. I would check the config files. Look for entries involving quotes that needs to be closed/terminated. You just have a missing end quote. That’s all.

  38. @Ulysses Yeah that’s definitely the most compact, straight-forward, tutorial on setting up bind that I’ve ever read.

    That said there were a few more steps need to get both the Linux and Windows machines running on my network, you can see the successful results of that endeavor over at:

    (Basically the question’s answer in the link above handles the Windows Advanced TCP/IP settings side of things.)

  39. Hi Andrew, thanks for sharing the solution. When you ping, do you use the host name only or the fully qualified domain name? Just curious. It looks like adding the DNS entry in Windows fixes that issue.

  40. Thank you for this very concise and helpful information. This is sooo exactly what I was looking for I can’t even explain it. The one thing I had to figure out was to replace ‘ns’ in a few places with the hostname I’d given the server hosting the DNS server.

  41. No luck,
    trying this on Ubuntu server 10.10, and it doesn’t work. I’ve actually copied the examples straight from the site just for the heck of it to see if I could get it to work using your example.

    Nslookup and DIG both give me SERVFAIL results.

  42. The odd part is that I’ve been able to empty out my resolve.conf and named.conf.options file completely and outside DNS requests still work (despite restarting bind). How is it getting that information?

    For giggles I’m restarting the server… very odd.

  43. Even weirder.. Reverse lookup works… but forward lookup doesn’t. I used named-checkzone and both of the zone files are happy. Not sure why this is failing.

  44. Now I’ve got reverse lookup fully working, however the best I can get for forward lookup is an “NXDOMAIN” status in DIG (which is a step up from SERVFAIL from before).

  45. Correction… and this is really odd. I had fatfingered my resolv.conf file to use my router’s IP address (gateway). With this set up… forward lookups were in a an NXDOMAIN state, and reverse lookups were in an NOERROR state. Correcting it to the DNS server address of has now put it back in a SERVFAIL state. For the hell of it, I’ve completely unplugged any external source just to see if I can get this working as a private setup without any forwarding.

  46. Hi Ulysses, thanks a lot for this very good tutorial. But I am stuck somewhere at the Comcast IP. Suppose I only want a local connection between my server and another terminal laptop and I want to use the default domain ( I have a wireless router whose control panel is activated by and this router has already given two IP addresses to my server and my other laptop (server the other laptop was given ( I imagine that after the setup has completed I would be able to open the website ( hosted on my server from the other machine.
    I would be so grateful if you would be able to explain for me what to do in terms of IP addresses and any other thing. Much thanks

  47. I hope I’m able to answer your question correctly. You would like to be able to connect to any desktop, laptop or server on your local network using a hostname or a fully qualified domain name. To do this you need to point the DNS entry of each machine to your DNS server. In this example, let’s assume your DNS server is Typically, the DNS entries point to your router, If you make that change to every machine on your network, you should be able to resolve a hostname in your local network as well as the internet, assuming your DNS server is routing properly.

  48. Thanks for your reply. Let us suppose that I am at the stage of

    sudo vi /etc/bind/named.conf.options

    forwarders {;

    what IP address I should put instead of (because this is not my ISP address). Did you mean that I should put instead? How to point the DNS entry of each machine to my DNS server- can u please explain practically how to do this. My assumed server IP is and my other terminal laptop is

    Assume also that I am going to put a web page hosted on my server so that it can be reached from my terminal just by writing the domain name

    Your help is very much appreciated as I am still very new in this field, very interested in learning.

  49. The forwarders should be the DNS server of your ISP. To resolve your local domain, you need to change the network settings of your terminal laptop to use as DNS instead of

    In Windows, you need to go to Control Panels, Network Connections, Properties, TCP/IP and then enter as your DNS.

    I hope that makes sense.

  50. I thought that you might help me better if I explain my environment settings. I have two laptops and I am intending to make one of them as a server for learning purposes. My router has given the server the IP and the other was given the IP I am intending to make the first one as the server. The router IP is . As I am still new in this field, I was totally confused on the number of parameter used on your tutorial. I am especially confused about the IP to use for the DNS server. Suppose I am not able to get the static IP; will it be possible to use the local IP(s) mentioned in this message?. And then what IP should be used in the forwarder. My Terminal shows the prompt


    I would be so grateful if you reformulate your tutorial in view of my environment settings to enable me to build the local domain

  51. If your DNS server is, then you need to change the DNS network setting on your laptop to point to Simple.

  52. Had same problem but all I did is restart the bind9 process anyway and that was all. I used the line below:

    $ sudo service bind9 restart

    To explicitly confirm bind9 is running, use this line:

    $ service bind9 status

  53. Thanks a lot for all. I could reinstall Bind again and no problem with it now. Now I installed apache22 on a Windows 7 and and I created a testing site on a folder I called c:\mysites and a server name I called it site1.local. And all the necessary setting I have done in the httpd.conf file. I also tweaked the hosts file inside Windows 7. I am intending to request the name http://site1.local from my other laptop browser (Ubuntu 10.10) but I am not succeeding. I am getting the error (Forbidden

    You don’t have permission to access / on this server) please note that I also opened port 80.

  54. i m getting following error-

    sudo /etc/init.d/bind9 restart
    * Stopping domain name service…bind9 rndc: connect failed: connection refused

  55. Whenever i am trying this domain name system for my ubuntu system. it is not running. is any additional configuration or packages need to config dns. now i m using ubuntu 10.10. please help me..

  56. This seems kinda pointless. To quote yourself ..
    “Let’s assume all devices are going to be configured with static IP addresses. Normally, most computer systems nowadays are configured to automatically obtain IP addresses from the DHCP server/router. ”

    Why give an example that is not applicable to “most computer systems nowadays”?

    1. I think you are confusing DHCP which automatically assigns IP addresses to computers vs DNS which makes server names stick that’s accessible from any computer in the same network. That’s what we are after here. We want DNS to work internally as well as forward outside of the internal domain.

Comments are closed.