我在旧的 DO droplet(Debian 7.11)上设置了 bind9,一切正常。我决定今天设置一个新的 droplet(Debian 8.7)并配置 bind9。
在旧的 Debian 7 droplet 上,我将其配置为具有以下名称的权威名称服务器,ns1.example.com
并且ns2.example.com
.
我通过 GoDaddy 注册了域名,并使用他们的 Web 界面将其example.com
设置为指向我的外部名称服务器。ns1.example.com
ns2.example.com
但是,当我尝试设置它时,DNS 似乎无法在 Debian 8.7 droplet 上运行。
命名.conf.local
//
// Do any local configuration here
//
// Consider adding the 1918 zones here, if they are not used in your
// organization
//include "/etc/bind/zones.rfc1918";
// 107.170.40.252 <= public IP v4
zone "example.com" {
type master;
file "/etc/bind/zones/master/db.example.com";
};
zone "252.40.170.107.in-addr.arpa" {
type master;
file "/etc/bind/zones/master/db.107.170.40";
};
db.example.com
;
; BIND data file for example.com
;
$TTL 86400
@ IN SOA ns1.example.com. chris.example.com. (
1 ; Serial
3h ; Refresh after 3 hours
1h ; Retry after 1 hour
1w ; Expire after 1 week
1h ) ; Negative caching TTL of 1 day
;
@ IN NS ns1.example.com.
@ IN NS ns2.example.com.
example.com. IN MX 10 mail.example.com.
example.com. IN A 107.170.40.252
ns1 IN A 107.170.40.252
ns2 IN A 107.170.40.252
www IN CNAME example.com.
db.107.170.40
;
; Addresses and other host information
;
$TTL 86400
@ IN SOA example.local. hostmaster.example.local. (
2013090501 ; Serial
43200 ; Refresh
3600 ; Retry
3600000 ; Expire
2592000) ; Minimum
40.170.107.in-addr.arpa. IN NS dns.example.local.
252 IN PTR mail.example.local.
252 IN PTR ns1.example.local.
252 IN PTR ns2.example.local.
对此问题的任何帮助将不胜感激。