二、How
- 配置/etc/named.conf 删除zone
12 options { 13 listen-on port 53 { 192.168.64.55; }; 14 listen-on-v6 port 53 { ::1; }; 15 directory "/var/named"; 16 dump-file "/var/named/data/cache_dump.db"; 17 statistics-file "/var/named/data/named_stats.txt"; 18 memstatistics-file "/var/named/data/named_mem_stats.txt"; 19 allow-query { any; }; 20 forwarders { 202.106.0.20; };
- 测试从192.168.64.102 ping www.baidu.com
[root@localhost ~]# cat /etc/resolv.conf # Generated by NetworkManager nameserver 192.168.64.55 nameserver 192.168.64.100 [root@localhost ~]# ping www.baidu.com PING www.a.shifen.com (182.61.200.7) 56(84) bytes of data. 64 bytes from 182.61.200.7 (182.61.200.7): icmp_seq=1 ttl=128 time=14.3 ms
总结
- 缓存服务器保存在 /var/named/named.ca中