bind里面配置ipv6

 

options语句的定义和使用:

options语句用来设置可以被整个BIND使用的全局选项。这个语句在每个配置文件中只有 一处。如果出现多个options语句,则第一个options的配置有效,并且会产生一个警告信息。

接口和端口(服务器回答来自于此的询问)可以使用listen-on选项来设定。listen-on使用可选的端口和一个地址匹配列表(address_match_list)。服务器将会监听所有匹配地址列表 中所允许的端口。如果没有设定端口,就使用默认的53。
允许使用多个listen-on语句。例如:
listen-on { 192.168.10.10; };
listen-on port 10053 { !10.2.3.4; 10.2/16; };
将在192.168.10.10的ip地址上打开53端口,在除了10.2.3.4的10.2 网段上打开10053 端口。
如果没有设定listen-on,服务器将在所有接口上监听端口53。
listen-on-v6选项用来设定监听进入服务器的ipv6请求的端口。
服务器并不象在ipv4中那样对每个IPV6端口地址绑定一个独立的socket。相反,它一直监听ipv6通配的地址。这样,对于listen-on-v6语句唯一的address_match_list的参数就是: { any; }和{ none;}
多个listen-on-v6选项可以用来监听多个端口:
listen-on-v6 port 53 { any; };
listen-on-v6 port 1234 { any; };
要使服务器不监听任何ipv6地址,使用:
listen-on-v6 { none; };
如果没有设定listen-on-v6语句,服务器将不会监听任何ipv6地址

根据RFC4159规范描述,ip6.int格式已经废弃,原文如下:
As of 1 September 2005, the IETF advises the community that the DNS
   domain "ip6.int" should no longer be used to perform reverse mapping
   of IPv6 addresses to domain names, and that the domain "ip6.arpa"
   should be used henceforth, in accordance with the IANA Considerations
   described in [RFC3596].  The domain "ip6.int" is deprecated, and its
   use in IPv6 implementations that conform to the IPv6 Internet
   Standards is discontinued.
 

配置AAAA 记录
AAAA 记录和IPV4 的A 记录相似,需要在BIND的各个zone中进行配置。它在一个单独的记录中设定了全部地址。例如:

  1. $ORIGIN 10658123.cn.
  2. www.10658123.cn. 3600 IN AAAA 8888::A18

使用Nibble 格式进行IPv6地址到域名的反向查询

虽然不建议使用Nibble 格式查找名字,但它能向下兼容支持现有的IPV6 应用。当解析一个nibble 格式的地址时,地址块被简单的翻转了,在名字的结果后面附加上一个ip6.arpa.(RFC 4159规范说明),就象在IPv4 中一样。例如,下面的例子会为一台主机提供反转名称查询,地址是2001:1234:5678:1:987::2

  1. more DefaultView.1.0.0.0.8.7.6.5.4.3.2.1.1.0.0.2.ip6.arpa.hosts
  2. $ORIGIN    1.0.0.0.8.7.6.5.4.3.2.1.1.0.0.2.ip6.arpa.

  3. @ 86400 IN SOA dns1.aischang.com ming.aischang.com (

  4.   1481720695
       3600
       7200
       604800
       604800)

  5.    86400 IN NS dns1.aischang.com.

  6.    86400 IN NS dns2.aischang.com.

  7. 2.0.0.0.0.0.0.0.0.0.0.0.7.8.9.0    14400   IN   PTR   ipv6.aischang.cn.

验证测试结果:

#### dig -p10053  -x 2001:1234:5678:1:987::2 
; <<>> DiG 9.10.2-P4-v1.0.1 <<>> @192.168.10.12 -p10053 -x 2001:1234:5678:1:987::2
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 46195
;; flags: qr aa rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;2.0.0.0.0.0.0.0.0.0.0.0.7.8.9.0.1.0.0.0.8.7.6.5.4.3.2.1.1.0.0.2.ip6.arpa. IN PTR

;; ANSWER SECTION:
2.0.0.0.0.0.0.0.0.0.0.0.7.8.9.0.1.0.0.0.8.7.6.5.4.3.2.1.1.0.0.2.ip6.arpa. 14400 IN PTR ipv6.aischang.cn.

;; AUTHORITY SECTION:
1.0.0.0.8.7.6.5.4.3.2.1.1.0.0.2.ip6.arpa. 86400 IN NS dns1.aischang.com.
1.0.0.0.8.7.6.5.4.3.2.1.1.0.0.2.ip6.arpa. 86400 IN NS dns2.aischang.com.

;; Query time: 0 msec
;; SERVER: 192.168.10.12#10053(192.168.10.12)
;; WHEN: Wed Jun 27 10:06:09 CST 2018
;; MSG SIZE  rcvd: 186


  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 3
    评论
中文名: DNS and BIND on IPv6 (第1版) 原名: DNS and BIND on IPv6, 1st edition 作者: Cricket Liu 资源格式: PDF 版本: 英文文字版 出版社: O'Reilly书号: 978-1449305192发行时间: 2011年05月27日 地区: 美国 语言: 英文 简介: 内容介绍: If you're preparing to roll out IPv6 on your network, this concise book provides the essentials you need to support this protocol with DNS. You'll learn how DNS was extended to accommodate IPv6 addresses, and how you can configure a BIND name server to run on the network. This book also features methods for troubleshooting problems with IPv6 forward- and reverse-mapping, techniques for helping islands of IPv6 clients communicate with IPv4 resources, and many other topics. 作者介绍: Cricket Liu Cricket Liu graduated from the University of California, Berkeley, that great bastion of free speech, unencumbered Unix, and cheap pizza. He joined Hewlett-Packard after graduation and worked for HP for nine years. Cricket began managing the hp.com zone after the Loma Prieta earthquake forcibly transferred the zone's management from HP Labs to HP's Corporate Offices (by cracking a sprinkler main and flooding a Labs computer room). Cricket was hostmaster@hp.com for over three years, and then joined HP's Professional Services Organization to co-found HP's Internet Consulting Program. Cricket left HP in 1997 to form Acme Byte & Wire, a DNS consulting and training company, with his friend Matt Larson. Network Solutions acquired Acme in June 2000, and later the same day merged with VeriSign. Cricket worked for a year as Director of DNS Product Management for VeriSign Global Registry Services. Cricket joined Infoblox, a company that develops DNS and DHCP appliances, in March, 2003. He is currently their Vice President of Architecture. Cricket, his wife, Paige, their son, Walt, and daughter, Greta, live in California with their two Siberian Huskies, Annie and Dakota. 目录: Chapter 1 DNS and IPv6 Chapter 2 BIND on IPv6 Chapter 3 Resolver Configuration Chapter 4 DNS64 Chapter 5 Troubleshooting

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 3
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值