来源: 最后更新:22-12-07 09:06:36
一、组网要求
1) 交换机连接两个出口路由器,172.6.1.2为主线路,172.16.2.2为备用线路;
2)当主线路的物理线路失效,备用线路切换为主。
二、组网拓扑
三、配置要点
四、配置步骤
注意:配置之前建议使用 Ruijie#show interface status查看接口名称,常用接口名称有FastEthernet(百兆)、GigabitEthernet(千兆)和TenGigabitEthernet(万兆),以下配置以千兆接口为例
1)配置接口地址
Ruijie>enable
Ruijie#configure terminal
Ruijie(config)# interface GigabitEthernet 0/3
Ruijie(config-if-GigabitEthernet 0/3)#no switchport----->把接口属性改成路由接口
Ruijie(config-if-GigabitEthernet 0/3)#ip address 172.16.1.1 255.255.255.0----->配置地址
Ruijie(config)#interface GigabitEthernet 0/4
Ruijie(config-if-GigabitEthernet 0/4)#no switchport
Ruijie(config-if-GigabitEthernet 0/4)#ip address 172.16.2.1 255.255.255.0
2)配置浮动路由
Ruijie(config)#ip route 0.0.0.0 0.0.0.0 172.16.1.2
Ruijie(config)#ip route 0.0.0.0 0.0.0.0 172.16.2.2 10-----10为metric值,metric值越大优先级越低。默认是1
3) 保存配置
Ruijie(config)#end
Ruijie#write ----->确认配置正确,保存配置
五、验证命令:
正常情况下:
Ruijie#show ip route
Codes:C - connected, S - static, R - RIP, B - BGP
O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default
Gateway of last resort is 172.16.1.2 to network 0.0.0.0
S* 0.0.0.0/0 [1/0] via 172.16.1.2
C 172.16.1.0/24 is directly connected, GigabitEthernet 0/14
C 172.16.1.1/32 is local host.
C 172.16.2.0/24 is directly connected, GigabitEthernet 0/15
C 172.16.2.1/32 is local host.
当主线路down后:
Ruijie(config)#show ip route
Codes:C - connected, S - static, R - RIP, B - BGP
O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default
Gateway of last resort is 172.16.2.2 to network 0.0.0.0
S* 0.0.0.0/0 [10/0] via 172.16.2.2
C 172.16.1.0/24 is directly connected, GigabitEthernet 0/14
C 172.16.1.1/32 is local host.
C 172.16.2.0/24 is directly connected, GigabitEthernet 0/15
C 172.16.2.1/32 is local host.
帮同学化妆最高日入近千 帮朋友化妆帮同学化妆最高日入近千?浙江大二女生冲上热搜,彩妆,妆容,模特,王
2023吉林省紧缺急需职业工种目录政策解读 2024张杰上海演唱会启东直通车专线时间+票价 马龙谢幕,孙颖莎显示统治力,林诗栋紧追王楚钦,国乒新奥运周期竞争已启动 全世界都被吓了一跳(惊吓全世界)