OSPF|OSPF 综合实验



要求:
1.区域0 实现区域验证 区域23接口验证
2.区域145 NSSA 掌握NSSA和完全NSSA 区别
R1
interface Loopback0
ip address 1.1.1.1 255.255.255.255
!
interface Loopback1
ip address 20.1.1.1 255.255.255.0
!
interface Loopback2
ip address 20.1.2.1 255.255.255.0
!
interface Loopback3
ip address 20.1.3.1 255.255.255.0
!
interface Ethernet0/0
ip address 192.168.12.1 255.255.255.0
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet0/1
ip address 192.168.18.1 255.255.255.0
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet0/2
no ip address
shutdown
half-duplex
!
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
interface Serial1/0
ip address 192.168.145.1 255.255.255.0
encapsulation frame-relay
ip ospf network broadcast
ip ospf priority 10
serial restart-delay 0
no fair-queue
frame-relay map ip 192.168.145.1 103
frame-relay map ip 192.168.145.4 104 broadcast
frame-relay map ip 192.168.145.5 105 broadcast
no frame-relay inverse-arp
!
interface Serial1/1
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
router ospf 10
router-id 1.1.1.1
log-adjacency-changes
area 0 authentication message-digest
area 18 virtual-link 8.8.8.8 authentication
area 18 virtual-link 8.8.8.8 message-digest-key 1 md5 cisco
area 145 nssa no-redistribution default-information-originate no-summary
network 1.1.1.1 0.0.0.0 area 145
network 20.1.1.0 0.0.0.255 area 0
network 20.1.2.0 0.0.0.255 area 0
network 20.1.3.0 0.0.0.255 area 0
network 192.168.12.0 0.0.0.255 area 0
network 192.168.18.0 0.0.0.255 area 18
network 192.168.145.0 0.0.0.255 area 145
R2
interface Loopback0
ip address 2.2.2.2 255.255.255.255
!
interface Loopback1
ip address 172.16.2.2 255.255.255.0
!
interface Ethernet0/0
ip address 192.168.12.2 255.255.255.0
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
ip address 192.168.23.2 255.255.255.0
ip ospf authentication message-digest
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet0/3
ip address 192.168.28.2 255.255.255.0
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet1/0
no ip address
shutdown
half-duplex
!
interface Ethernet1/1
no ip address
shutdown
half-duplex
!
interface Ethernet1/2
no ip address
shutdown
half-duplex
!
interface Ethernet1/3
no ip address
shutdown
half-duplex
!
router eigrp 100
network 172.16.2.0 0.0.0.255
no auto-summary
!
router ospf 10
router-id 2.2.2.2
log-adjacency-changes
area 0 authentication message-digest
area 23 stub no-summary
area 28 virtual-link 8.8.8.8 authentication
area 28 virtual-link 8.8.8.8 message-digest-key 1 md5 cisco
redistribute eigrp 100 metric 120 subnets
network 192.168.12.0 0.0.0.255 area 0
network 192.168.23.0 0.0.0.255 area 23
network 192.168.28.0 0.0.0.255 area 28
R3

interface Loopback0
ip address 3.3.3.3 255.255.255.255
!
interface Ethernet0/0
no ip address
shutdown
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
ip address 192.168.23.3 255.255.255.0
ip ospf authentication message-digest
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
router ospf 10
router-id 3.3.3.3
log-adjacency-changes
area 23 stub
network 192.168.23.0 0.0.0.255 area 23
R4
interface Loopback0
ip address 4.4.4.4 255.255.255.255
!
interface Serial0/0
no ip address
shutdown
serial restart-delay 0
no fair-queue
!
interface Serial0/1
ip address 192.168.145.4 255.255.255.0
encapsulation frame-relay
ip ospf network broadcast
ip ospf priority 0
serial restart-delay 0
frame-relay map ip 192.168.145.1 401 broadcast
no frame-relay inverse-arp
!
interface Serial0/2
no ip address
shutdown
serial restart-delay 0
!
interface Serial0/3
no ip address
shutdown
serial restart-delay 0
!
router ospf 10
router-id 4.4.4.4
log-adjacency-changes
area 145 nssa
network 4.4.4.4 0.0.0.0 area 145
network 192.168.145.0 0.0.0.255 area 145
R5
!
interface Loopback0
ip address 5.5.5.5 255.255.255.255
!
interface Ethernet0/0
ip address 192.168.57.5 255.255.255.0
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
no ip address
shutdown
half-duplex
!
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
interface Serial1/0
no ip address
shutdown
serial restart-delay 0
no fair-queue
!
interface Serial1/1
no ip address
shutdown
serial restart-delay 0
!
interface Serial1/2
ip address 192.168.145.5 255.255.255.0
encapsulation frame-relay
ip ospf network broadcast
ip ospf priority 0
serial restart-delay 0
frame-relay map ip 192.168.145.1 501 broadcast
no frame-relay inverse-arp
!
interface Serial1/3
no ip address
shutdown
serial restart-delay 0
!
router ospf 10
router-id 5.5.5.5
log-adjacency-changes
area 145 nssa
redistribute rip metric 100 subnets
network 5.5.5.5 0.0.0.0 area 145
network 192.168.145.0 0.0.0.255 area 145
!
router rip
version 2
network 192.168.57.0
no auto-summary
!
R6
!
interface Loopback0
ip address 6.6.6.6 255.255.255.255
!
interface Ethernet0/0
ip address 192.168.68.6 255.255.255.0
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
no ip address
shutdown
half-duplex
!
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
router ospf 10
router-id 6.6.6.6
log-adjacency-changes
network 6.6.6.6 0.0.0.0 area 68
network 192.168.68.0 0.0.0.255 area 68
R7
interface Loopback0
ip address 7.7.7.7 255.255.255.255
!
interface Loopback1
ip address 10.1.1.7 255.255.255.0
!
interface Loopback2
ip address 10.1.2.7 255.255.255.0
!
interface Loopback3
ip address 10.1.3.7 255.255.255.0
!
interface Ethernet0/0
ip address 192.168.57.7 255.255.255.0
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
no ip address
shutdown
half-duplex
!
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
router rip
version 2
network 10.0.0.0
network 192.168.57.0
no auto-summary
R8
interface Loopback0
ip address 8.8.8.8 255.255.255.255
!
interface Ethernet0/0
ip address 192.168.68.8 255.255.255.0
half-duplex
!
interface Ethernet0/1
ip address 192.168.18.8 255.255.255.0
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
interface Ethernet0/2
ip address 192.168.28.8 255.255.255.0
shutdown
half-duplex
!
interface Ethernet0/3
ip address 192.168.28.8 255.255.255.0
ip ospf message-digest-key 1 md5 cisco
half-duplex
!
router ospf 10
router-id 8.8.8.8
log-adjacency-changes
area 0 authentication message-digest
area 18 virtual-link 1.1.1.1 authentication
area 18 virtual-link 1.1.1.1 message-digest-key 1 md5 cisco
area 28 virtual-link 2.2.2.2 authentication
area 28 virtual-link 2.2.2.2 message-digest-key 1 md5 cisco
network 8.8.8.8 0.0.0.0 area 18
network 192.168.18.0 0.0.0.255 area 18
network 192.168.28.0 0.0.0.255 area 28
network 192.168.68.0 0.0.0.255 area 68

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
C192.168.12.0/24 is directly connected, Ethernet0/0
1.0.0.0/32 is subnetted, 1 subnets
C1.1.1.1 is directly connected, Loopback0
O IA 192.168.28.0/24 [110/20] via 192.168.18.8, 00:00:57, Ethernet0/1
[110/20] via 192.168.12.2, 00:00:57, Ethernet0/0
4.0.0.0/32 is subnetted, 1 subnets
O4.4.4.4 [110/65] via 192.168.145.4, 00:00:57, Serial1/0
C192.168.145.0/24 is directly connected, Serial1/0
20.0.0.0/8 is variably subnetted, 4 subnets, 2 masks
C20.1.1.0/24 is directly connected, Loopback1
O20.1.0.0/22 is a summary, 00:00:57, Null0
C20.1.3.0/24 is directly connected, Loopback3
C20.1.2.0/24 is directly connected, Loopback2
5.0.0.0/32 is subnetted, 1 subnets
O5.5.5.5 [110/65] via 192.168.145.5, 00:00:58, Serial1/0
O N2 192.168.57.0/24 [110/100] via 192.168.145.5, 00:00:58, Serial1/0
6.0.0.0/32 is subnetted, 1 subnets
O IA6.6.6.6 [110/21] via 192.168.18.8, 00:00:58, Ethernet0/1
172.16.0.0/24 is subnetted, 1 subnets
O E2172.16.2.0 [110/120] via 192.168.12.2, 00:00:58, Ethernet0/0
8.0.0.0/32 is subnetted, 1 subnets
O8.8.8.8 [110/11] via 192.168.18.8, 00:00:58, Ethernet0/1
10.0.0.0/24 is subnetted, 3 subnets
O N210.1.3.0 [110/100] via 192.168.145.5, 00:00:58, Serial1/0
O N210.1.2.0 [110/100] via 192.168.145.5, 00:00:58, Serial1/0
O N210.1.1.0 [110/100] via 192.168.145.5, 00:00:58, Serial1/0
O IA 192.168.23.0/24 [110/20] via 192.168.12.2, 00:00:58, Ethernet0/0
O IA 192.168.68.0/24 [110/20] via 192.168.18.8, 00:00:58, Ethernet0/1
C192.168.18.0/24 is directly connected, Ethernet0/1
R5#show ip rou
R5#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 192.168.145.1 to network 0.0.0.0
1.0.0.0/32 is subnetted, 1 subnets
O1.1.1.1 [110/65] via 192.168.145.1, 00:58:58, Serial1/2
4.0.0.0/32 is subnetted, 1 subnets
O4.4.4.4 [110/65] via 192.168.145.4, 00:58:58, Serial1/2
C192.168.145.0/24 is directly connected, Serial1/2
5.0.0.0/32 is subnetted, 1 subnets
C5.5.5.5 is directly connected, Loopback0
C192.168.57.0/24 is directly connected, Ethernet0/0
10.0.0.0/24 is subnetted, 3 subnets
R10.1.3.0 [120/1] via 192.168.57.7, 00:00:04, Ethernet0/0
R10.1.2.0 [120/1] via 192.168.57.7, 00:00:04, Ethernet0/0
R10.1.1.0 [120/1] via 192.168.57.7, 00:00:04, Ethernet0/0
O*IA 0.0.0.0/0 [110/65] via 192.168.145.1, 00:36:37, Serial1/2
R6#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
O IA 192.168.12.0/24 [110/30] via 192.168.68.8, 00:33:29, Ethernet0/0
1.0.0.0/32 is subnetted, 1 subnets
O IA1.1.1.1 [110/21] via 192.168.68.8, 00:41:41, Ethernet0/0
O IA 192.168.28.0/24 [110/20] via 192.168.68.8, 00:42:47, Ethernet0/0
4.0.0.0/32 is subnetted, 1 subnets
O IA4.4.4.4 [110/85] via 192.168.68.8, 00:41:41, Ethernet0/0
O IA 192.168.145.0/24 [110/84] via 192.168.68.8, 00:41:41, Ethernet0/0
20.0.0.0/32 is subnetted, 3 subnets
O IA20.1.1.1 [110/21] via 192.168.68.8, 00:41:41, Ethernet0/0
O IA20.1.2.1 [110/21] via 192.168.68.8, 00:41:41, Ethernet0/0
O IA20.1.3.1 [110/21] via 192.168.68.8, 00:41:41, Ethernet0/0
5.0.0.0/32 is subnetted, 1 subnets
O IA5.5.5.5 [110/85] via 192.168.68.8, 00:41:41, Ethernet0/0
O E2 192.168.57.0/24 [110/100] via 192.168.68.8, 00:29:15, Ethernet0/0
6.0.0.0/32 is subnetted, 1 subnets
C6.6.6.6 is directly connected, Loopback0
172.16.0.0/24 is subnetted, 1 subnets
O E2172.16.2.0 [110/120] via 192.168.68.8, 00:29:15, Ethernet0/0
8.0.0.0/32 is subnetted, 1 subnets
O IA8.8.8.8 [110/11] via 192.168.68.8, 00:42:48, Ethernet0/0
10.0.0.0/24 is subnetted, 3 subnets
O E210.1.3.0 [110/100] via 192.168.68.8, 00:29:15, Ethernet0/0
O E210.1.2.0 [110/100] via 192.168.68.8, 00:29:15, Ethernet0/0
O E210.1.1.0 [110/100] via 192.168.68.8, 00:29:15, Ethernet0/0
O IA 192.168.23.0/24 [110/30] via 192.168.68.8, 00:29:20, Ethernet0/0
C192.168.68.0/24 is directly connected, Ethernet0/0
O IA 192.168.18.0/24 [110/20] via 192.168.68.8, 00:42:48, Ethernet0/0
有一点关于nssa区域说下
area 145 nssa no-redistribution default-information-originate no-summary
抑制57起源条默认路由3 4




【OSPF|OSPF 综合实验】本文转自q狼的诱惑 51CTO博客,原文链接:http://blog.51cto.com/liangrui/564147,如需转载请自行联系原作者

    推荐阅读