私人DynDns服务器bind9

我正在尝试在我的私人在线实例上构build自己的dynamicDNS服务器。

我开始通过以下方式在您的Debian / Ubuntu服务器上安装DNS服务器BIND9:

apt-get update && apt-get install bind9. 

在/etc/bind/named.conf.local中添加了我的区域:

 include "/etc/bind/ddns-keys.conf"; zone "d.example.com" IN { type master; file "/var/lib/bind/db.d.example.com"; update-policy { grant *.d.example.com. self d.example.com. A AAAA TXT; }; notify no; }; 

我在/etc/bind/ddns-keys.conf中创build了我的密钥:

 dnssec-keygen -a HMAC-SHA512 -b 512 -n HOST sb.d.example.com. 

为我的区域/var/lib/bind/db.d.example.com添加了db文件:

 $ORIGIN . $TTL 10 ; 10 seconds d.example.com. IN SOA ns1.d.example.com. hostmaster.example.com. ( 2014080101 ; serial 120 ; refresh (2 minutes) 120 ; retry (2 minutes) 2419200 ; expire(4 weeks) 120 ; minimum (2 minutes) ) NS ns1.d.example.com. NS ns2.d.example.com. $ORIGIN d.example.com. $TTL 30 ; 30 seconds ipv4 A 38.68.84.19 ipv4v6 A 38.68.84.19 AAAA 2001:0db8::2 ipv6 AAAA 2001:0db8::2 ns1 A 38.68.84.19 ns2 AAAA 2001:0db8::2 

我也检查并重新安装了conf:

 named-checkconf named-checkzone d.example.com /var/lib/bind/db.d.example.com /etc/init.d/bind9 reload 

但子域没有解决。

任何想法的帮助,非常感激。