日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

ospf hello时间和dead_使用OSPF协议使SPOKE端正常通信

發布時間:2025/3/20 编程问答 16 豆豆
生活随笔 收集整理的這篇文章主要介紹了 ospf hello时间和dead_使用OSPF协议使SPOKE端正常通信 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

1:用自己的語言描述OSPF接口的類型及LSA新舊的比較

2:LAB:NBMA環境,使用OSPF協議使SPOKE端可以正常通信,不能修改接口的OSPF網絡類型

作業一:用自己的語言描述OSPF接口的類型及LSA新舊的比較。

OSPF接口的類型有:broadcast,NBMA,point-to-point,point-to-muitipoint四種類型

可以通過:ip ospf network xx 命令修改類型參數。

Broadcast:hello-time為10s,dead時間為40s wait時間為40s, 組播發送

NBMA:hello-time為30s,dead時間為120s wait時間為120s, 單播發送

point-to-point:hello-time為10s,dead時間為40s wait時間為40s,組播發送

point-to-muitipoint:hello-time為30s,dead時間為120s wait時間為120s,組播發送。

LSA:默認為1800s更新一次,序列號增加1(默認序列號從0x80000001開始到0x7FFFFFFFF),如果在3600s內沒有收到更新信息,就老化LSA。

1:先比較LSA的序列號,值越大則越優先。

2:序列號一致時,則會比較checksum值,如果這個值越大則優先。

3:當序列號和checksum值都相同,則比較AGE時間是不是會等于3600s,如果相等,則表示為最新的。

4:如果AGE時間不等于3600s,會計算兩者之間的差,如果差值大于15分鐘,則越小月優先,如果小于15分鐘,則視為同一條路由。

LAB:NBMA環境,使用OSPF協議使SPOKE端可以正常通信,不能修改接口的OSPF網絡類型

使用拓撲圖:

以下是R1,R2,R3設備的配置信息:

R1的配置信息:

R1(config-if)#do show run int s1/0 //驗證接口s1/0的配置信息

Building configuration...

Current configuration : 202 bytes

!

interface Serial1/0

ip address 123.1.1.1 255.255.255.0 //接口s1/0的IP地址信息

encapsulation frame-relay //接口s1/0封裝FR

serial restart-delay 0

frame-relay map ip 123.1.1.3 103 broadcast //FR map 配置

frame-relay map ip 123.1.1.2 102 broadcast //FR map 配置

end

R1(config-if)#do show fram map 驗證FR map

Serial1/0 (up): ip 123.1.1.2 dlci 102(0x66,0x1860), static,

broadcast,

CISCO, status defined, active

Serial1/0 (up): ip 123.1.1.3 dlci 103(0x67,0x1870), static,

broadcast,

CISCO, status defined, active

R1(config-if)#do ping 123.1.1.2 //測試123.1.1.2的地址

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 123.1.1.2, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 4/8/12 ms

===============================================================================

R2的配置信息:

R2(config-if)#do show run int s1/0 //驗證接口s1/0的配置信息

Building configuration...

Current configuration : 158 bytes

!

interface Serial1/0

ip address 123.1.1.2 255.255.255.0 //接口s1/0的IP地址信息

encapsulation frame-relay //接口s1/0封裝FR

serial restart-delay 0

frame-relay map ip 123.1.1.1 201 broadcast //FR map 配置

end

R2(config-if)#do show fram map

Serial1/0 (up): ip 123.1.1.3 dlci 201(0xC9,0x3090), static,

broadcast,

CISCO, status defined, active //在沒有這一條的時候R2測試不通R3

Serial1/0 (up): ip 123.1.1.1 dlci 201(0xC9,0x3090), static,

broadcast,

CISCO, status defined, active

R2(config-if)#do ping 123.1.1.1 //測試123.1.1.1的地址

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 123.1.1.1, timeout is 2 seconds:

..!!!

Success rate is 60 percent (3/5), round-trip min/avg/max = 16/29/48 ms

===============================================================================

R3的配置信息:

R3(config-if)#do show run int s1/0 //驗證接口s1/0的配置信息

Building configuration...

Current configuration : 158 bytes

!

interface Serial1/0

ip address 123.1.1.3 255.255.255.0 //接口s1/0的IP地址信息

encapsulation frame-relay //接口s1/0封裝FR

serial restart-delay 0

frame-relay map ip 123.1.1.1 301 broadcast //FR map 配置

end

R3(config-if)#do show fram map

Serial1/0 (up): ip 123.1.1.2 dlci 301(0x12D,0x48D0), static,

broadcast,

CISCO, status defined, active //在沒有這一條的時候R3測試不通R2

Serial1/0 (up): ip 123.1.1.1 dlci 301(0x12D,0x48D0), static,

broadcast,

CISCO, status defined, active

R3(config-if)#do ping 123.1.1.1

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 123.1.1.1, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 12/24/40 ms

R3(config-if)#do ping 123.1.1.2

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 123.1.1.2, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 20/34/44 ms

R3可以ping通R1但是無法ping通R2因為沒有到達R2和dlci號的對應關系不能進行通信。

===============================================================================

為R1,R2,R3運行ospf并手工指定鄰居:

R1的OSPF配置信息:

R1(config-router)#do show run | se ospf

ip ospf 110 area 0 //開啟運行ospf動態路由協議區域0

router ospf 110 //運行ospf

log-adjacency-changes

network 1.1.1.0 0.0.0.255 area 0 //宣告網段

neighbor 123.1.1.2 //手工指定鄰居

neighbor 123.1.1.3 //手工指定鄰居

R1(config-router)#do show ip ospf int b

Interface PID Area IP Address/Mask Cost State Nbrs F/C

Lo0 110 0 1.1.1.1/24 1 LOOP 0/0

Se1/0 110 0 123.1.1.1/24 64 DR 2/2

R1(config-router)#do 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

2.0.0.0/32 is subnetted, 1 subnets

O 2.2.2.2 [110/65] via 123.1.1.2, 00:17:04, Serial1/0

3.0.0.0/32 is subnetted, 1 subnets

O 3.3.3.3 [110/65] via 123.1.1.3, 00:19:18, Serial1/0

123.0.0.0/24 is subnetted, 1 subnets

C 123.1.1.0 is directly connected, Serial1/0

R2的OSPF配置信息:

R2(config-router)#do show run | se ospf

ip ospf priority 0 //ospf 優先級改為0

ip ospf 110 area 0 //開啟運行ospf動態路由協議區域0

router ospf 110 //運行ospf

log-adjacency-changes

network 2.2.2.0 0.0.0.255 area 0 //宣告網段

R2(config-router)#do show ip ospf int b

Interface PID Area IP Address/Mask Cost State Nbrs F/C

Lo0 110 0 2.2.2.2/24 1 LOOP 0/0

Se1/0 110 0 123.1.1.2/24 64 DROTH 1/1

R2(config-if)#do 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/32 is subnetted, 1 subnets

O 1.1.1.1 [110/65] via 123.1.1.1, 00:16:35, Serial1/0

2.0.0.0/24 is subnetted, 1 subnets

C 2.2.2.0 is directly connected, Loopback0

3.0.0.0/32 is subnetted, 1 subnets

O 3.3.3.3 [110/65] via 123.1.1.3, 00:16:35, Serial1/0

123.0.0.0/24 is subnetted, 1 subnets

C 123.1.1.0 is directly connected, Serial1/0

R3的OSPF配置信息:

R3#show run | se ospf

ip ospf priority 0 //ospf 優先級改為0

ip ospf 110 area 0 //開啟運行ospf動態路由協議區域0

router ospf 110 //運行ospf

log-adjacency-changes

network 3.3.3.0 0.0.0.255 area 0 //宣告網段

R3#show ip ospf int b

Interface PID Area IP Address/Mask Cost State Nbrs F/C

Lo0 110 0 3.3.3.3/24 1 LOOP 0/0

Se1/0 110 0 123.1.1.3/24 64 DROTH 1/1

R3(config-if)#do 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/32 is subnetted, 1 subnets

O 1.1.1.1 [110/65] via 123.1.1.1, 00:28:38, Serial1/0

2.0.0.0/32 is subnetted, 1 subnets

O 2.2.2.2 [110/65] via 123.1.1.2, 00:15:58, Serial1/0

3.0.0.0/24 is subnetted, 1 subnets

C 3.3.3.0 is directly connected, Loopback0

123.0.0.0/24 is subnetted, 1 subnets

C 123.1.1.0 is directly connected, Serial1/0

測試結果:R3測試R1和R2

R3(config-if)#do ping 1.1.1.1

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 1.1.1.1, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 8/18/24 ms

R3(config-if)#do ping 2.2.2.2

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 2.2.2.2, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 20/28/40 ms

總結

以上是生活随笔為你收集整理的ospf hello时间和dead_使用OSPF协议使SPOKE端正常通信的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。