【发布时间】:2015-04-02 14:29:59
【问题描述】:
我正在使用带有两个不同虚拟机的种子 Ubuntu 12.04:第一个用于运行 BIND9 的 DNS 服务器,第二个用于模拟用户/客户端。我的任务是毒化 DNS 服务器缓存。
在用户机器中,我将主 DNS 地址配置为 DNS 服务器机器的地址。
嗯,这是named.conf.options 文件的上下文(位置是/etc/bind/):
options {
directory "/var/cache/bind";
// If there is a firewall between you and nameservers you want
// to talk to, you may need to fix the firewall to allow multiple
// ports to talk. See http://www.kb.cert.org/vuls/id/800113
// If your ISP provided one or more IP addresses for stable
// nameservers, you probably want to use them as forwarders.
// Uncomment the following block, and insert the addresses replacing
// the all-0's placeholder.
// forwarders {
// 0.0.0.0;
// };
//========================================================================
// If BIND logs error messages about the root key being expired,
// you will need to update your keys. See https://www.isc.org/bind-keys
//========================================================================
//dnssec-validation auto;
dnssec-enable no;
auth-nxdomain no; # conform to RFC1035
listen-on-v6 { any; };
dump-file "/var/cache/bind/dump.db";
query-source port 33333;
};
在用户中,我尝试使用不同的主机名(google.com、cnn.com 等)输入一些不同的地址,以查看对缓存文件的影响。
问题:无论我做什么,缓存文件都是空的。当然我使用转储命令:
sudo rndc dumpdb -cache
但文件/var/cache/bind/dump.db 仍然是空的。
谢谢!
【问题讨论】: