所有服务器:关闭防火墙和安全机制
iptables -F
systemctl stop firewalld
setenforce 0
配置yum源
[root@ns2 ~]# umount -a
[root@ns2 ~]# mount /dev/sr0 /media
[root@ns2 ~]# cd /etc/yum.r*
[root@ns2 yum.repos.d]# mv C* a/
[root@ns2 yum.repos.d]# vim ./local.repo
[cdrom]
name=cdrom
baseurl=file:///media/
enabled=1
gpgcheck=0
[root@ns2 yum.repos.d]# yum -y clean all
主服务器的配置:
[root@localhost ~]# yum -y install bind
[root@localhost ~]# vim /etc/resolv.conf
[root@localhost ~]# vim /etc/hosts
[root@localhost ~]# vim /etc/named.conf
[root@localhost ~]# vim /var/named/crushlinux.zheng
[root@localhost ~]# cp /var/named/crushlinux.zheng /var/named/crushlinux.fan
[root@localhost ~]# vim /var/named/crushlinux.fan
[root@localhost ~]# chown :named /var/named/crushlinux.*
[root@localhost ~]# named-checkconf -z /etc/named.conf
[root@localhost ~]# named-checkzone crushlinux.com /var/named/crushlinux.zheng
[root@localhost ~]# named-checkzone crushlinux.com /var/named/crushlinux.fan
[root@localhost ~]# systemctl restart named
从服务器配置:
[root@localhost ~]# yum -y install bind
[root@localhost ~]# cat /etc/resolv.conf
[root@ns2 ~]# vim /etc/hosts
[root@localhost ~]# cat /etc/named.conf
[root@ns2 ~]# systemctl restart named