|
configure terminal | interface loopback 0 | Ip address 1.1.1.1 255.255.255.0 | Router rip | Version 2 | No auto-summary | Network 1.0.0.0 | exit |
Configuration : R1
interface Loopback0 ip address 1.1.1.1 255.255.255.0 ! interface FastEthernet0/0 ip address 12.12.12.1 255.255.255.0 duplex auto speed auto ! router rip version 2 network 1.0.0.0 network 12.0.0.0 no auto-summary
| R1#show ip route Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP D - EIGRP, EX - EIGRP external, 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, U - per-user static route o - ODR, P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/24 is subnetted, 1 subnets C 1.1.1.0 is directly connected, Loopback0 23.0.0.0/24 is subnetted, 1 subnets R 23.23.23.0 [120/1] via 12.12.12.2, 00:00:13, FastEthernet0/0 12.0.0.0/24 is subnetted, 1 subnets C 12.12.12.0 is directly connected, FastEthernet0/0 | R2 interface FastEthernet0/0 ip address 12.12.12.2 255.255.255.0 duplex auto speed auto ! interface FastEthernet0/1 ip address 23.23.23.2 255.255.255.0 duplex auto speed auto router rip version 2 network 12.0.0.0 network 23.0.0.0 no auto-summary
| R2#show ip route Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP D - EIGRP, EX - EIGRP external, 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, U - per-user static route o - ODR, P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/24 is subnetted, 1 subnets R 1.1.1.0 [120/1] via 12.12.12.1, 00:00:01, FastEthernet0/0 23.0.0.0/24 is subnetted, 1 subnets C 23.23.23.0 is directly connected, FastEthernet0/1 12.0.0.0/24 is subnetted, 1 subnets C 12.12.12.0 is directly connected, FastEthernet0/0 | R3 interface Loopback0 ip address 3.3.3.3 255.255.255.0 interface FastEthernet0/0 ip address 23.23.23.3 255.255.255.0 duplex auto speed auto router rip version 2 network 3.0.0.0 network 23.0.0.0 no auto-summary !
| R3#show ip route Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP D - EIGRP, EX - EIGRP external, 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, U - per-user static route o - ODR, P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/24 is subnetted, 1 subnets R 1.1.1.0 [120/2] via 23.23.23.2, 00:00:21, FastEthernet0/0 23.0.0.0/24 is subnetted, 1 subnets C 23.23.23.0 is directly connected, FastEthernet0/0 12.0.0.0/24 is subnetted, 1 subnets R 12.12.12.0 [120/1] via 23.23.23.2, 00:00:21, FastEthernet0/0 |
测试: R3#ping 1.1.1.1 source 3.3.3.3
Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds: Packet sent with a source address of 3.3.3.3 !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 44/90/148 ms | R1#ping 3.3.3.3 source 1.1.1.1
Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 3.3.3.3, timeout is 2 seconds: Packet sent with a source address of 1.1.1.1 !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 44/74/128 ms |
|
|