Posted by: kezhong | April 28, 2011

Install Caching-Only DNS server on CentOS5.5

Install the BIND software
# yum -y install bind
# yum -y install caching-nameserver*

# cd /var/named/chroot/etc/
# ls -la
total 48
drwxr-x— 2 root named 4096 Apr 29 03:06 .
drwxr-x— 5 root named 4096 Feb 23 06:35 ..
-rw-r–r– 1 root root  3519 Feb 27  2006 localtime
-rw-r—– 1 root named 1230 Feb 23 06:35 named.caching-nameserver.conf
-rw-r—– 1 root named  955 Feb 23 06:35 named.rfc1912.zones
-rw-r—– 1 root named  113 Dec 17 06:52 rndc.key

# cp named.caching-nameserver.conf named.conf
# chown root:named named.conf

Because my customer just wanted to use DNS on his own server, I didn’t need to modify the named.conf file. If he allowed the other servers to access it, I need to change “” and “localhost” in the named.conf file to “any”.
# vim named.conf

Start the named service
# chkconfig named on
# service named start

Modify the /etc/resolv.conf file, and add a line “nameserver” at the top of the file
# vi /etc/resolv.conf

As for the Caching-Only name server on Fedora, Raymond has a good solution.



  1. I found another post

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s


%d bloggers like this: