一、错误

[root@localhost ~]# nslookup
> server 192.168.181.148
Default server: 192.168.181.148
Address: 192.168.181.148#53
> 10.3.3.1
** server can't find 1.3.3.10.in-addr.arpa: SERVFAIL
> exit
二、解决
##反向配置没有任何问题
[root@localhost ~]# cat /var/named/10.3.3.zone
$TTL 1D
@ IN SOA linux.com. rname.invalid. (
0 ; serial
1D ; refresh
1H ; retry
1W ; expire
3H ) ; minimum
NS dns03.linux.com.
dns03 A 192.168.181.148
1 PTR test3.linux.com.
2 PTR test4.linux.com.
3 PTR python.linux.com.
[root@localhost ~]# cat /etc/named.rfc1912.zones
// named.rfc1912.zones:
//
// Provided by Red Hat caching-nameserver package
//
// ISC BIND named zone configuration for zones recommended by
// RFC 1912 section 4.1 : localhost TLDs and address zones
// and http://www.ietf.org/internet-drafts/draft-ietf-dnsop-default-local-zones-02.txt
// (c)2007 R W Franks
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
zone "localhost.localdomain" IN {
type master;
file "named.localhost";
allow-update { none; };
};
zone "localhost" IN {
type master;
file "named.localhost";
allow-update { none; };
};
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" IN {
type master;
file "named.loopback";
allow-update { none; };
};
zone "1.0.0.127.in-addr.arpa" IN {
type master;
file "named.loopback";
allow-update { none; };
};
zone "0.in-addr.arpa" IN {
type master;
file "named.empty";
allow-update { none; };
};
zone "linux.com" IN {
type master;
file "linux.com.zone";
};
zone "3.3.10.in-addr.arpa" IN {
type master;
file "10.3.3.zone";
};
###是权限问题!!!!!
数组要为named cp -a有时不会把格式复制过去
[root@localhost ~]# ll /var/named/
总用量 24
-rw-r----- 1 root root 247 8月 16 10:33 10.3.3.zone
drwxrwx--- 2 named named 23 8月 16 09:29 data
drwxrwx--- 2 named named 60 8月 16 10:20 dynamic
-rw-r----- 1 root named 254 8月 16 10:24 linux.com.zone
-rw-r----- 1 root named 2253 4月 5 2018 named.ca
-rw-r----- 1 root named 152 12月 15 2009 named.empty
-rw-r----- 1 root named 152 6月 21 2007 named.localhost
-rw-r----- 1 root named 168 12月 15 2009 named.loopback
drwxrwx--- 2 named named 6 6月 11 2024 slaves
[root@localhost ~]# chgrp named /var/named/10.3.3.zone
[root@localhost ~]# ll /var/named/10.3.3.zone
-rw-r----- 1 root named 247 8月 16 10:33 /var/named/10.3.3.zone
[root@localhost ~]# systemctl restart named
[root@localhost ~]# nslookup
> server 192.168.181.148
Default server: 192.168.181.148
Address: 192.168.181.148#53
> 10.3.3.1
1.3.3.10.in-addr.arpa name = test3.linux.com.
>

3733

被折叠的 条评论
为什么被折叠?



