接口配置省略R1router ripnetwork 192.168.10.0network 192.168.0.0network 192.168.1.0 R2router ripnetwork 192.168.20.0network 192.168.2.0network 192.168.0.0 R3router ripnetwrok 192.168.30.0network 192.168.2.0network 192.168.1.0network 192.168.3.0 R4router ripnetwork 192.168.40.0network 192.168.3.0 路由表R1R 192.168.30.0/24 [120/1] via 192.168.1.2, 00:00:10, FastEthernet0/0C 192.168.10.0/24 is directly connected, Loopback0R 192.168.40.0/24 [120/2] via 192.168.1.2, 00:00:10, FastEthernet0/0R 192.168.20.0/24 [120/1] via 192.168.0.2, 00:00:04, FastEthernet1/0C 192.168.0.0/24 is directly connected, FastEthernet1/0C 192.168.1.0/24 is directly connected, FastEthernet0/0R 192.168.2.0/24 [120/1] via 192.168.1.2, 00:00:10, FastEthernet0/0 [120/1] via 192.168.0.2, 00:00:04, FastEthernet1/0R 192.168.3.0/24 [120/1] via 192.168.1.2, 00:00:12, FastEthernet0/0R2R 192.168.30.0/24 [120/1] via 192.168.2.1, 00:00:00, FastEthernet0/0R 192.168.10.0/24 [120/1] via 192.168.0.1, 00:00:09, FastEthernet1/0R 192.168.40.0/24 [120/2] via 192.168.2.1, 00:00:00, FastEthernet0/0C 192.168.20.0/24 is directly connected, Loopback0C 192.168.0.0/24 is directly connected, FastEthernet1/0R 192.168.1.0/24 [120/1] via 192.168.2.1, 00:00:00, FastEthernet0/0 [120/1] via 192.168.0.1, 00:00:09, FastEthernet1/0C 192.168.2.0/24 is directly connected, FastEthernet0/0R 192.168.3.0/24 [120/1] via 192.168.2.1, 00:00:02, FastEthernet0/0R3C 192.168.30.0/24 is directly connected, Loopback0R 192.168.10.0/24 [120/1] via 192.168.1.1, 00:00:25, FastEthernet1/0R 192.168.40.0/24 [120/1] via 192.168.3.1, 00:00:21, FastEthernet2/0R 192.168.20.0/24 [120/1] via 192.168.2.2, 00:00:24, FastEthernet0/0R 192.168.0.0/24 [120/1] via 192.168.2.2, 00:00:24, FastEthernet0/0 [120/1] via 192.168.1.1, 00:00:25, FastEthernet1/0C 192.168.1.0/24 is directly connected, FastEthernet1/0C 192.168.2.0/24 is directly connected, FastEthernet0/0C 192.168.3.0/24 is directly connected, FastEthernet2/0R4R 192.168.30.0/24 [120/1] via 192.168.3.2, 00:00:13, FastEthernet0/0R 192.168.10.0/24 [120/2] via 192.168.3.2, 00:00:13, FastEthernet0/0C 192.168.40.0/24 is directly connected, Loopback0R 192.168.20.0/24 [120/2] via 192.168.3.2, 00:00:13, FastEthernet0/0R 192.168.0.0/24 [120/2] via 192.168.3.2, 00:00:13, FastEthernet0/0R 192.168.1.0/24 [120/1] via 192.168.3.2, 00:00:13, FastEthernet0/0R 192.168.2.0/24 [120/1] via 192.168.3.2, 00:00:13, FastEthernet0/0C 192.168.3.0/24 is directly connected, FastEthernet0/0标红的路由条目表示到目标网段有两条路径可走,跳数相同,因为RIP是以跳数作为度量值的扩展RIPv2内容(修改lo 0 参数)把 R1 lo 0 修改为10.10.10.1/24把R2 lo 0 修改为10.10.20.1/24把R3 lo 0 修改为10.10.30.1/24把R4 lo 0 修改为10.10.40.1/24然后每台路由宣告lo 0 网段network 10.0.0.0路由表R1 R 10.0.0.0/8 [120/1] via 192.168.1.2, 00:00:15, FastEthernet0/0R2R 10.0.0.0/8 [120/1] via 192.168.2.1, 00:00:16, FastEthernet0/0 [120/1] via 192.168.0.1, 00:00:15, FastEthernet1/0R3R 10.0.0.0/8 [120/1] via 192.168.1.1, 00:00:02, FastEthernet1/0R4 R 10.0.0.0/8 [120/1] via 192.168.3.2, 00:00:14, FastEthernet0/0
R1 到10.10.20.1不通 10.10.30.1通 10.10.40.1不通R2 到10.10.10.1通 10.10.30.1 通 10.10.40.1不通R3到 10.10.10.1通 10.10.20.1 不通 10.10.40.1不通R4 到10.10.10.1通 10.10.20.1不通 10.10.30.1通解决办法:用RIPv2并且禁止路由汇总路由表R1R 10.10.20.0 [120/1] via 192.168.0.2, 00:00:12, FastEthernet1/0R 10.10.30.0 [120/1] via 192.168.1.2, 00:00:19, FastEthernet0/0R 10.10.40.0 [120/2] via 192.168.1.2, 00:00:19, FastEthernet0/0R2R 10.10.10.0 [120/1] via 192.168.0.1, 00:00:04, FastEthernet1/0R 10.10.30.0 [120/1] via 192.168.2.1, 00:00:11, FastEthernet0/0R 10.10.40.0 [120/2] via 192.168.2.1, 00:00:11, FastEthernet0/0R3R 10.10.10.0 [120/1] via 192.168.1.1, 00:00:09, FastEthernet1/0R 10.10.20.0 [120/1] via 192.168.2.2, 00:00:21, FastEthernet0/0R 10.10.40.0 [120/1] via 192.168.3.1, 00:00:15, FastEthernet2/0R4R 10.10.10.0 [120/2] via 192.168.3.2, 00:00:29, FastEthernet0/0R 10.10.20.0 [120/2] via 192.168.3.2, 00:00:29, FastEthernet0/0R 10.10.30.0 [120/1] via 192.168.3.2, 00:00:29, FastEthernet0/0全网互通成功 












