named.conf
[code:1]
include "/etc/bind/named.conf.options";
// prime the server with knowledge of the root servers
zone "." {
type hint;
file "/etc/bind/db.root";
};
// be authoritative for the localhost forward and reverse zones, and for
// broadcast zones as per RFC 1912
zone "localhost" {
type master;
file "/etc/bind/db.local";
};
zone "127.in-addr.arpa" {
type master;
file "/etc/bind/db.127";
};
zone "0.in-addr.arpa" {
type master;
file "/etc/bind/db.0";
};
zone "255.in-addr.arpa" {
type master;
file "/etc/bind/db.255";
};
include "/etc/bind/named.conf.local";
zone "home" {
type master;
file "/var/cache/bind/home.hosts";
};
zone "11.168.192.in-addr.arpa" {
type master;
file "/var/cache/bind/192.168.11.rev";
};
[/code:1]
在 var/cache/bind 下的 192.168.11。rev
[code:1]
$ttl 38400
11.168.192.in-addr.arpa. IN SOA debian.home. root.debian.home. (
1039102453
10800
3600
604800
38400 )
11.168.192.in-addr.arpa. IN NS debian.home.
2.11.168.192.in-addr.arpa. IN PTR workunit.home.
15.11.168.192.in-addr.arpa. IN PTR wintest.home.
13.11.168.192.in-addr.arpa. IN PTR debian.home.
[/code:1]
home.hosts
[code:1]
$ttl 38400
home. IN SOA debian.home. root.debian.home. (
1039102090
10800
3600
604800
38400 )
home. IN NS debian home.
debian.home. IN A 192.168.11.13
workunit.home. IN A 192.168.11.2
wintest.home. IN A 192.168.11.15
[/code:1]
我用的是 bind 9