Suse DNS 10.0 server

From openSUSE


This article is being considered for deletion for the following reason: The same article exists as Suse_10.0_DNS_server.

You are welcome to edit this article, but please do not blank, merge, or move this article, or remove this notice until any discussion has completed.
For more information see the OpenSUSE:Deletion Policy

Suse 10.0 DNS server

Any Linux distro can be used as a DNS, Web, E-mail, and FTP server, and Suse is not an exception. All in one box and one static IP address. That's all you need! (Of course, I am talking about an experimental machine.) The DNS server is very easy to install. You need to install the BIND package, and modified the /etc/named.conf file, and create your own zones files.


Edit /etc/named.conf and add your reference zone files. Right after the first reference zone file, in this case zone "0..0.127.in-addr.arpa", add yours, in my case I added two zone references: enicaragua.net and sixbone.com. Pay close attention to the open and close braces, quotes, and semicolons.


zone "0.0.127.in-addr.arpa" in {

       type master;
       file "127.0.0.zone";

};

zone "enicaragua.net" in {

       type master;
       file "enicaragua.zone";

};

zone "sixbone.com" in {

       type master;
       file "sixbone.zone";

};


Zones files

Suse puts the named dir in /var/lib/named. Here is where your zones file will be located. This is the sixbone.com domain's zone file. Now, we need to test the zone files, so we type: rndc reload, next we run rcnamed start. You should get not erros. Next type rcnamed status, you should see the number of zones running, and the last line will say the server is up and running.

If you get an error, check braces, quotes, and semicolos in /etc/named.conf.

If you want to know more about CNAME, A, NS, etc. Read The DNS & Bind Book

Have you seen those sites that if you don't put the www, you cannot get to it? Well, is all in the zones files. If you check the sixbone.com file, you see one reference with the www and one reference without it. Bingo! By the same token, you create the same way an FTP server, so on and so forth. In the case of a Web server, you need to check your Apache conf files, and make sure that you create your virtual hosts reference as well. This is another topic.

Finally, we run a last check using dig, and this is what I get

DNS is an exciting topic, and these few lines don't even put a dent to it. For example, you need to register your own domain name with a domain name service provider. i.e ns.com, buydomains.com, etc. By creating these zone files in your server, your DNS server is not going to work, I mean, it won't resolve any domain name at all, may be locally.

How does DNS work? Here is a link that explains very well how it works: How DNS works Each domain name must have two DNS servers. Some people name theirs ns1.example.com and ns2.example.com. In my case I named mine: unix.sixbone.com unix is the name of the machine itself, or host name in the UNIX jargon. The first reference in the link above, is the root level. These are a series of machines, 13 total to be exact, distributed around the world. I think Japan has two, Europe has a couple more, the US has the most, etc.

What are the names of these machines? In your /var/lib/named there is a file called root.hint, this file contain the list of the these machines. DNS root servers

The last machine listed in this root.hint file is locates in Paris, France. Just use visualroute.com to find the rest.


--Raxxal 18:46, 13 Jan 2006 (MST)