首页 > 代码库 > dns多台管理

dns多台管理

#####dns的多台管理####

 

1.dns的配置

 

以下文件配置参照之前dns的方法(之前博客介绍过):

[root@server named]# vim westos.com.zone

[root@server named]# vim /etc/named.conf

[root@server named]# vim /etc/named.rfc1912.zones

[root@server named]# vim /etc/resolv.conf

[root@server named]# systemctl restart named

[root@server named]#  dig www.westos.com

 

2.多台管理

 

 

主dns:

zone "westos.com" IN {

        type master;

        file "westos.com.zone";

        allow-update { none; };

        also-notify { 172.25.254.239; };

};

 

 

配置的其他台dns:

 

zone "westos.com" IN {

        type slave;

        masters { 172.25.254.139; };

        file "slaves/westos.com.zone";

        allow-update { none; };

};

 

每次更改dns配置时,只在主dns更改。

重启服务之后测试

$TTL 1D

@       IN SOA  dns.westos.com. root.westos.com. (

    此处每次更改dns要发生变化,否则不能同步## 2       ; serial

                                        1D      ; refresh

                                        1H      ; retry

                                        1W      ; expire

                                        3H )    ; minimum

        NS      dns.westos.com.

dns     A       172.25.254.139

www     A       172.25.254.139


本文出自 “AELY木” 博客,请务必保留此出处http://12768057.blog.51cto.com/12758057/1942052

dns多台管理