Install the Bind DNS server in CentOS 6.4
Install the Bind DNS server in CentOS 6.4
I. Introduction
1) CentOS 6.4 64bit minimal
2) bind-9.8.2-0.30.rc1.el6_6.3.x86_64
Ii. Installation
$ Yum install-y bind-utils
Iii. Configuration
A) bind main configuration file
$ Vi/etc/named. conf
//
// Named. conf
//
// Provided by Red Hat bind package to configure the isc bind named (8) DNS
// Server as a caching only nameserver (as a localhost DNS resolver only ).
//
// See/usr/share/doc/bind */sample/for example named configuration files.
//
Options {
Listen-on port 53 {172.31.100.82 ;};
# Listen-on-v6 port 53 {:: 1 ;};
Directory "/var/named ";
Dump-file "/var/named/data/cache_dump.db ";
Statistics-file "/var/named/data/named_stats.txt ";
Memstatistics-file "/var/named/data/named_mem_stats.txt ";
Allow-query {172.31.100.0/24 ;};
Recursion yes;
Forward only;
Forwarders {114.114.114.114; 1.2.4.8 ;};
Dnssec-enable no;
Dnssec-validation no;
// Dnssec-lookaside auto;
/* Path to isc dlv key */
Bindkeys-file "/etc/named. iscdlv. key ";
Managed-keys-directory "/var/named/dynamic ";
};
Logging {
Channel default_debug {
File "data/named. run ";
Severity dynamic;
};
};
Zone "." IN {
Type hint;
File "named. ca ";
};
Zone "bkjia.com" IN {
Type master;
File "bkjia.com. zone ";
Allow-update {none ;};
};
Include "/etc/named. rfc1912.zones ";
Include "/etc/named. root. key ";
B) configure the dns zone File
$ Cp-rfv/var/named. localhost/var/named/bkjia.com. zone
$ Vi/var/named/bkjia.com. zone
$ TTL 600
@ In soa master.bkjia.com. root.master.bkjia.com .(
0; serial
1D; refresh
1 H; retry
1 W; expire
3 H); minimum
@ In a 172.31.100.46
@ In ns ns.bkjia.com.
In mx 10 mail.bkjia.com.
Ns in a 172.31.100.82
Mail in a 172.31.100.82
Www in a 172.31.100.46
Iv. Run
$/Etc/init. d/named start
$ Chkconfig named on
5. Check
$ Ps aux | grep named
$ Netstat-ntlp | grep named
$ Dig www.bkjia.com
Use BIND to configure the DNS server
BIND + DLZ + MySQL smart DNS implementation of forward and reverse resolution
Domain Name Service BIND construction and application configuration
Ubuntu BIND9 wildcard domain name resolution Configuration
Install BIND9.6 in CentOS 5.2
This article permanently updates the link address: