Chinaunix首页 | 论坛 | 博客
  • 博客访问: 542713
  • 博文数量: 375
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 15
  • 用 户 组: 普通用户
  • 注册时间: 2013-09-20 10:21
文章分类

全部博文(375)

文章存档

2015年(1)

2014年(374)

分类: LINUX

2014-08-18 13:38:49

原文地址:BIND 常见错误信息 作者:ailms

1.启动信息 ok

 

 Jul 27 16:18:41 terminator named[7045]: starting BIND 9.1.0
 
2.reload信息 ok

 

[general] Sep 29 15:06:22.316 general: debug 1: received control channel command 'reload'
 Sep 29 15:06:22.316 general: info: loading configuration from '/etc/named.conf'
 Sep 29 15:06:22.320 general: debug 1: now using logging configuration from config file
 Sep 29 15:06:22.321 general: debug 1: load_configuration: success

 

3. stop 信息 ok

 

[general] Sep 29 17:02:25.444 general: debug 1: received control channel command 'stop'
 Sep 29 17:02:25.444 general: info: shutting down: flushing changes
 Sep 29 17:02:25.444 general: notice: stopping command channel on 127.0.0.1#953
 Sep 29 17:02:25.458 general: notice: exiting 
 
[network] Sep 29 17:02:25.445 network: info: no longer listening on 127.0.0.1#53
  Sep 29 17:02:25.445 network: info: no longer listening on 192.168.13.162#53
 
4. 文件描述符不足

 

Jan 10 20:50:20 terminator named[3221]: cannot set resource limits on  this system  

 

Jan 10 20:50:31 terminator named[3221]: fcntl(dfd, F_DUPFD, 20): Too   many open files

 

5. 加载 zone data file ok

 

[general] Sep 29 16:37:20.292 general: debug 1: zone_loaddone: zone bob.com/IN: enter
 Sep 29 16:37:20.292 general: debug 1: zone bob.com/IN: loaded
 Sep 29 16:37:20.293 general: debug 1: zone bob.com/IN: journal rollforward completed successfully: no journal
 Sep 29 16:37:20.293 general: info: zone bob.com/IN: loaded serial 2005092911

 
6. 统计信息 ok

 

 [root@dns named]# cat named.stats
 +++ Statistics Dump +++ (1127984980)
 success 2
 referral 0
 nxrrset 0
 nxdomain 0
 recursion 1
 failure 0
 --- Statistics Dump --- (1127984980)

 

 +++ Statistics Dump +++ (1127985042)
 success 3
 referral 0
 nxrrset 0
 nxdomain 0
 recursion 2
 failure 0
 --- Statistics Dump --- (1127985042)
 [root@dns named]#
 
 
从以上可以看出 named 运行了 62 (1127985042-1127984980=62)
 
 
7. 主机名检测 (BIND 9.2.1 不支持) ok

 

 Jul 24 20:56:26 terminator named[1496]: owner name "ID_4.movie.edu IN"   (primary) is invalid - rejecting  

 


8. CNAME 错误 ok

 

[general] Sep 29 16:29:33.981 general: error: dns_master_load: primary/bob.com/bob.com.zone:16: ailms.bob.com: CNAME and other data
 Sep 29 16:29:33.981 general: error: zone bob.com/IN: loading master file primary/bob.com/bob.com.zone: CNAME and other data

 

1 :当出现该错误时,BIND 将不加载新的 zone data。也就是说 reload 失败。

 
9. zone transfer 失败

 

 Jul 27 16:50:55 terminator named[7174]: refresh_callback: zone movie.edu/IN: failure for 10.0.0.1#53: timed out

 

10. zone transfer 成功

 

 Mar  7 07:30:04 terminator named[3977]: approved AXFR from [192.249.249.1].2253 for "movie.edu"

 

11. zone transfer 被拒绝

 

 Jul 27 16:59:26 terminator named[7174]: client 192.249.249.1#1386: zone transfer denied

 

12. 响应包出错

 

 Jan 10 20:52:42 wormhole named[2813]: Malformed response from 192.1.1.1
 
13. 配置了本地zone以外的主机。 (属于 general 类的,级别为 warnning

 

例如在 bob.com.zone 文件中配置了 " sohu.com. IN A    192.168.13.253" 这条记录。再 reload

 

Sep 30 15:48:35.709 general: warning: dns_master_load: primary/bob.com/bob.com.zone:16: ignoring out-of-zone data (sohu.com)

 

'16' 是表示第几行。括号中的是记录的第一个字段。


 
14. CNAME 使用错误

 

 Jun 13 08:21:04 terminator named[2699]: "movie.edu IN NS" points to a  CNAME (dh.movie.edu) 

 

例如配置如下

 

ailms                   IN      CNAME   dns.bob.com.
                         IN      NS      ailms

 

Sep 30 15:55:27.331 general: error: dns_master_load: primary/bob.com/bob.com.zone:11: ailms.bob.com: CNAME and other data


 
15. 从未知地址的回复 

 

 Jun 11 11:40:54 terminator named[131]: Response from unexpected source   ([204.138.114.3].53)
 
16. 未知的 class  

 

 Jun 10 07:57:28 terminator named[131]: No root nameservers for   class 226

 

Sep 30 16:00:18.993 general: warning: dns_master_load: primary/bob.com/bob.com.zone:16: unknown RR type 'L'
Sep 30 16:00:18.994 general: debug 1: zone_loaddone: zone bob.com/IN: enter
Sep 30 16:00:18.994 general: error: zone bob.com/IN: loading master file primary/bob.com/bob.com.zone: unknown class/type

 
17. 主服务器上的 serial number 比从服务器上的 serial number 要小。 

 

 Jun 7 20:14:26 wormhole named[29618]: Zone "253.253.192.in-addr.arpa"  (class 1) SOA serial# (3345) rcvd from [192.249.249.10] is < ours (563319491

 

18. serial number 比上一次 load zone 的时候还小

 

Sep 30 16:06:06.793 general: error: zone bob.com/IN: zone serial has gone backwards
Sep 30 16:06:06.793 general: info: zone bob.com/IN: loaded serial 2005092909

 

虽然 serial number 比上一次加载该 zone 时小,但仍然会加载。


 
19. lame server 授权错误。

 

例如在 bob.com.zone 中配置

sub.bob.com.            IN      NS      dns.sub.bob.com.

 

再执行 nslookup 命令查询

 

[root@dns general]# nslookup ssh.sub.bob.com.
Note:  nslookup is deprecated and may be removed from future releases.
Consider using the `dig' or `host' programs instead.  Run nslookup with
the `-sil[ent]' option to prevent this message from appearing.
Server:         192.168.13.162
Address:        192.168.13.162#53

 

** server can't find ssh.sub.bob.com: SERVFAIL

 

Sep 30 16:09:18.081 lame-servers: info: lame server resolving 'dns.sub.bob.com' (in 'sub.bob.com'?): 192.168.13.162#53
 
20. query-log ok
 
 Jan 13 18:32:42 terminator named[13976]: client 192.253.253.2#1702: query: 4.253.253.192.in-addr.arpa IN PTR
 
21. 53 端口被占用 

 

 Jul 27 17:15:58 terminator named[7357]: binding TCP socket: address in use  

 

注释 :其实 named 使用的是 UDP 53 端口,所以即使 TCP 53 端口被占用了,named 也照样可以启动和解释。

 

[root@dns network]# fuser -n tcp 53
53/tcp:              12273 12276 12277 12278 12279 12280 12281 12282 12283
[root@dns network]# ps 12273
  PID TTY      STAT   TIME COMMAND
12273 ?        S      0:00 /usr/sbin/httpd
[root@dns network]# fuser -n udp 53
53/udp:              12353
[root@dns network]# ps 12353
  PID TTY      STAT   TIME COMMAND
12353 ?        S      0:00 /usr/sbin/named -u named
[root@dns network]#

 

 

修改 /etc/services 文件,将 domain 一行的 udp/53 注释掉,再启动 named


 Sep 30 16:35:46 dns named[12414]: listening on IPv4 interface lo, 127.0.0.1#53
Sep 30 16:35:46 dns named[12414]: binding TCP socket: address in use
Sep 30 16:35:46 dns named[12414]: listening on IPv4 interface eth0, 192.168.13.162#53
Sep 30 16:35:46 dns named[12414]: binding TCP socket: address in use
Sep 30 16:35:46 dns named[12414]: command channel listening on 127.0.0.1#953

 

[root@dns default]# pidof named
12414
[root@dns default]# ps 12414
  PID TTY      STAT   TIME COMMAND
12414 ?        S      0:00 /usr/sbin/named -u named
[root@dns default]#

 

[root@dns default]# fuser -n tcp 53
53/tcp:              12273 12276 12277 12278 12279 12280 12281 12282 12283
[root@dns default]# fuser -n udp 53
53/udp:              12414
[root@dns default]# ps 12414
  PID TTY      STAT   TIME COMMAND
12414 ?        S      0:00 /usr/sbin/named -u named
[root@dns default]# nslookup sohu.com
Note:  nslookup is deprecated and may be removed from future releases.
Consider using the `dig' or `host' programs instead.  Run nslookup with
the `-sil[ent]' option to prevent this message from appearing.
Server:         192.168.13.162
Address:        192.168.13.162#53

 

Non-authoritative answer:
Name:   sohu.com
Address: 61.135.133.104
Name:   sohu.com
Address: 61.135.133.103

 

[root@dns default]#

仍然可以运行和解释,说明默认就是采用 UDP 53 端口,即使在 /etc/services 文件中注释掉 udp/53 一行。

 

[root@dns default]# netstat -au
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State     
udp        0      0 *:32768                 *:*                                
udp        0      0 *:nfs                   *:*                                
udp        0      0 *:32770                 *:*                                
udp        0      0 *:32771                 *:*                                
udp        0      0 *:dns_query             *:*                                
udp        0      0 *:10000                 *:*                                
udp        0      0 *:940                   *:*                                
udp        0      0 dns.bob.com:domain      *:*                                
udp        0      0 localhost.locald:domain *:*                                
udp        0      0 *:npmp-local            *:*                                
udp        0      0 *:sunrpc                *:*                                
[root@dns default]# tail -f /var/log/messages
Sep 30 16:42:30 dns  9
30 16:42:30 httpd: httpd 关闭 succeeded
Sep 30 16:42:31 dns  9
30 16:42:31 httpd: httpd 启动 succeeded
Sep 30 16:42:42 dns named[12548]: starting BIND 9.2.1 -u named
Sep 30 16:42:42 dns named[12548]: using 1 CPU
Sep 30 16:42:42 dns named[12548]: loading configuration from '/etc/named.conf'
Sep 30 16:42:42 dns  9
30 16:42:42 named: named 启动 succeeded
Sep 30 16:42:42 dns named[12548]: no IPv6 interfaces found
Sep 30 16:42:42 dns named[12548]: listening on IPv4 interface lo, 127.0.0.1#53
Sep 30 16:42:42 dns named[12548]: listening on IPv4 interface eth0, 192.168.13.162#53
Sep 30 16:42:42 dns named[12548]: command channel listening on 127.0.0.1#953

 

[root@dns default]# 

  

 

阅读(1483) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~