我先在/var/named.conf下面加了2个声明[code:1]
zone "jamond.net" {
type master;
file "jamond.net.hosts";
};
zone "1.168.192.in-addr.arpa" {
type master;
file "192.168.1.rev";
};[/code:1]
然后,我又加了2个/var/named/jamond.net.hosts和/var/named/192.168.1.rev
在/var/named/jamond.net.hosts下是这样写的[code:1]
$TTL
@ IN SOA shrike.jamond.net. root.shrike.jamond.net.
( 1053891162
3H
15M
1W
1D )
IN NS shrike.jamond.net.
IN MX 5 shrike.jamond.net.
shrike IN A 192.168.1.200
win01 IN A 192.168.1.77
win02 IN A 192.168.1.88
www IN CNAME shrike.jamond.net.[/code:1]
在/var/named/192.168.1.rev下是这样写的[code:1]
$TTL
@ IN SOA shrike.jamond.net. root.shrike.jamond.net.
( 1053892104
1053892104
3H
15M
1W
1D )
IN NS shrike.jamond.net.
200 IN PTR shrike.jamond.net.
77 IN PTR win01.jamond.net.
88 IN PTR win02.jamond.net.[/code:1]
然后我在/etc/resolv.conf下写:nameserver 192.168.1.200.把eth0的ip设为192.168.1.100
serciec named restart,以后,就是解析不了,请哪位大侠帮我看看
系统日志的错误
nov 21 15:35:43 localhost named[1986]:loading configuration from '/etc/named.conf'
nov 21 15:35:43 localhost named[1986]:no ipv6 interfaces found
nov 21 15:35:43 localhost named[1986]:listening on ipv4 interface lo,127.0.0.1 #53
nov 21 15:35:43 localhost named[1986]:command channel listening on 127.0.0.1 #953
nov 21 15:35:43 localhost named[1986]:zone 0.0.127.in-addr.arpa/IN:loaded serial 1997022700
nov 21 15:35:43 localhost named[1986]:dns_rdata_fromtext: 192.168.1.rev:2 near eol: unexpected end of input
nov 21 15:35:43 localhost named[1986]:zopne localhost/IN:loaded serial 42
nov 21 15:35:43 localhost named[1986]:dns_rdata_fromtext: jamond.net.hosts:2: near eol: unexpected end of input
nov 21 15:35:43 localhost named[1986]:zone jamond.net/IN: loading master file jamond.net.hosts : unexpected end of input
nov 21 15:35:43 localhost named[1986]:running