Linux下DNS服务器的搭建及区域委派
2012-08-22 11:34:49 来源:WEB开发网核心提示:include "/etc/named.rfc1912.zones";};[root@www etc]# vim named.rfc1912.zones增加以下记录:26 zone "sh.gjp.com" IN { 27 type master; 28 file "s
include "/etc/named.rfc1912.zones";
};
[root@www etc]# vim named.rfc1912.zones
增加以下记录:
26 zone "sh.gjp.com" IN {
27 type master;
28 file "sh.gjp.com.zone";
29 allow-update { none; };
30 };
产生 sh.gjp.com.zone 文件
[root@www named]# pwd
/var/named/chroot/var/named
[root@www named]# cp -p localdomain.zone sh.gjp.com.zone
[root@www named]#vim sh.gjp.com.zone
[root@www named]# service named start
启动 named: [确定]
[root@www named]# vim /etc/resolv.conf
[root@www named]# rndc reload
server reload successful
[root@www named]# nslookup www.sh.gjp.com
Server: 192.168.2.12
Address: 192.168.2.12#53
Name: www.sh.gjp.com
Address: 192.168.4.100
在父域主机上测试:
[root@gjp99 named]# rndc flush //清缓存!
[root@gjp99 named]# nslookup www.sh.gjp.com
Server: 192.168.2.100
Address: 192.168.2.100#53
Non-authoritative answer:
Name: www.sh.gjp.com
Address: 192.168.4.100
RHEL 5.3被委派端:
无条件转发:
更多精彩
赞助商链接