当前位置: 技术问答>linux和unix
bind反向解析问题,已经弄了我很久了,一直找不到问题,请高手帮帮忙呀
来源: 互联网 发布时间:2016-06-08
本文导语: named.conf options{ directory "/var/named"; forwarders { 61.139.2.69; }; }; # Use with the following in named.conf, adjusting the allow list as needed: ke...
named.conf
options{
directory "/var/named";
forwarders {
61.139.2.69;
};
};
# Use with the following in named.conf, adjusting the allow list as needed:
key "rndc-key" {
algorithm hmac-md5;
secret "Ue8n9NeROQdIpvSmMPKeRg==";
};
controls {
inet 127.0.0.1 port 953
allow { 127.0.0.1; } keys { "rndc-key"; };
};
# End of named.conf
#zone space
zone "."{
type hint;
file "named.ca";
};
#Slave nameserver for domain.com and 192.168.1/24
//zone "domain.com"{
// type slave;
// masters {192.168.1.160;};
// file "slaves/domain.com.zone";
// };
//zone "1.168.192.in-addr.arpa"{
// type slave;
// masters {192.168.1.160;};
// file "slaves/192.168.1.zone";
// };
//
zone "example.com"{
type master;
file "example.com.zone";
};
zone "1.168.192.in-adde.arpa" {
type master;
file "1.168.192.in-adde.arpa.zone";
};
example.com.zone
$TTL 86400
@ IN SOA example.com. root.example.com.(
2009051400;
10800;
3600;
604800;
0;
);
1.168.192.in-adde.arpa.zone
$TTL 86400
@ IN SOA example.com. root.example.com.(
2009051400;
10800;
3600;
604800;
0;
);
@ IN NS example.com.
160 IN PTR example.com.
@ IN NS ns.example.com.
ns IN A 192.168.1.160
mail IN A 192.168.1.160
mail IN MX 10 mail.example.com.
www IN A 192.168.1.160
[root@localhost ~]# named -g
29-Apr-2009 12:07:58.656 starting BIND 9.6.0 -g
29-Apr-2009 12:07:58.659 built with defaults
29-Apr-2009 12:07:58.660 using up to 4096 sockets
29-Apr-2009 12:07:58.681 loading configuration from '/etc/named.conf'
29-Apr-2009 12:07:58.686 using default UDP/IPv4 port range: [1024, 65535]
29-Apr-2009 12:07:58.688 using default UDP/IPv6 port range: [1024, 65535]
29-Apr-2009 12:07:58.697 listening on IPv4 interface lo, 127.0.0.1#53
29-Apr-2009 12:07:58.699 listening on IPv4 interface eth0, 192.168.1.160#53
29-Apr-2009 12:07:58.713 automatic empty zone: 0.IN-ADDR.ARPA
29-Apr-2009 12:07:58.715 automatic empty zone: 127.IN-ADDR.ARPA
29-Apr-2009 12:07:58.716 automatic empty zone: 254.169.IN-ADDR.ARPA
29-Apr-2009 12:07:58.718 automatic empty zone: 2.0.192.IN-ADDR.ARPA
29-Apr-2009 12:07:58.720 automatic empty zone: 255.255.255.255.IN-ADDR.ARPA
29-Apr-2009 12:07:58.723 automatic empty zone: 0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA
29-Apr-2009 12:07:58.724 automatic empty zone: 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA
29-Apr-2009 12:07:58.725 automatic empty zone: D.F.IP6.ARPA
29-Apr-2009 12:07:58.726 automatic empty zone: 8.E.F.IP6.ARPA
29-Apr-2009 12:07:58.728 automatic empty zone: 9.E.F.IP6.ARPA
29-Apr-2009 12:07:58.730 automatic empty zone: A.E.F.IP6.ARPA
29-Apr-2009 12:07:58.732 automatic empty zone: B.E.F.IP6.ARPA
29-Apr-2009 12:07:58.745 command channel listening on 127.0.0.1#953
29-Apr-2009 12:07:58.748 ignoring config file logging statement due to -g option
29-Apr-2009 12:07:58.754 zone 1.168.192.in-adde.arpa/IN: loaded serial 2009051400
29-Apr-2009 12:07:58.761 zone example.com/IN: loaded serial 2009051400
29-Apr-2009 12:07:58.764 running
29-Apr-2009 12:07:58.766 zone example.com/IN: sending notifies (serial 2009051400)
29-Apr-2009 12:10:27.025 shutting down
29-Apr-2009 12:10:27.028 stopping command channel on 127.0.0.1#953
29-Apr-2009 12:10:27.030 no longer listening on 127.0.0.1#53
29-Apr-2009 12:10:27.031 no longer listening on 192.168.1.160#53
29-Apr-2009 12:10:27.043 exiting
[root@localhost /var/named]# nslookup
> www.example.com
Server: 192.168.1.160
Address: 192.168.1.160#53
Name: www.example.com
Address: 192.168.1.160
> mail.example.com
Server: 192.168.1.160
Address: 192.168.1.160#53
> 192.168.1.160
Server: 192.168.1.160
Address: 192.168.1.160#53
** server can't find 160.1.168.192.in-addr.arpa.: NXDOMAIN
请高手看看怎么回事,为什么就是不能进行反向解析
options{
directory "/var/named";
forwarders {
61.139.2.69;
};
};
# Use with the following in named.conf, adjusting the allow list as needed:
key "rndc-key" {
algorithm hmac-md5;
secret "Ue8n9NeROQdIpvSmMPKeRg==";
};
controls {
inet 127.0.0.1 port 953
allow { 127.0.0.1; } keys { "rndc-key"; };
};
# End of named.conf
#zone space
zone "."{
type hint;
file "named.ca";
};
#Slave nameserver for domain.com and 192.168.1/24
//zone "domain.com"{
// type slave;
// masters {192.168.1.160;};
// file "slaves/domain.com.zone";
// };
//zone "1.168.192.in-addr.arpa"{
// type slave;
// masters {192.168.1.160;};
// file "slaves/192.168.1.zone";
// };
//
zone "example.com"{
type master;
file "example.com.zone";
};
zone "1.168.192.in-adde.arpa" {
type master;
file "1.168.192.in-adde.arpa.zone";
};
example.com.zone
$TTL 86400
@ IN SOA example.com. root.example.com.(
2009051400;
10800;
3600;
604800;
0;
);
1.168.192.in-adde.arpa.zone
$TTL 86400
@ IN SOA example.com. root.example.com.(
2009051400;
10800;
3600;
604800;
0;
);
@ IN NS example.com.
160 IN PTR example.com.
@ IN NS ns.example.com.
ns IN A 192.168.1.160
mail IN A 192.168.1.160
mail IN MX 10 mail.example.com.
www IN A 192.168.1.160
[root@localhost ~]# named -g
29-Apr-2009 12:07:58.656 starting BIND 9.6.0 -g
29-Apr-2009 12:07:58.659 built with defaults
29-Apr-2009 12:07:58.660 using up to 4096 sockets
29-Apr-2009 12:07:58.681 loading configuration from '/etc/named.conf'
29-Apr-2009 12:07:58.686 using default UDP/IPv4 port range: [1024, 65535]
29-Apr-2009 12:07:58.688 using default UDP/IPv6 port range: [1024, 65535]
29-Apr-2009 12:07:58.697 listening on IPv4 interface lo, 127.0.0.1#53
29-Apr-2009 12:07:58.699 listening on IPv4 interface eth0, 192.168.1.160#53
29-Apr-2009 12:07:58.713 automatic empty zone: 0.IN-ADDR.ARPA
29-Apr-2009 12:07:58.715 automatic empty zone: 127.IN-ADDR.ARPA
29-Apr-2009 12:07:58.716 automatic empty zone: 254.169.IN-ADDR.ARPA
29-Apr-2009 12:07:58.718 automatic empty zone: 2.0.192.IN-ADDR.ARPA
29-Apr-2009 12:07:58.720 automatic empty zone: 255.255.255.255.IN-ADDR.ARPA
29-Apr-2009 12:07:58.723 automatic empty zone: 0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA
29-Apr-2009 12:07:58.724 automatic empty zone: 1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA
29-Apr-2009 12:07:58.725 automatic empty zone: D.F.IP6.ARPA
29-Apr-2009 12:07:58.726 automatic empty zone: 8.E.F.IP6.ARPA
29-Apr-2009 12:07:58.728 automatic empty zone: 9.E.F.IP6.ARPA
29-Apr-2009 12:07:58.730 automatic empty zone: A.E.F.IP6.ARPA
29-Apr-2009 12:07:58.732 automatic empty zone: B.E.F.IP6.ARPA
29-Apr-2009 12:07:58.745 command channel listening on 127.0.0.1#953
29-Apr-2009 12:07:58.748 ignoring config file logging statement due to -g option
29-Apr-2009 12:07:58.754 zone 1.168.192.in-adde.arpa/IN: loaded serial 2009051400
29-Apr-2009 12:07:58.761 zone example.com/IN: loaded serial 2009051400
29-Apr-2009 12:07:58.764 running
29-Apr-2009 12:07:58.766 zone example.com/IN: sending notifies (serial 2009051400)
29-Apr-2009 12:10:27.025 shutting down
29-Apr-2009 12:10:27.028 stopping command channel on 127.0.0.1#953
29-Apr-2009 12:10:27.030 no longer listening on 127.0.0.1#53
29-Apr-2009 12:10:27.031 no longer listening on 192.168.1.160#53
29-Apr-2009 12:10:27.043 exiting
[root@localhost /var/named]# nslookup
> www.example.com
Server: 192.168.1.160
Address: 192.168.1.160#53
Name: www.example.com
Address: 192.168.1.160
> mail.example.com
Server: 192.168.1.160
Address: 192.168.1.160#53
> 192.168.1.160
Server: 192.168.1.160
Address: 192.168.1.160#53
** server can't find 160.1.168.192.in-addr.arpa.: NXDOMAIN
请高手看看怎么回事,为什么就是不能进行反向解析
|
http://hi.baidu.com/chenshake/blog/item/162f03172220d7044b90a718.html
http://blog.chinaunix.net/u1/42928/showart_334280.html
教程你应该找了不少了。
server can't find 167.126.32.10.in-addr.arpa.: NXDOMAIN
这样的错误可以参考下这里
http://hi.baidu.com/filebat/blog/item/c38c10b3f19835afd8335ac6.html
倒数第2个错误
http://blog.chinaunix.net/u1/42928/showart_334280.html
教程你应该找了不少了。
server can't find 167.126.32.10.in-addr.arpa.: NXDOMAIN
这样的错误可以参考下这里
http://hi.baidu.com/filebat/blog/item/c38c10b3f19835afd8335ac6.html
倒数第2个错误