Named.conf配置文件
//
// named.caching-nameserver.conf
//
// Provided by Red Hat caching-nameserver package to configure the
// ISC BIND named(8) DNS server as a caching only nameserver
// (as a localhost DNS resolver only).
//
// See /usr/share/doc/bind*/sample/ for example named configuration files.
//
// DO NOT EDIT THIS FILE - use system-config-bind or an editor
// to create named.conf - edits to this file will be lost on
// caching-nameserver package upgrade.
//
include "/etc/named.rfc1912.zones";
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-dra ... -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 "abc.com" IN {
type master;
file "abc.com.zone";
};
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 "128.200.10.in-addr.arpa" IN{
type master;
file "128.200.10.zone";
};
正向的 abc.com.zone
$TTL 1D
@ IN SOA dns.abc.com. root (
42 ; serial
1D ; refresh
1H ; retry
1W ; expire
3H ) ; minimum
IN NS dns.abc.com.
dns IN A 10.200.128.220
www IN A 10.200.128.220
反向的
$TTL 1D
@ IN SOA dns.abc.com. root (
42 ; serial
1D ; refresh
1H ; retry
1W ; expire
3H ) ; minimum
IN NS dns.abc.com.
220 IN PTR dns.abc.com.
220 IN PTR www.abc.com.
能启动,,但不能解析。。。。。。。
出现错误
.nslookup
>10.200.128.220
Nslookup:’’220.128.200.10.in-addr.arpa.” is not a legal name (unexpected end of input)
>www.abc.com
Server :10.200.128.220
Address:10.200.128.220#53