Tool used in the experiment: Xiao fan Simulator
1. On router R1, configure the interface, start the ospf routing process and rip, advertise the network segment, and configure route redistribution.
★☆R1 ☆★☆→
Router>
Router> enable
Router # config terminal
Router (config) # hostname R1-jin
R1-jin (config) # interface loopback 0
R1-jin (config-if) # ip address 1.1.1.1 255.255.255.255
R1-jin (config-if) # interface f0/0
R1-jin (config-if) # ip address 10.0.0.1 255.0.0.0
R1-jin (config-if) # no shutdown
R1-jin (config-if) # interface f1/0
R1-jin (config-if) # ip address 192.168.0.1 255.255.255.0
R1-jin (config-if) # no shutdown
R1-jin (config-if) # exit
R1-jin (config) # router rip
R1-jin (config-router) # network 10.0.0.0
R1-jin (config-router) # exit
R1-jin (config) # router ospf 1
R1-jin (config-router) # network 192.168.0.1 0.0.0.0 area 1
R1-jin (config-router) # redistribute rip metric 100 subnets -- route redistribution (RIP → OSPF)
R1-jin (config-router) # exit
R1-jin (config) # end
R1-jin #
2. configure interfaces on routers R2, R3, and R4, start the ospf routing process, and declare network segments
★☆R2 ☆★
Router>
Router> enable
Router # config terminal
Router (config) # hostname R2-jin
R2-jin (config) # interface loopback 0
R2-jin (config-if) # ip address 2.2.2.2 255.255.255.255
R2-jin (config-if) # exit
R2-jin (config) # interface f1/0
R2-jin (config-if) # ip address 192.168.0.2 255.255.255.0
R2-jin (config-if) # no shutdown
R2-jin (config-if) # interface f0/0
R2-jin (config-if) # ip address 172.16.0.2 255.255.255.0.0
R2-jin (config-if) # no shutdown
R2-jin (config-if) # exit
R2-jin (config) # router ospf 1
R2-jin (config-router) # network 192.168.0.2 0.0.0.0 area 1
R2-jin (config-router) # network 172.16.0.2 0.0.0.0 area 2
R2-jin (config-router) # exit
★☆R3 ☆★
Router>
Router> enable
Router # config terminal
Router (config) # hostname R3-jin
R3-jin (config) # interface loopback 0
R3-jin (config-if) # ip address 3.3.3.3 255.255.255.255
R3-jin (config-if) # exit
R3-jin (config) # interface f0/0
R3-jin (config-if) # ip address 172.16.0.1 255.255.255.0.0
R3-jin (config-if) # no shutdown
R3-jin (config-if) # interface s1/0
R3-jin (config-if) # ip address 192.168.1.1 255.255.255.0
R3-jin (config-if) # no shutdown
R3-jin (config-if) # exit
R3-jin (config) # router ospf 1
R3-jin (config-router) # network 172.16.0.1 0.0.0.0 area 2
R3-jin (config-router) # network 192.168.1.1 0.0.0.0 area 0
R3-jin (config-router) # exit
★☆R4 ☆★
Router>
Router> enable
Router # config terminal
Router (config) # hostname R4-jin
R4-jin (config) # interface loopback 0
R4-jin (config-if) # ip address 4.4.4.4 255.255.255.255
R4-jin (config-if) # exit
R4-jin (config) # interface s1/0
R4-jin (config-if) # clock rate 128000
R4-jin (config-if) # ip address 192.168.1.2 255.255.255.0
R4-jin (config-if) # no shutdown
R4-jin (config-if) # interface f0/0
R4-jin (config-if) # ip address 255.0.0.1 255.0.0.0
R4-jin (config-if) # no shutdown
R4-jin (config-if) # exit
R4-jin (config) # router ospf 1
R4-jin (config-router) # network 192.168.1.2 0.0.0.0 area 0
R4-jin (config-router) # network protocol 0.0.1 0.0.0.0 area 0
R4-jin (config-router) # exit
R4-jin (config) # end
3. Configure virtual links on routers R2 and R3 and view the route table status of each Router
★☆R2 ☆★
R2-jin (config )#
R2-jin (config) # router ospf 1
R2-jin (config-router) # area 2 virtual-link 3.3.3.3 -- virtual link (R2 → R3)
R2-jin (config-router) # end
R2-jin # show ip route
2.0.0.0/32 is subnetted, 1 subnets
C 2.2.2.2 is directly connected, Loopback0
O route 0.0.0/8 [110/66] via 172.16.0.1, 00:00:10, FastEthernet0/0
C 172.16.0.0/16 is directly connected, FastEthernet0/0
O E2 10.0.0.0/8 [110/100] via 192.168.0.1, 00:00:10, FastEthernet1/0
C 192.168.0.0/24 is directly connected, FastEthernet1/0
O 192.168.1.0/24 [110/65] via 172.16.0.1, 00:00:10, FastEthernet0/0
R2-jin #
★☆R3 ☆★
R3-jin (config )#
R3-jin (config) # router ospf 1
R3-jin (config-router) # area 2 virtual-link 2.2.2.2 -- virtual link (R3 → R2)
R3-jin (config-router) # end
R3-jin # show ip route
3.0.0.0/32 is subnetted, 1 subnets
C 3.3.3.3 is directly connected, Loopback0
O route 0.0.0/8 [110/65] via 192.168.1.2, 00:00:16, Serial1/0
C 172.16.0.0/16 is directly connected, FastEthernet0/0
O E2 10.0.0.0/8 [110/100] via 172.16.0.2, 00:00:16, FastEthernet0/0
O ia 192.168.0.0/24 [110/2] via 172.16.0.2, 00:00:16, FastEthernet0/0
C 192.168.1.0/24 is directly connected, Serial1/0
R3-jin #
★☆R1 ☆★
R1-jin # show ip route
1.0.0.0/32 is subnetted, 1 subnets
C 1.1.1.1 is directly connected, Loopback0
O ia 255.0.0.0/8 [110/67] via 192.168.0.2, 00:00:04, FastEthernet1/0
O ia 172.16.0.0/16 [110/2] via 192.168.0.2, 00:00:53, FastEthernet1/0
C 10.0.0.0/8 is directly connected, FastEthernet0/0
C 192.168.0.0/24 is directly connected, FastEthernet1/0
O ia 192.168.1.0/24 [110/66] via 192.168.0.2, 00:00:04, FastEthernet1/0
R1-jin #
★☆R4 ☆★
R4-jin # show ip route
4.0.0.0/32 is subnetted, 1 subnets
C 4.4.4.4 is directly connected, Loopback0
C versions 0.0.0/8 is directly connected, FastEthernet0/0
O ia 172.16.0.0/16 [110/65] via 192.168.1.1, 00:00:34, Serial1/0
O E2 10.0.0.0/8 [110/100] via 192.168.1.1, 00:00:34, Serial1/0
O ia 192.168.0.0/24 [110/66] via 192.168.1.1, 00:00:34, Serial1/0
C 192.168.1.0/24 is directly connected, Serial1/0
R4-jin #
4. Perform a non-pure peripheral area on area1 (R1, R2) and view route table changes.
★☆R1 ☆★
R1-jin #
R1-jin # config terminal
R1-jin (config) # router ospf 1
R1-jin (config-router) # area 1 nssa
R1-jin (config-router) # end
R1-jin # show ip route
Press RETURN to get started., 1 subnets
C 1.1.1.1 is directly connected, Loopback0
C 10.0.0.0/8 is directly connected, FastEthernet0/0
C 192.168.0.0/24 is directly connected, FastEthernet1/0
R1-jin #
★☆R2 ☆★
R2-jin #
R2-jin # config terminal
R2-jin (config) # router ospf 1
R2-jin (config-router) # area 1 nssa
R2-jin (config-router) # end
R2-jin # show ip route
2.0.0.0/32 is subnetted, 1 subnets
C 2.2.2.2 is directly connected, Loopback0
O route 0.0.0/8 [110/66] via 172.16.0.1, 00:00:01, FastEthernet0/0
C 172.16.0.0/16 is directly connected, FastEthernet0/0
C 192.168.0.0/24 is directly connected, FastEthernet1/0
O 192.168.1.0/24 [110/65] via 172.16.0.1, 00:00:01, FastEthernet0/0
★☆R3 ☆★
R3-jin # show ip route
★☆R4 ☆★
R4-jin # show ip route
5. Configure the PC for verification
VPCS 1>
VPCS 1> show
VPCS 1> ip 10.0.0.2 10.0.0.1 8
VPCS 1> 2
VPCS 2> ip address 255.0.0.2 255.0.0.1 8
VPCS 2> show
Name ip/CIDR GATEWAY LPORT RPORT
PC1 10.0.0.2/8 10.0.0.1 10001 11100
PC2 255.0.0.2/8 255.0.0.1 10002 11400
PC3 0.0.0.0/0 0.0.0.0 10003 30002
PC4 0.0.0.0/0 0.0.0.0 10004 30003
PC5 0.0.0.0/0 0.0.0.0 10005 30004
PC6 0.0.0.0/0 0.0.0.0 10006 30005
PC7 0.0.0.0/0 0.0.0.0 10007 30006
Pc80.0.0.0/0 0.0.0.0 10008 30007
PC9 0.0.0.0/0 0.0.0.0 10009 30008
VPCS 2> ping 10.0.0.2
10.0.0.2 icmp_seq = 1 timeout
10.0.0.2 icmp_seq = 2 time = 156.000 MS
10.0.0.2 icmp_seq = 3 time = 218.000 MS
10.0.0.2 icmp_seq = 4 time = 141.000 MS
10.0.0.2 icmp_seq = 5 time = 172.000 MS
VPCS 2>
OK !!!! The experiment is complete !!!
Author: ""