1753455 Members
6090 Online
108794 Solutions
New Discussion

Re: configure DNS server

 
SOLVED
Go to solution
Joyce S. Solomon_1
Occasional Advisor
Solution

Re: configure DNS server

Hi,

As a matter of fact, i did configure my HP-UX box to be the primary DNS.

Here is what i did , hope this helps you

1. The primary dns machine,
a) create a list of host names and IP that will be used as the primary dns and the secondary dns
b) create a directory /etc/named.data, in this dir create a file name 'param', in this file list these down,

-d
-n
-z
-b /etc/named.boot
-s

The file 'param' will be actually used to create the DNS data file.

c) Run the command
hosts_to_named -f param
This command creates the server configuration and data files

d)go to /etc/rc.config.d dir and modify the file namesvrs, set the NAMED variable to 1. this is to allow the named process to start at every boot

e) start the DNS with these command
/sbin/init.d/named start

after this the name server should be running

2. Configuring the secondary DNS server
a) at the secondary server, create a dir /etc/named.data
b) copy the boot.sec and boot.sec.save from the /etc/named.boot dir from the primary server to this secondary server.
c)copy the db.127.0.0 and db.cache file from the primary server to sec server's /etc/named.data dir
d) If you did copy the boot.sec.save from the primary server, this enables the data files to be created also in the secondary server, so you also need to copy all files from /etc/named.data from the primary server
e) Change the variable NAMED to 1 at the /etc/rc.config.d/namesvrs on the sec dns server
f) start the named process using /sbin/init.d/named start

3) configuring the client server
a) at the client machine, in the file /etc/nsswitch.conf, you can specify below:

hosts: dns files

this means that the the DNS will be used first instead of the /etc/hosts file for host name resolution

b) at the /etc/resolv.conf file specify below:

nameserver
nameserver


After all this, you can use the nslookup command to test the DNS from the client

I hope this helps.

Regards