Loading... 实验为路由IP地址汇总,本实验环境为小凡搭建!! 本人亲做!望大家支持! 先看一下ip地址汇总的方法吧 把这几个网络地址展开为2进制的,然后看相同的网络位,连续而且相同的网络位就是这几个网络地址的汇总地址了,例如: 172.168.4.1/24 172.168.5.1/24 172.168.6.1/24 172.168.7.1/24 这几个地址展开来是: 10101100.10101000.00000100.00000001 10101100.10101000.00000101.00000001 10101100.10101000.00000110.00000001 10101100.10101000.00000111.00000001 他们都有相同的前22位,所以汇总地址就是 172.168.4.0/22 还有,汇总只能汇总到主类的边界,也就是说A类只能汇总到/8,B类只能汇总到/16,C类只能汇总到/24。 只有CIDR才可以突破主类边界。 好了,来看实验过程!! <strong>1. </strong><strong>实验图</strong><strong></strong> <a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image002.gif"><img style="display: inline; border: 0px;" title="clip_image002" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image002_thumb.gif" border="0" alt="clip_image002" width="504" height="268" style=""></a> <span style="color: #ff0000;"><strong>2. </strong><strong>按图配置</strong><strong></strong></span> <span style="color: #ff0000;">3. <strong>测试</strong></span> <a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image004.gif"><img style="display: inline; border: 0px;" title="clip_image004" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image004_thumb.gif" border="0" alt="clip_image004" width="592" height="291" style=""></a>a.b.<a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image006.gif"><img style="display: inline; border: 0px;" title="clip_image006" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image006_thumb.gif" border="0" alt="clip_image006" width="594" height="204" style=""></a>c.<a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image008.gif"><img style="display: inline; border: 0px;" title="clip_image008" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image008_thumb.gif" border="0" alt="clip_image008" width="599" height="211" style=""></a> <span style="color: #ff0000;">4. <strong>配置信息</strong> R1</span> ----------------------------------------------------------------------------------------------------------------- Current configuration : 826 bytes ! version 12.4 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R1 ! boot-start-marker boot-end-marker ! ! no aaa new-model memory-size iomem 5 ! ! ip cef ! interface FastEthernet0/0 ip address 192.168.0.9 255.255.255.252 duplex auto speed auto ! interface FastEthernet1/0 ip address 192.168.0.1 255.255.255.252 duplex auto speed auto ! interface FastEthernet2/0 ip address 192.168.0.5 255.255.255.252 duplex auto speed auto ! ip http server no ip http secure-server ip route 192.168.4.0 255.255.255.0 192.168.0.2 ip route 192.168.6.0 255.255.255.0 192.168.0.6 ip route 192.168.128.0 255.255.252.0 192.168.0.10 ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end ----------------------------------------------------------------------------------------------- <span style="color: #ff0000;">R2</span> ----------------------------------------------------------------------------------------------- Current configuration : 722 bytes ! version 12.4 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R2 ! boot-start-marker boot-end-marker ! ! no aaa new-model memory-size iomem 5 ! ! ip cef ! interface Loopback1 ip address 192.168.4.1 255.255.255.192 ! interface Loopback2 ip address 192.168.4.65 255.255.255.192 ! interface Loopback3 ip address 192.168.4.129 255.255.255.224 ! interface FastEthernet0/0 ip address 192.168.0.2 255.255.255.252 duplex auto speed auto ! ip http server no ip http secure-server ip route 0.0.0.0 0.0.0.0 192.168.0.1 ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end ----------------------------------------------------------------------------------------------- <span style="color: #ff0000;">R3</span> ----------------------------------------------------------------------------------------------- Current configuration : 659 bytes ! version 12.4 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R3 ! boot-start-marker boot-end-marker ! ! no aaa new-model memory-size iomem 5 ! ! ip cef ! interface Loopback1 ip address 192.168.6.1 255.255.255.128 interface Loopback2 ip address 192.168.6.129 255.255.255.224 ! interface FastEthernet0/0 ip address 192.168.0.6 255.255.255.252 duplex auto speed auto ! ip http server no ip http secure-server ip route 0.0.0.0 0.0.0.0 192.168.0.5 ! control-plane line con 0 line aux 0 line vty 0 4 ! ! end ---------------------------------------------------- <span style="color: #ff0000;">R4</span> ---------------------------------------------------------------------------------------------------------------- Current configuration : 658 bytes ! version 12.4 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R4 ! boot-start-marker boot-end-marker ! ! no aaa new-model memory-size iomem 5 ! ! ip cef ! interface Loopback1 ip address 192.168.128.1 255.255.255.0 ! interface Loopback2 ip address 192.168.130.1 255.255.255.0 ! interface FastEthernet0/0 ip address 192.168.0.10 255.255.255.252 duplex auto speed auto ! ip http server no ip http secure-server ip route 0.0.0.0 0.0.0.0 192.168.0.9 ! control-plane ! line con 0 line aux 0 line vty 0 4 ! ! end ------------------------------------------------------------------------------------------------------------------- <span style="color: #ff0000;"><strong>5. </strong><strong>路由表</strong></span><strong></strong> R1 <a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image010.gif"><img style="display: inline; border: 0px;" title="clip_image010" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image010_thumb.gif" border="0" alt="clip_image010" width="466" height="166" style=""></a> R2 <a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image012.gif"><img style="display: inline; border: 0px;" title="clip_image012" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image012_thumb.gif" border="0" alt="clip_image012" width="472" height="168" style=""></a> R3 <a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image014.gif"><img style="display: inline; border: 0px;" title="clip_image014" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image014_thumb.gif" border="0" alt="clip_image014" width="480" height="171" style=""></a> R4 <a href="https://www.crazycen.com/usr/uploads/2011/05/clip_image016.gif"><img style="display: inline; border: 0px;" title="clip_image016" src="https://www.crazycen.com/usr/uploads/2011/05/clip_image016_thumb.gif" border="0" alt="clip_image016" width="490" height="174" style=""></a> Last modification:October 6, 2023 © Allow specification reprint Support Appreciate the author AliPayWeChat Like 如果觉得我的文章对你有用,请随意赞赏