Mylinux.com 172.16.100.0/24
NS 172.16.100.1
www 172.16.100.1, 172.16.100.3
Mail 172.16.100.24
FTP www
Dns:bind Software
Berkeley Internet Name Domain
Isc
www.isc.org
[email protected] yum.repos.d]# Yum list |grep "^bind"
[Email protected] yum.repos.d]# yum-y install bind.i686
/etc/named.conf master configuration file, which is used to define the working properties of the bind process, the definition of the zone, etc.
/etc/rndc.key key File,
/etc/rndc.conf configuration information
/VAR/NAMED/XX Zone data file, you need to define it yourself
/etc/init.d/named Service Script
/etc/sysconfig/named The main configuration file for the service script
/usr/sbin/named Main Program
/usr/sbin/named-checkconf Check the configuration file
/usr/sbin/named-chenkzone Check the zone file
/USR/SBIN/RNDC Remote Control Tool
/usr/sbin/rndc-confgen The RNDC configuration file is generated.
{Start|stop|restart|status|reload}
Binary program: Named
Bind-chroot:
Default: Named
Users: Named
Group: Named
/var/named/chroot/
etc/named.conf
Etc/rdnc.key
Sbin/named
var/named/
Caching-nameserver Cache DNS Server RPM package
/var/named/named.ca This file holds the address of 13 root node servers
Dig:domain Information
Dig-t NS. Find all DNS servers for the root domain
Dig-t NS. @a.root-servers.net. Directly from this server to find
This file is/var/named/named.localhost to avoid DNS server parsing errors. specifically resolves localhost to 127.0.0.1
[[Email protected] named]# service named Start services
Dns:
Protocols and ports for listening:
The 53/UDP query protocol uses UDP by default
53/tcp use TCP when backing up from the server. TCP is also used when RNDC remote
Socket: Socket
Ip:port
C/S: Client/server
Vi/etc/named.conf
Options Global Option
127.0.0.1:53 only receive hosts from the inside
0.0.0.0:53 listening on port 53rd for all IPs
Directory "/var/named"; Clear description This is the data directory
allow-query {localhost} only allows local queries
recursion Yes; recursive
Area: Type
Zone "Zone NAME" in {
Type {Master Master |slave forwarding from |hint root zone |forward}
};
Main area:
File "zone data Files";
From zone:
File "zone data Files";
master {master1_ip;master2_ip;} ;
Vi/etc/named.conf
------------------------
Options {
Directory "/var/named";
};
Zone "." in {
Type hint;
File "named.ca";
};
Zone "localhost" in {
Type master;
File "Name.localhost";
};
Zone "0.0.127.in-addr.arpa" in{
Type master;
File "Named.loopback";
};
--------------------------------
Chown root:named/etc/named.conf
chmod 640/etc/named.conf
Named-checkconf
Named-checkzone "." /var/named/named.ca
Named-checkzone "localhost"/var/named.localhost
Named-checkzone "0.0.127.in-addr.apra"/var/named.loopback
Service named start
Temporarily close SELinux:
Getenforce View
Setenforce 0 off
Setenforce 1 Enabled
Permanently closed: Vim/etc/selinux/config
Selinux=disabled or permissive
This article from "Linux operation and Maintenance" blog, declined reprint!
DNS server installation and configuration bind