HCIA—静态路由实验
实验要求:
1.除R5外的环回地址固定外,其他所有网段基于192.168.1.0/24进行合理IP地址划分
2.R1-R4每个路由器上存在两个环回接口,用于模拟连接PC的网段
3.R1-R4史昂泵直接写到达5.5.5.0/24的静态路由,但依然能够访问
4.全网可达,尽量减少每台路由器路由条目的数量,避免环路产生
5.R4和R5之间正常以1000M链路通信,故障时自动改为100M
实验拓扑:
IP地址规划:
192.168.1.0/24
骨干链路–6个
192.168.1.0/25
192.168.1.0/28
192.168.1.16/28
192.168.1.32/28
192.168.1.48/28
192.168.1.64/28
192.168.1.80/28
192.168.1.96/28
192.168.1.112/28
环回链路8个
192.168.1.128/25
R1:
100–128
192.168.1.128/27
192.168.1.128/28
192.168.1.144/28
R2:
101–160
192.168.1.160/27
192.168.1.160/28
192.168.1.176/28
R3:
110–192
192.168.1.192/27
192.168.1.192/28
192.168.1.208/28
R4:
111–224
192.168.1.224/27
192.168.1.224/28
192.168.1.240/28
配置:
R1:
IP地址:
interface GigabitEthernet0/0/0
ip address 192.168.1.1 255.255.255.240
interface GigabitEthernet0/0/1
ip address 192.168.1.50 255.255.255.240
interface GigabitEthernet0/0/2
interface NULL0
interface LoopBack0
ip address 192.168.1.129 255.255.255.240
interface LoopBack1
ip address 192.168.1.145 255.255.255.240
静态路由:
ip route-static 192.168.1.16 255.255.255.240 192.168.1.2
ip route-static 192.168.1.32 255.255.255.240 192.168.1.49
ip route-static 192.168.1.64 255.255.255.240 192.168.1.49
ip route-static 192.168.1.64 255.255.255.240 192.168.1.2
ip route-static 192.168.1.80 255.255.255.240 192.168.1.49
ip route-static 192.168.1.80 255.255.255.240 192.168.1.2
ip route-static 192.168.1.160 255.255.255.240 192.168.1.2
ip route-static 192.168.1.176 255.255.255.240 192.168.1.2
ip route-static 192.168.1.192 255.255.255.240 192.168.1.2
ip route-static 192.168.1.192 255.255.255.240 192.168.1.49
ip route-static 192.168.1.208 255.255.255.240 192.168.1.2
ip route-static 192.168.1.208 255.255.255.240 192.168.1.49
ip route-static 192.168.1.224 255.255.255.240 192.168.1.49
ip route-static 192.168.1.240 255.255.255.240 192.168.1.49
缺省路由:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.66
ip route-static 0.0.0.0 0.0.0.0 192.168.1.82
路由汇总:
ip route-static 192.168.1.128 255.255.255.224 LoopBack0
R2:
IP地址:
interface GigabitEthernet0/0/0
ip address 192.168.1.17 255.255.255.240
interface GigabitEthernet0/0/1
ip address 192.168.1.2 255.255.255.240
interface GigabitEthernet0/0/2
interface NULL0
interface LoopBack0
ip address 192.168.1.161 255.255.255.240
interface LoopBack1
ip address 192.168.1.177 255.255.255.240
静态路由:
ip route-static 192.168.1.48 255.255.255.240 192.168.1.1
ip route-static 192.168.1.64 255.255.255.240 192.168.1.18
ip route-static 192.168.1.80 255.255.255.240 192.168.1.18
ip route-static 192.168.1.128 255.255.255.240 192.168.1.1
ip route-static 192.168.1.144 255.255.255.240 192.168.1.1
ip route-static 192.168.1.192 255.255.255.240 192.168.1.18
ip route-static 192.168.1.208 255.255.255.240 192.168.1.1
ip route-static 192.168.1.224 255.255.255.240 192.168.1.1
ip route-static 192.168.1.240 255.255.255.240 192.168.1.1
缺省路由:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.66
ip route-static 0.0.0.0 0.0.0.0 192.168.1.82
路由汇总:
ip route-static 192.168.1.160 255.255.255.224 LoopBack0
R3:
IP地址:
interface GigabitEthernet0/0/0
ip address 192.168.1.33 255.255.255.240
interface GigabitEthernet0/0/1
ip address 192.168.1.18 255.255.255.240
interface GigabitEthernet0/0/2
ip address 192.168.1.81 255.255.255.240
interface GigabitEthernet4/0/0
ip address 192.168.1.65 255.255.255.240
interface LoopBack0
ip address 192.168.1.193 255.255.255.240
interface LoopBack1
ip address 192.168.1.209 255.255.255.240
静态路由:
ip route-static 192.168.1.0 255.255.255.240 192.168.1.17
ip route-static 192.168.1.48 255.255.255.240 192.168.1.34
ip route-static 192.168.1.128 255.255.255.240 192.168.1.17
ip route-static 192.168.1.128 255.255.255.240 192.168.1.34
ip route-static 192.168.1.144 255.255.255.240 192.168.1.17
ip route-static 192.168.1.144 255.255.255.240 192.168.1.34
ip route-static 192.168.1.160 255.255.255.240 192.168.1.17
ip route-static 192.168.1.176 255.255.255.240 192.168.1.17
ip route-static 192.168.1.224 255.255.255.240 192.168.1.34
ip route-static 192.168.1.240 255.255.255.240 192.168.1.34
缺省路由:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.66
ip route-static 0.0.0.0 0.0.0.0 192.168.1.82
路由汇总:
ip route-static 192.168.1.192 255.255.255.224 LoopBack0
R4:
interface GigabitEthernet0/0/0
ip address 192.168.1.49 255.255.255.240
interface GigabitEthernet0/0/1
ip address 192.168.1.34 255.255.255.240
interface GigabitEthernet0/0/2
interface NULL0
interface LoopBack0
ip address 192.168.1.225 255.255.255.240
interface LoopBack1
ip address 192.168.1.241 255.255.255.240
缺省路由:
ip route-static 0.0.0.0 0.0.0.0 192.168.1.66
ip route-static 0.0.0.0 0.0.0.0 192.168.1.82
静态路由:
ip route-static 192.168.1.0 255.255.255.240 192.168.1.50
ip route-static 192.168.1.16 255.255.255.240 192.168.1.33
ip route-static 192.168.1.64 255.255.255.240 192.168.1.33
ip route-static 192.168.1.80 255.255.255.240 192.168.1.33
ip route-static 192.168.1.128 255.255.255.240 192.168.1.50
ip route-static 192.168.1.144 255.255.255.240 192.168.1.50
ip route-static 192.168.1.160 255.255.255.240 192.168.1.33
ip route-static 192.168.1.160 255.255.255.240 192.168.1.50
ip route-static 192.168.1.176 255.255.255.240 192.168.1.33
ip route-static 192.168.1.176 255.255.255.240 192.168.1.50
ip route-static 192.168.1.192 255.255.255.240 192.168.1.33
ip route-static 192.168.1.208 255.255.255.240 192.168.1.33
汇总路由:
ip route-static 192.168.1.224 255.255.255.224 LoopBack0
修改路由优先级:
ip route-static 5.5.5.5 255.255.255.255 192.168.1.80 preference 70
R5:
IP地址:
interface GigabitEthernet0/0/0
ip address 192.168.1.66 255.255.255.240
interface GigabitEthernet0/0/1
interface GigabitEthernet0/0/2
ip address 192.168.1.82 255.255.255.240
interface LoopBack0
ip address 5.5.5.5 255.255.255.0
静态路由:
ip route-static 192.168.1.0 255.255.255.240 192.168.1.65
ip route-static 192.168.1.0 255.255.255.240 192.168.1.81
ip route-static 192.168.1.16 255.255.255.240 192.168.1.65
ip route-static 192.168.1.16 255.255.255.240 192.168.1.81
ip route-static 192.168.1.32 255.255.255.240 192.168.1.65
ip route-static 192.168.1.32 255.255.255.240 192.168.1.81
ip route-static 192.168.1.48 255.255.255.240 192.168.1.65
ip route-static 192.168.1.48 255.255.255.240 192.168.1.81
ip route-static 192.168.1.128 255.255.255.240 192.168.1.65
ip route-static 192.168.1.128 255.255.255.240 192.168.1.81
ip route-static 192.168.1.144 255.255.255.240 192.168.1.65
ip route-static 192.168.1.144 255.255.255.240 192.168.1.81
ip route-static 192.168.1.160 255.255.255.240 192.168.1.65
ip route-static 192.168.1.160 255.255.255.240 192.168.1.81
ip route-static 192.168.1.176 255.255.255.240 192.168.1.65
ip route-static 192.168.1.176 255.255.255.240 192.168.1.81
ip route-static 192.168.1.192 255.255.255.240 192.168.1.65
ip route-static 192.168.1.192 255.255.255.240 192.168.1.81
ip route-static 192.168.1.208 255.255.255.240 192.168.1.65
ip route-static 192.168.1.208 255.255.255.240 192.168.1.81
ip route-static 192.168.1.224 255.255.255.240 192.168.1.65
ip route-static 192.168.1.224 255.255.255.240 192.168.1.81
ip route-static 192.168.1.240 255.255.255.240 192.168.1.65
ip route-static 192.168.1.240 255.255.255.240 192.168.1.81