1,实验要求
2,实验步骤
①.划分网段,如下图所示,有4个直连网段,每个路由器的两个环回接口进行汇总,以便在后续操作中减少路由表条目数量。
四个路由器后面各需要一条网段,加上骨干链路需要一条网段,需要五条。
将192.168.1.0/24分出五个网段
192..168.1.0/24
192.168.1.000 00000/27 -- 骨干链路
192.168.1.000 000 00/30 -- 192.168.1.0/30
192.168.1.000 001 00/30 -- 192.168.1.4/30
192.168.1.000 010 00/30 -- 192.168.1.8/30
192.168.1.000 011 00/30 -- 192.168.1.12/30
192.168.1.000 100 00/30 -- 192.168.1.16/30
192.168.1.000 101 00/30 -- 192.168.1.20/30
192.168.1.000 110 00/30
192.168.1.000 111 00/30
192.168.1.32/27
192.168.1.32/28
192.168.1.48/28
192.168.1.001 00000/27 -- R1
192.168.1.001 0 0000/28
192.168.1.001 1 0000/28
192.168.1.64/27
192.168.1.64/28
192.168.1.80/28
192.168.1.010 00000/27 -- R2
192.168.1.010 0 0000/28
192.168.1.010 1 0000/28
192.168.1.96/27
192.168.1.96/28
192.168.1.112/28
192.168.1.011 00000/27 -- R3
192.168.1.011 0 0000/28
192.168.1.011 1 0000/28
192.168.1.128/27
192.168.1.128/28
192.168.1.144/28
192.168.1.100 00000/27 -- R4
192.168.1.100 0 0000/28
192.168.1.100 1 0000/28
下面三个网段用于后备资源
192.168.1.101 00000/27
192.168.1.110 00000/27
192.168.1.111 00000/27
②配置IP地址,分别在R1~R5上配置其端口及其环回地址的IP地址。
③配置静态路由,分别在五个路由器上配置其到各个网段及环回接口的静态路径。
[r1]ip route-static 192.168.1.64 27 192.168.1.2
[r1]ip route-static 192.168.1.8 30 192.168.1.2
[r1]ip route-static 192.168.1.128 27 192.168.1.2
[r1]ip route-static 192.168.1.128 27 192.168.1.6
[r1]ip route-static 192.168.1.16 30 192.168.1.2
[r1]ip route-static 192.168.1.16 30 192.168.1.6
[r1]ip route-static 192.168.1.12 30 192.168.1.6
[r1]ip route-static 192.168.1.96 27 192.168.1.6
[r2]ip route-static 192.168.1.128 27 192.168.1.10
[r2]ip route-static 192.168.1.16 30 192.168.1.10
[r2]ip route-static 192.168.1.12 30 192.168.1.10
[r2]ip route-static 192.168.1.96 27 192.168.1.10
[r2]ip route-static 192.168.1.96 27 192.168.1.1
[r2]ip route-static 192.168.1.4 30 192.168.1.1
[r2]ip route-static 192.168.1.32 27 192.168.1.1
[r3]ip route-static 192.168.1.32 27 192.168.1.5
[r3]ip route-static 192.168.1.0 30 192.168.1.5
[r3]ip route-static 192.168.1.64 27 192.168.1.5
[r3]ip route-static 192.168.1.64 27 192.168.1.14
[r3]ip route-static 192.168.1.8 30 192.168.1.14
[r3]ip route-static 192.168.1.128 27 192.168.1.14
[r3]ip route-static 192.168.1.16 30 192.168.1.14
[r4]ip route-static 192.168.1.96 27 192.168.1.13
[r4]ip route-static 192.168.1.4 30 192.168.1.13
[r4]ip route-static 192.168.1.32 27 192.168.1.13
[r4]ip route-static 192.168.1.32 27 192.168.1.9
[r4]ip route-static 192.168.1.0 30 192.168.1.9
[r4]ip route-static 192.168.1.64 27 192.168.1.9
[r5]ip route-static 192.168.1.32 27 192.168.1.17
[r5]ip route-static 192.168.1.64 27 192.168.1.17
[r5]ip route-static 192.168.1.96 27 192.168.1.17
[r5]ip route-static 192.168.1.128 27 192.168.1.17
[r5]ip route-static 192.168.1.0 30 192.168.1.17
[r5]ip route-static 192.168.1.4 30 192.168.1.17
[r5]ip route-static 192.168.1.8 30 192.168.1.17
[r5]ip route-static 192.168.1.12 30 192.168.1.17
④为了满足第三点要求,要配置缺省路由,R1指向R2或R3,R2指向R4,R3指向R4,R4指向R5的端口,最终通过缺省路由连接到5.5.5.0/24
[r1]ip route-static 0.0.0.0 0 192.168.1.2
[r1]ip route-static 0.0.0.0 0 192.168.1.6
[r2]ip route-static 0.0.0.0 0 192.168.1.10
[r3]ip route-static 0.0.0.0 0 192.168.1.14
[r4]ip route-static 0.0.0.0 0 192.168.1.18
⑤为避免环路出现,要创建空路径,使每个路由器指向其各自的换回地址的汇总。
[r1]ip route-static 192.168.1.32 27 NULL 0
[r2]ip route-static 192.168.1.64 27 NULL 0
[r3]ip route-static 192.168.1.96 27 NULL 0
[r4]ip route-static 192.168.1.128 27 NULL 0
⑥为满足第五点条件,要在每个路由器上配置到100M路径的静态路由,并在R4,R5上修改此路径的优先级,以实现正常1000M,故障100M的效果。
[r5]ip route-static 192.168.1.32 27 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.64 27 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.96 27 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.128 27 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.0 30 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.4 30 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.8 30 192.168.1.17 preference 70
[r5]ip route-static 192.168.1.12 30 192.168.1.17 preference 70