DNS: Configure a caching-only name server

Share this link

Install the bind package:

# yum install -y bind

Edit the /etc/named.conf file and change the ‘listen-on’ option from 127.0.0.1 to any:

listen-on port 53 { any; };

In the same file, change the ‘allow-query’ option from localhost to any:

allow-query { any; };

In the same file, disable the ‘dnssec-validation‘ option:

dnssec-validation no;

Check the configuration file:

# named-checkconf

Add two new rules to the firewall:

# iptables -I INPUT -m state --state NEW -m tcp -p tcp --dport 53 -j ACCEPT
# iptables -I INPUT -m state --state NEW -m udp -p udp --dport 53 -j ACCEPT

Save the firewall configuration:

# service iptables save

Activate the DNS service:

# chkconfig named on

Start the DNS service:

# service named start

Check the configuration:

# nslookup cnn.com 127.0.0.1
# dig @127.0.0.1 cnn.com
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...

Leave a Reply

Be the First to Comment!

Notify of
wpDiscuz

RHCSA7: Task of the day

Allowed time: 5 minutes.
Create a user account named "tony" with password “redhat” and belonging to a secondary group called “team”.

RHCE7: Task of the day

Allowed time: 10 minutes.
Set up a default secure MariaDB database called maria with a user named muser with all privileges.

Poll for favorite RHEL 7 book

What is your favorite RHEL 7 book to prepare RHCSA & RHCE exams?

View Results

Loading ... Loading ...

Poll for most difficult RHCSA 7 topic

What do you think is the most difficult RHCSA 7 topic?

View Results

Loading ... Loading ...

Poll for most difficult RHCE 7 topic

What do you think is the most difficult RHCE 7 topic?

View Results

Loading ... Loading ...

Recent Comments