|
|
发表于 2005-6-7 13:04:31
|
显示全部楼层
DNS涉及三个文件,/etc/resolv.conf;/etc/named.conf;/var/named/[domainnamefile],摘例如下:
[resolv.conf]
domain yourdomainname #domain sina.com.cn
nameserver dnsserverip #nameserver 202.96.128.68
nameserver secondarydnsserverip #nameserver 202.96.134.133
[named.conf]
include "/etc/rndc.key";
options {
directory "/var/named";
};
controls {
inet 127.0.0.1 allow { localhost; } keys { rndckey; };
};
key DHCP_UPDATER {
algorithm hmac-md5;
secret pRP5FapFoJ95JEL06sv4PQ==;
};
zone "." {
type hint;
file "named.ca";
};
zone "localhost" {
allow-update { none; };
type master;
file "localhost.zone";
};
zone "0.0.127.in-addr.arpa" {
allow-update { none; };
type master;
file "named.local";
};
zone "sina.com.cn" {
type master;
file "sina.com.cn.zone";
};
[sina.com.cn.zone]
$TTL 86400
@ IN SOA mailsvr.sina.com.cn. root.mailsvr.sina.com.cn (
2005032501 ; serial
28800 ; refresh
14400 ; retry
3600000 ; expire
86400 ; ttl
)
@ IN NS dns
@ IN MX mail
dns IN A 10.1.1.1
mail IN A 10.1.1.2
#需要将sina.com.cn更改成你自己的域名
#其中mailsvr是你自己的主机名 |
|