Flux rss

Intranet - Installing a DNS

Packages needed for installation

A DNS (domain name server) is a server that links names to the IP addresses of computers on a network. In order to set up such a server, it is necessary to install bind and named. They can be downloaded as RPM files (for Mandrake they are bind-8.2.2P5-1mdk.i586.rpm and nameserver-6.0-3mdk.noarch.rpm; other distributions can be downloaded from freshmeat.net or rpmfind.net)

The server tuxserver (with the IP 192.168.1.1) is going to be configured as a domain name server, so as to allow clients (a Linux machine with the IP address 192.168.1.20 and a Windows machine with the IP address 192.168.1.30 - the subnet mask is 255.255.255.0) to access the services bearing the following names:

  • web server: www.tuxdomain
  • SMTP server: smtp.tuxdomain
  • POP server: pop.tuxdomain
  • News server: news.tuxdomain

Installing packages

Installating RPM packages is very simple. Just type the following commands:

rpm -ivh bind-8.2.2P5-1mdk.i586.rpm 
rpm -ivh caching-nameserver-6.0-3mdk.noarch.rpm

Before you start

Before you configure the name server, you have to edit the file /etc/resolv.conf so as to declare the domain name of your choice (here tuxdomain) and declare the local machine (with the local loop IP address - 127.0.0.1) as a name server.

So you have to make sure that the following lines are found in the file /etc/resolv.conf:

domain tuxdomain
nameserver 127.0.0.1

Adding the domain

After having installed bind and named, you can assign the domain name tuxdomain by editing the file /etc/named.conf:

options {
directory "/var/named";

};

//
// Declaring the reverse lookup zone
//
zone "0.0.127.in-addr.arpa" {
type master;

file "named.local";

};

zone "1.168.192.in-addr.arpa" {
notify no;

type master;

file "tuxdomain.rev
";

};

//
// Declaration for domain name resolution
//

zone "tuxdomain" {
notify no;

type master;

file "tuxdomain"
;

}

The first part serves as reverse lookup, meaning that it is used to find the name of a computer when given its IP address.

Creating zone files

Next, edit the file named.local found in the directory /var/named :

@	   IN	  SOA	 tuxserver.tuxdomain.
root.tuxserver.tuxdomain.


(
1997022700 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS tuxserver.tuxdomain.
1 IN PTR localhost.

Finally, create a file called tuxdomain in the directory /var/named containing the following:

@	   IN	  SOA	 tuxserver.tuxdomain.
root.tuxserver.tuxdomain.


(
1997022700 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum

TXT "Primary DNS server"

NS tuxserver

NS tuxserver.tuxdomain.

MX 10 tuxserver

MX 20 tuxserver.tuxdomain.

localhost A 127.0.0.1

tuxserver A 192.168.1.1

www CNAME tuxserver

smtp CNAME tuxserver

pop CNAME tuxserver

news CNAME tuxserver

tux A 192.168.1.20

win A 192.168.1.30

...

MX is used to specify the name of the SMTP server Here, our server tuxserver hosts all of the services.

For reverse lookup, you need to create a file named tuxdomain.rev within /var/named containing the reverse lookup table:

@	   IN	  SOA	 tuxserver.tuxdomain.
root.tuxserver.tuxdomain.


(

1997022700 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum

IN NS tuxserver.tuxdomain.

1 IN PTR tuxserver.tuxdomain.

20 IN PTR tux.tuxdomain.

30 IN PTR win.tuxdomain.

...

Booting up the DNS

The daemon named (a daemon is an application which runs permanently in the background) may be loaded manually using the command:

/etc/rc.d/init.d/named start
In order to have the daemon named launch automatically when your computer starts, it is helpful to create links using the commands
chkconfig --level 345 named on
chkconfig --level 0126 named off

To test if it is working properly, it is recommended to "ping" the other machines on the network with the command:

ping tux

Michel Maudet

This document entitled « Intranet - Installing a DNS » from Kioskea (en.kioskea.net) is made available under the Creative Commons license. You can copy, modify copies of this page, under the conditions stipulated by the licence, as this note appears clearly.

Résultats pour Intranet Installing a DNS

Intranet - Installing the Linux distribution Mandrake The server can work with any Linux distribution, but we have chosen to use the distribution Mandrake, which has the advantage of being simple to install, and includes a multitude of pre-installed applications. You can find this distribution: On the... en.kioskea.net/intranet/resinst.php3
Intranet - Installing a mail server The most commonly used e-mail server in Linux is Sendmail; however, as it is very hard to configure, we will use Qmail, an alternative e-mail server, instead. Qmail is made up of a group of programs that work with different UID/GIDs, in order to... en.kioskea.net/intranet/resmail.php3
Introduction to setting up an intranet This document explaining how to set up an intranet on a machine running Linux has been made possible through a partnership with www.tldp.org/, whose webmaster (Michel Maudet) is the author of the original document. An intranet is a set of Internet... en.kioskea.net/intranet/resintro.php3

Résultats pour Intranet Installing a DNS

Installing a DynDnsInstalling a DynDns Configuration For DynDns.org For DNS-O-Matic (OpenDNS) Setting as default Other DynDns client under Linux Dyn Dns (Dynamic DNS ) service allows you to alias a dynamic IP address to a static hostname, allowing your... en.kioskea.net/faq/sujet-718-installing-a-dyndns
Installing an easy HTTP proxy-cache (polipo)Installing an easy HTTP proxy-cache (polipo) Intro Quick Installation Allowing hosts on the LAN to connect Changing the port Use a proxy server parent Using an alternative DNS server Disabling IPv6 More info Intro Installing an... en.kioskea.net/faq/sujet-805-installing-an-easy-http-proxy-cache-polipo
Windows XP update refuse to installWindows XP update refuse to install It may happen that updates to your system might refuse to install due to error in file system 32. System32 is an important tool for windows OS. However this file is very vulnerable to Trojan, malware... en.kioskea.net/faq/sujet-429-windows-xp-update-refuse-to-install

Résultats pour Intranet Installing a DNS

Setting up my own DNS ServerHi, I have my own registered domain. I want to set up my own DNS server and host a website completely independent of any third party hosting service. I have Windows Server 2003 and have installed the DNS role and configured it with a single forward... en.kioskea.net/forum/affich-24678-setting-up-my-own-dns-server
Dns wrong?Hello, Actually I have windows millennium installed on my computer and when I load the aol cd in the cd rom tray I get a message that it could not get online that my dns address is wrong. Internet explorer neither don’t work and I tried to ping but... en.kioskea.net/forum/affich-26190-dns-wrong
Dns wrong with aolHello, Actually I have windows millennium installed on my computer and when I load the aol cd in the cd rom tray I get a message that it could not get online that my dns address is wrong. Internet explorer neither don’t work and I tried to ping but... en.kioskea.net/forum/affich-31174-dns-wrong-with-aol

Résultats pour Intranet Installing a DNS

Download Multi InstallBy creating a CD or CDRom, you would definitely like to add it a menu for its launching and a better browse. Muti Install is program moved forward for the creation of menu of kickoff for CD / DVD. He allows so to create numerous programs from the... en.kioskea.net/telecharger/telecharger-755-multi-install
Download Ext2 Installable File SystemIf you currently have Windows running and you realize that you need some files for your work which you have stored on an Ext2 volume of your Linux installation, you no longer have to shut down Windows and boot Linux! Furthermore, Windows will now... en.kioskea.net/telecharger/telecharger-235-ext2-installable-file-system

Résultats pour Intranet Installing a DNS

Linux - Mini HOW-TO Documents The mini HowTo documents are a set of documentations written by different people on very specific topics concerning Linux. Below you will find a (non exhaustive) list of HowTo documents written or translated into French: HOW-To Description 3Dfx-HOWTO... en.kioskea.net/linux/howto.php3
Réseaux - Intranet and extranet An intranet is a set of Internet services (for example a web server) inside a local network, i.e. only accessible from workstations of a local network, or rather a set of well-defined networks that are invisible (or inaccessible) from the outside. It... en.kioskea.net/entreprise/intranet.php3
Installing a network adapter The purpose of this article is to set up a network to enable data exchanges between computers, resource sharing and network games. Is it therefore necessary to install a network card in each computer that may be part of the local area network. The... en.kioskea.net/configuration-reseau/installation-carte-reseau.php3