一、 拓扑图
二、 接口配置
R1 配置
R1(config)#interface f0/0
R1(config-if)#ip address 172.16.12.1 255.255.255.0
R1(config-if)#no shutdown
R2 配置
R2(config)#interface f0/0
R2(config-if)#ip address 172.16.12.2 255.255.255.0
R2(config-if)#no shutdown
R2(config-if)#interface f0/1
R2(config-if)#ip address 172.16.23.2 255.255.255.0
R2(config-if)#no shutdown
R3 配置
R3(config)#interface f0/0
R3(config-if)#ip address 172.16.23.3 255.255.255.0
R3(config-if)#no shutdown
三、 协议配置(RIPv1)
R1 配置
R1(config)#router rip
R1(config-router)#no auto-summary (关闭自动汇总)
R1(config-router)#network 172.16.12.0
R2 配置
R2(config)#router rip
R2(config-router)#no auto-summary (关闭自动汇总)
R2(config-router)#network 172.16.12.0
R2(config-router)#network 172.16.23.0
R3 配置
R3(config)#router rip
R3(config-router)#no auto-summary (关闭自动汇总)
R3(config-router)#network 172.16.23.0
四、 问题说明
1. 测试
R1#ping 172.16.23.3
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.23.3, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 62/62/63 ms2
2. 实验说明
启动并配置好 RIP 协议之后,路由器会自动学到 每一个路由的路由条目。
转载于:https://blog.51cto.com/3352007/671861