设备搭建
要进行IP地址划分 ,先要搞清楚有几个网段:
因为在第二点要求中需要r1~r4路由器都要有两个环回接口 ,一个环回接口就是一个广播域,一个广播域就得划分一个网段,所以每一个环回接口都要单独配一个网段 所以应该有14个网段。
2.因为16>14>8所以应该划分16个网段 ,为了减少黑洞路由的可能性, 我们从小到大取IP网段和接口的IP地址如下:
注意:因为在第五点要求中 需要分别有一个1000M和一百M链路通信,所以对AR4加入了一块FE WAN接口卡如图:
设备设置
按图对路由器端口IP设置(因为各路由器的设置类似 所以只展示了AR 1的GE0/0/0接口的配置过程 ):
配置完成后,对R1~R4配置环回接口,且在192.168.1.0/24范围内(因为配置过程相似 所以只展示了AR 1的配置过程 ):
配置路由
配置操作如下 :
AR1
[AR1]ip route-static 192.168.1.64 27 192.168.1.50
[AR1]ip route-static 192.168.1.96 28 192.168.1.50
[AR1]ip route-static 192.168.1.112 28 192.168.1.50
[AR1]ip route-static 192.168.1.128 28 192.168.1.50
[AR1]ip route-static 192.168.1.144 28 192.168.1.1
[AR1]ip route-static 192.168.1.160 27 192.168.1.1
AR2
[AR2]ip route-static 192.168.1.0 26 192.168.1.49
[AR2]ip route-static 192.168.1.0 28 192.168.1.49
[AR2]ip route-static 192.168.1.160 27 192.168.1.49
[AR2]ip route-static 192.168.1.144 28 192.168.1.98
[AR2]ip route-static 192.168.1.128 28 192.168.1.98
[AR2]ip route-static 192.168.1.112 28 192.168.1.98
AR3
[AR3]ip route-static 192.168.1.64 27 192.168.1.97
[AR3]ip route-static 192.168.1.48 28 192.168.1.97
[AR3]ip route-static 192.168.1.0 26 192.168.1.97
[AR3]ip route-static 192.168.1.0 28 192.168.1.146
[AR3]ip route-static 192.168.1.160 27 192.168.1.146
AR4
[AR4]ip route-static 192.168.1.96 28 192.168.1.145
[AR4]ip route-static 192.168.1.0 26 192.168.1.2
[AR4]ip route-static 192.168.1.64 27 192.168.1.2
[AR4]ip route-static 192.168.1.48 28 192.168.1.2
[AR4]ip route-static 192.168.1.128 28 192.168.1.145
[AR4]ip route-static 192.168.1.112 28 192.168.1.145
AR5
[AR5]ip route-static 192.168.1.0 28 192.168.1.209
[AR5]ip route-static 192.168.1.0 26 192.168.1.209
[AR5]ip route-static 192.168.1.48 28 192.168.1.209
[AR5]ip route-static 192.168.1.64 27 192.168.1.209
[AR5]ip route-static 192.168.1.96 28 192.168.1.209
[AR5]ip route-static 192.168.1.112 28 192.168.1.209
[AR5]ip route-static 192.168.1.128 28 192.168.1.209
[AR5]ip route-static 192.168.1.144 28 192.168.1.209
[AR5]ip route-static 192.168.1.160 27 192.168.1.209
随机测试结果如下:
创建一个AR5的换回接口:
地址为5.5.5.1/24:
配置缺省路由:
使5.5.5.0/24互通(因为配置过程相似,所以只显示了AR2的配置过程):
测试:
破环设置:
[AR1]ip route-static 192.168.1.0 26 NULL 0
[AR2]ip route-static 192.168.1.64 27 null 0
[AR4]ip route-static 192.168.1.160 27 NULL 0
做AR5的备份:
[AR5]ip route-static 192.168.1.160 27 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.0 28 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.144 28 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.112 28 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.128 28 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.0 26 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.48 28 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.96 28 192.168.1.193 preference 61
[AR5]ip route-static 192.168.1.64 27 192.168.1.193 preference 61
检测备份结果:
将1000M口断开,检测100M是否接通:
实验结果满足要求,试验结束。