QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 574|回复: 1

DNS服务器问题

[复制链接]
发表于 2005-8-7 16:10:20 | 显示全部楼层 |阅读模式
本人是在局域网环境下做解析的,域名为www.IT.com  mail.IT.com  IP地址同为192.168.0.2,系统为Redhat AS 4.0
/etc/named.conf(内容):

//
// named.conf for Red Hat caching-nameserver
//

options {
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
       statistics-file "/var/named/data/named_stats.txt";
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below.  Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};

//
// a caching only nameserver config
//
controls {
inet 127.0.0.1 allow { localhost; } keys { rndckey; };
};

zone "." IN {
type hint;
file "named.ca";
};

zone "localdomain" IN {
type master;
file "localdomain.zone";
allow-update { none; };
};

zone "localhost" IN {
type master;
file "localhost.zone";
allow-update { none; };
};

zone "0.0.127.in-addr.arpa" IN {
type master;
file "named.local";
allow-update { none; };
};

zone "0.168.192.in-addr.arpa" IN {
type master;
file "named.192.168.0.2";
allow-update { none; };
};

zone "IT.com" IN {
type master;
file "/var/named/named.IT";
allow-update { none; };
};
include "/etc/rndc.key";

/var/named/named.192.168.0.2(内容):

  $TTL 86400
  @ IN SOA     IT.com.        root.IT.com. (
                                      83              ; serial (d. adams)
                                       3H              ; refresh
                                       15M             ; retry
                                       1W              ; expiry
                                       1D )            ; minimum
     IN    NS    www.IT.com
     IN    MX   10    mail.IT.com
 2 IN PTR www.IT.com
2 IN PTR mail.IT.com

/var/named/named.IT(内容):

  $TTL 86400
  @ IN SOA     IT.com.           root.IT.com. (
                                      83              ; serial (d. adams)
                                       3H              ; refresh
                                       15M             ; retry
                                       1W              ; expiry
                                       1D )            ; minimum
                IN      NS   www.IT.com
                IN      MX   10  mail.IT.com
   www IN A 192.168.0.2
   mail IN A 192.168.0.2

tail -20 /var/log/messages:
Aug  7 15:01:59 IT named[3924]: no longer listening on 192.168.0.1#53
Aug  7 15:01:59 IT named[3924]: exiting
Aug  7 15:01:59 IT named:  succeeded
Aug  7 15:02:01 IT named[3953]: starting BIND 9.2.4 -u named -t /var/named/chroot
Aug  7 15:02:01 IT named[3953]: using 1 CPU
Aug  7 15:02:01 IT named: named 启动 succeeded
Aug  7 15:02:01 IT named[3953]: loading configuration from '/etc/named.conf'
Aug  7 15:02:01 IT named[3953]: listening on IPv4 interface lo, 127.0.0.1#53
Aug  7 15:02:01 IT named[3953]: listening on IPv4 interface eth0, 192.168.0.1#53
Aug  7 15:02:01 IT named[3953]: command channel listening on 127.0.0.1#953
Aug  7 15:02:01 IT named[3953]: zone 0.0.127.in-addr.arpa/IN: loaded serial 1997022700
Aug  7 15:02:01 IT named[3953]: dns_master_load: named.192.168.0.2:2: unexpected end of line
Aug  7 15:02:01 IT named[3953]: dns_master_load: named.192.168.0.2:1: unexpected end of input
Aug  7 15:02:01 IT named[3953]: zone 0.168.192.in-addr.arpa/IN: loading master file named.192.168.0.2: unexpected end of input
Aug  7 15:02:01 IT named[3953]: dns_master_load: /var/named/named.IT:2: unexpected end of line
Aug  7 15:02:01 IT named[3953]: dns_master_load: /var/named/named.IT:1: unexpected end of input
Aug  7 15:02:01 IT named[3953]: zone IT.com/IN: loading master file /var/named/named.IT: unexpected end of input
Aug  7 15:02:01 IT named[3953]: zone localdomain/IN: loaded serial 42
Aug  7 15:02:01 IT named[3953]: zone localhost/IN: loaded serial 42
Aug  7 15:02:01 IT named[3953]: running
发表于 2005-8-7 22:22:30 | 显示全部楼层
named.192.168.0.2:2: unexpected end of line
named.192.168.0.2:1: unexpected end of input
/var/named/named.IT:2
var/named/named.IT:1: unexpected end of input
/var/named/named.IT

这些个文件再看看, 有错的说(log说的)
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-11-18 16:54 , Processed in 0.037936 second(s), 16 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表