IPv6和IPv4的掩码区别
浏览:2834次 出处信息
我们知道host或router等设备IPv4的地址配置中,一般提供”IPAddress/PrefixLen”或者”IPAddress network-mask 255.255.255.0”这类的地址配置方式。也就是说可以采用指定子网掩码长度或者明确写出子网前缀这两种方式配置地址。而到了IPv6之中,只能使用”IPv6Address/PrefixLen”这种方式。
看官可能会觉得这个无所谓啊,两者是等价的,其实不然。
如果提供指定掩码配置的方式我们可以配置出如下的”255.0.255.0”这样的不连续掩码,而IPv6无法达成这样的效果。
事实上,在IPv4发展处CIDR之后,并未要求掩码连续,在CIDR的早期标准RFC1519之中有如下描述:
It is also worthwhile to mention that once inter-domain protocols which support classless network destinations are widely deployed, the rules described by this plan generalize to permit arbitrary super/subnetting of the remaining class A and class B address space (the assumption being that classless inter-domain protocols will either allow for non-contiguous subnets to exist in the system or that all components of a sub-allocated class A/B will be contained within a single routing domain).
明确指出掩码可以不连续(non-contiguous ),这段描述在其更新标准RFC 4632中 被删掉了。
在实际应用中确实听到过某用户要求支持这样不连续的掩码,具体需求没有详细了解。
在IPv6中不连续掩码都无法配置,显然是不存在的。
建议继续学习:
QQ技术交流群:445447336,欢迎加入!
扫一扫订阅我的微信号:IT技术博客大学习
扫一扫订阅我的微信号:IT技术博客大学习
<< 前一篇:TCP Fast Open by Google 浅析
后一篇:如何根据http请求信息区分访问用户的国家、语言信息 >>
文章信息
- 作者:appleleaf 来源: kernelchina blogs
- 标签: 掩码
- 发布时间:2011-11-14 23:40:10
近3天十大热文
- [455] 如何拿下简短的域名
- [455] WEB系统需要关注的一些点
- [15] 什么是DNS劫持和DNS污染?
- [12] 一致性哈希算法及其在分布式系统中的应用
- [12] Mysql监控指南
- [12] Zookeeper工作原理
- [11] 行进在产品经理的路上
- [11] 大并发下的高性能编程 – 改进的(用户态)自
- [10] 分布式系统的事务处理
- [10] Python中的闭包