14-高级路由:OSPF 5 种LSA
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了14-高级路由:OSPF 5 种LSA相关的知识,希望对你有一定的参考价值。
一、实验拓扑:
二、命令部署:
1、1类、2类LSA命令
R1#show ip ospf int f0/0 看接口类型
R1#show ip ospf database 查看路由器所学习到的完成的网络拓扑
R1#show ip ospf database router 查看ospf数据库路由器
R1(config)#int lo1
R1(config-if)#ip ospf network point-to-point 修改为点对点类型,这样Lo1发送到对面是24位的。
2、3类LSA查看命令:
R3#show ip ospf database
R3#show ip route 可以看到3类LSA标记:O IA
R3#show ip ospf database summary 查看3类LSA每一条的详细信息
3、5类LSA:
R3(config)#router ospf 110
R3(config-router)#redistribute eigrp 90 subnets 重分发
R2#show ip ospf database external 可以看到OSPF区域内5类LSA通告者都是R3
4、4类LSA
R4#show ip ospf border-routers 查看边界路由器
5、修改OE 2为OE 1
R3(config)#router ospf 110
R3(config-router)#redistribute eigrp 90 subnets metric-type 1 必须要在ASBR:R3路由器上做
R3(config-router)#redistribute eigrp 90 subnets metric-type 1 metric 1 同时修改默认COST值为1
三、验证:
1、1类、2类LSA
R1#show ip ospf database
OSPF Router with ID (1.1.1.1) (Process ID 110)
Router Link States (Area 0)
Link ID ADV Router Age Seq# Checksum Link count
1.1.1.1 1.1.1.1 428 0x80000003 0x00C332 2
2.2.2.2 2.2.2.2 428 0x80000003 0x00AA3E 2
Net Link States (Area 0)
Link ID ADV Router Age Seq# Checksum
12.1.1.1 1.1.1.1 428 0x80000001 0x004AD0
2、3类LSA
R3#show ip ospf database
Summary Net Link States (Area 1)
Link ID ADV Router Age Seq# Checksum
1.1.1.0 1.1.1.1 215 0x80000001 0x0051E3
2.2.2.2 1.1.1.1 215 0x80000001 0x00230C
4.4.4.4 1.1.1.1 32 0x80000001 0x00D055
12.1.1.0 1.1.1.1 215 0x80000001 0x00C168
24.1.1.0 1.1.1.1 32 0x80000003 0x002BEF
3、5类LSA
R3#show ip ospf database
Type-5 AS External Link States
Link ID ADV Router Age Seq# Checksum Tag
5.0.0.0 3.3.3.3 55 0x80000001 0x004C43 0
35.1.1.0 3.3.3.3 57 0x80000001 0x00ADC1 0
R4#show ip route
O E2 5.0.0.0/8 [110/20] via 24.1.1.2, 00:03:15, FastEthernet0/0
24.0.0.0/24 is subnetted, 1 subnets
C 24.1.1.0 is directly connected, FastEthernet0/0
R4#show ip ospf database external
OSPF Router with ID (4.4.4.4) (Process ID 110)
Type-5 AS External Link States
Routing Bit Set on this LSA
LS age: 546
Options: (No TOS-capability, DC)
LS Type: AS External Link
Link State ID: 5.0.0.0 (External Network Number )
Advertising Router: 3.3.3.3
LS Seq Number: 80000001
Checksum: 0x4C43
Length: 36
Network Mask: /8
Metric Type: 2 (Larger than any link state path)
TOS: 0
Metric: 20
Forward Address: 0.0.0.0
External Route Tag: 0
4、4类LSA
R4#show ip ospf border-routers
OSPF Process 110 internal Routing Table
Codes: i - Intra-area route, I - Inter-area route
i 2.2.2.2 [1] via 24.1.1.2, FastEthernet0/0, ABR, Area 2, SPF 4
I 3.3.3.3 [3] via 24.1.1.2, FastEthernet0/0, ASBR, Area 2, SPF 4
R4#show ip ospf database
Summary ASB Link States (Area 2)
Link ID ADV Router Age Seq# Checksum
3.3.3.3 2.2.2.2 948 0x80000001 0x00C85D
5、修改OE 2为OE 1
R1#show ip route
O E1 35.1.1.0 [110/21] via 13.1.1.3, 00:01:28, FastEthernet1/0
2.0.0.0/32 is subnetted, 1 subnets
O E1 5.0.0.0/8 [110/21] via 13.1.1.3, 00:01:30, FastEthernet1/0
R1#show ip route
O E1 35.1.1.0 [110/2] via 13.1.1.3, 00:00:36, FastEthernet1/0
2.0.0.0/32 is subnetted, 1 subnets
O E1 5.0.0.0/8 [110/2] via 13.1.1.3, 00:00:38, FastEthernet1/0
24.0.0.0/24 is subnetted, 1 subnets
以上是关于14-高级路由:OSPF 5 种LSA的主要内容,如果未能解决你的问题,请参考以下文章