静态综合实验
一、合理划分IP地址
将192.168.1.0/24该网段的IP地址合理划分,确保IP地址不要造成浪费。
将192.168.1.0/24,先划分为8个网段:
192.168.1.0/27
192.168.1.32/27
192.168.1.64/27
192.168.1.96/27
192.168.1.128/27
192.168.1.160/27
192.168.1.192/27
192.168.1.224/27
将192.168.1.0/27的地址再次进行子网划分,取其中6段子网,用来作为路由器接口的IP网段(骨干链路)使用,其他作为备用网段。
子网划分结果:
192.168.1.0/30
192.168.1.4/30
192.168.1.8/30
192.168.1.12/30
192.168.1.16/30
192.168.1.20/30
192.168.1.24/30
192.168.1.28/30
二、配置IP地址
在系统视图下输入"interface GigabitEthernet 0/0/0",进入接口后,再次输入"ip address 192.168.1.1 30",为每一个路由器接口配置IP地址。
在系统视图下输入"interface LoopBack 0",进入环回接口,再次输入"ip address 192.168.1.33 28",为每一个环回接口配置IP地址。
1,对AR1设备进行IP配置
2,对AR2设备进行IP配置
3,对AR3设备进行IP配置
4,对AR4设备进行IP配置
5,对AR5设备进行IP配置
三、配置静态路由
对AR1进行配置
同理,使用相同的命令为其他路由器添加路由表。
四、添加空接口,避免环路出现
[r1]ip route-static 192.168.1.96 27 NULL 0
[r2]ip route-static 192.168.1.32 27 NULL 0
[r3]ip route-static 192.168.1.64 27 NULL 0
[r4]ip route-static 192.168.1.128 27 NULL 0
五、更改优先级
[r5]ip route-static 192.168.1.128 27 192.168.1.21 preference 61
[r5]ip route-static 192.168.1.32 27 192.168.1.21 preference 61
[r5]ip route-static 192.168.1.96 27 192.168.1.21 preference 61
[r5]ip route-static 192.168.1.64 27 192.168.1.21 preference 61
[r5]ip route-static 192.168.1.0 30 192.168.1.21 preference 61
[r5]ip route-static 192.168.1.4 30 192.168.1.21 preference 61
[r5]ip route-static 192.168.1.8 30 192.168.1.21 preference 61