?
快捷搜索:  as  test  1111  test aNd 8=8  test++aNd+8=8  as++aNd+8=8  as aNd 8=8

金庫娛樂app官網:探討OSPF次優路由選擇

?

拓撲為工大年夜瑞普ccnp實驗lab17,描述如下:

R1(S1/1)--R2(S1/0),cost=10;R1(S1/2)-framerelay-R4(S1/2),cost=2

R2(S1/1)--R3(S1/0),cost=2,R2(F0/0)--R4(F0/0),cost=2

R3(S1/1)--R4(S1/0),cost=5

R1的F0/0口銜吸收集192.168.1.0/24,cost=1

R1#show run

interface FastEthernet0/0

ip address 192.168.1.1 255.255.255.0

!

interface Serial1/1

description DCE,OSPF area 0,connected to R2's S1/0,ip 172.16.255.2/30

ip address 172.16.255.1 255.255.255.252

ip ospf cost 10

clock rate 9600

!

interface Serial1/2

description FrameRelay,OSPF area 0,connected to R4's S1/2,ip 172.16.255.14/30

ip address 172.16.255.13 255.255.255.252

encapsulation frame-relay

ip ospf network broadcast

ip ospf cost 2

!

router ospf 100

router-id 1.1.1.1

network 172.16.255.0 0.0.0.3 area 0

network 172.16.255.12 0.0.0.3 area 0

network 192.168.1.0金庫娛樂app官網 0.0.0.255 area 2

!

////////////////////

R2#show run

interface FastEthernet0/0

description OSPF area 1,connected to Network 172.16.255.16/30

ip address 172.16.255.17 255.255.255.252

ip ospf cost 2

!

interface Serial1/0

description DTE,OSPF area 0,connected to R1's S1/1,ip 172.16.255.1/30

ip address 172.16.255.2 255.255.255.252

ip ospf cost 10

!

interface Serial1/1

description DCE,OSPF area 1,connected to R3's S1/0,ip 172.16.255.6/30

ip address 17金庫娛樂app官網2.16.255.5 255.255.255.252

ip ospf cost 2

clock rate 9600

!

router ospf 100

router-id 2.2.2.2

network 172.16.255.0 0.0.0.3 area 0

network 172.16.255.4 0.0.0.3 area 1

network 172.16.255.16 0.0.0.3 area 1

!

////////////////////

R3#show run

interface Serial1/0

description DTE,OSPF area 1,connected to R2's S1/1,ip 172.16.255.5/30

ip address 172.16.255.6 255.255.255.252

ip ospf cost 2

!

interface Serial1/1

description DCE,OSPF area 1,connected to R4's S1/0,ip 172.16.255.10/30

ip address 172.16.255.9 255.255.255.252

ip ospf cost 5

clock rate 9600

!

router ospf 100

router-id 3.3.3.3

network 172.16.255.4 0.0.0.3 area 1金庫娛樂app官網

network 172.16.255.8 0.0.0.3 area 1

!

////////////////////

R4#show run

interface FastEthernet0/0

description OSPF area 1,connected to Network 172.16.255.16/30

ip address 172.16.255.18 255.255.255.252

ip ospf cost 2

!

interface Serial1/0

description DTE,OSPF area 1,connected to R3's S1/1,ip 172.16.255.9/30

ip address 172.16.255.10 255.255.255.252

ip ospf cost 5

!

interface Serial1/2

d金庫娛樂app官網escription FrameRelay,OSPF area 0,connected to R1's S1/2,ip 172.16.255.13/30

ip address 172.16.255.14 255.255.255.252

encapsulation frame-relay

ip ospf network broadcast

ip ospf cost 2

!

router ospf 100

router-id 4.4.4.4

network 172.16.255.8 0.0.0.3 area 1

network 172.16.255.12 0.0.0.3 area 0

network 172.16.255.16 0.0.0.3 area 1

!

R3#traceroute 192.168.1.1

1 172.16.255.5 24 msec 68 msec 12 msec

2 172.16.255.1 20 msec *20 msec

R3#show ip route

172.16.0.0/30 is subnetted, 5 subnets

O IA172.16.255.0 [110/12] via 172.16.255.5, 00:00:07, Serial1/0

C172.16.255.4 is directly connected, Serial1/0

C172.16.255.8 is directly connected, Serial1/1

O IA172.16.255.12 [110/6] via 172.16.255.5, 00:00:07, Serial1/0

O172.16.255.16 [110/4] via 172.16.255.5, 00:00:07, Serial1/0

O IA 192.168.1.0/24 [110/7] via 172.16.255.5, 00:00:07, Serial1/0

從R3到達192.168.1.0/24,起碼的cost為R3-R2-R4-R1=7,可實際路由為R3-R2-R1=13。為何呈現這樣的環境?

首先查看R3的ospf database:

R3#show ip ospf data

Router Link States (Area 1)

Link IDADV RouterAgeSeq#Checksum Link count

2.2.2.22.2.2.26730x80000005 0x003C97 3

3.3.3.33.3.3.36150x80000003 0x005569 4

4.4.4.44.4.4.46280x80000005 0x00951E 3

Net Link States (Area 1)

Link IDADV RouterAgeSeq#Checksum

172.16.255.172.2.2.26730x80000002 0x002C22

Summary Net Link States (Area 1)

Link IDADV RouterAgeSeq#Checksum

172.16.255.02.2.2.26730x80000002 0x001858

172.16.255.04.4.4.46280x80000002 0x00EF76

172.16.255.122.2.2.26730x80000004 0x00AFB0

172.16.255.124.4.4.46280x80000004 0x000F53

192.168.1.02.2.2.26730x80000002 0x00FCC1

192.168.1.04.4.4.46280x80000002 0x00704E

可以肯定,R4和R2同時向R3告示了192.168.1.0/24的路由

R3#show ip ospf database summary

Routing Bit Set on this LSA

LS age: 886

Options: (No TOS-capability, DC, Upward)

LS Type: Summary Links(Network)

Link State ID: 192.168.1.0 (summary Network Number)

Advertising Router: 2.2.2.2

LS Seq Number: 80000002

Checksum: 0xFCC1

Length: 28

Network Mask: /24

TOS: 0Metr金庫娛樂app官網ic: 11

Routing Bit Set on this LSA

LS age: 843

Options: (No TOS-capability, DC, Upward)

LS Type: Summary Links(Network)

Link State ID: 192.168.1.0 (summary Network Number)

Advertising Router: 4.4.4.4

LS Seq Number: 80000002

Checksum: 0x704E

Length: 28

Network Mask: /24

TOS: 0Metric: 3

這里已經呈現了兩個問題。1、以該告示的cost來謀略,R3經由過程R2(2.2.2.2)到達192.168.1.0/24的總cost為13,經由過程R4(4.4.4.4)的cost為8,而R3卻沒有選擇R4作為首選ABR;2、R2告示的192.168.1.0/24的cost為11,而不是我們所估計的5。

R3肯定是懂得全部拓撲的環境,由于從它的路由表中可以看出,到達192.168.1.0/24的起碼cost與理論值不停,為7。是以R3的路由選擇并沒有錯,關鍵是R2。

R2#show ip route

O IA 192.168.1.0/24 [110/11] via 172.16.255.1, 00:07:39, Serial1/0

無論從這里照樣剛才R3接管到的LSA看,R2自身認定192.168.1.0/24的cost為11,并且把該值看護給了R3。然則R3并沒有采取該metric,而是經由過程自身謀略,“得出”了“R2應該從R4轉發到192.168.1.0/24的數據包”這個結論。關鍵問題是,R2并沒有采用該結論。

小我感到其實不應該呈現這種問題。可能有人感覺R2的選路出了問題,但我感覺造成次優路由選擇差錯的不是R2,而是R3。首先,OSPF是一個可劃分區域的路由協議。從大年夜局上看,最優路由因該有兩個前提。一是區域間最優,即轉發數據包從ABR到達另一個ABR,此中骨干內的cost起碼;二是區域內最優,即源到ABR,以及ABR到目的地的cost起碼。區域與區域間的路由選擇是各自自力的,包括骨干區域。現在的環境是,R3干預了區域間及ABR到目的地的區域內兩者的選路。是以它得出了R2會經由過程R4轉發數據包這種差錯的結論。別的,R2已經告示了它到達192.168.1.0/24的cost為11,R4也告示了cost為3,但R3仍然選擇了R2。當然這是LS routing相對付DV routing的一個進步,即路由器能夠懂得全部收集拓撲的布局而做出加倍精確的決策,只是這里的決策已經越俎代庖了。從實驗本身來看,小我感覺最為合理的路由應該是R3-R4-R1,即R3不再懂得整網的拓撲,而只是懂得本區域的拓撲及各ABR告示的cost,根據這些得出的結論,雖然并非最優的結論,然則會加倍合理。

ps:

有同伙要求貼上R2、R4的路由表,若是能夠贊助表達我的意思,也便是舉手之勞而已。下面是完備的路由表

R4#show ip route

172.16.0.0/30 is subnetted, 5 subnets

O172.16.255.0 [110/12] via 172.16.255.13, 00:00:04, Serial1/2

O172.16.255.4 [110/4] via 172.16.255.17, 00:00:54, FastEthernet0/0

C172.16.255.8 is directly connected, Serial1/0

C172.16.255.12 is directly connected, Serial1/2

C172.16.255.16 is directly connected, FastEthernet0/0

O IA 192.168.1.0/24 [110/3] via 172.16.255.13, 00:00:04, Serial1/2

R2#show ip route

172.16.0.0/30 is subnetted, 5 subnets

C172.16.255.0 is directly connected, Serial1/0

C172.16.255.4 is directly connected, Serial1/1

O172.16.255.8 [110/7] via 172.16.255.6, 00:07:09, Serial1/1

[110/7] via 172.16.255.18, 00:07:09, FastEthernet0/0

O172.16.255.12 [110/12] via 172.16.255.1, 00:06:19, Serial1/0

C172.16.255.16 is directly connected, FastEthernet0/0

O IA 192.168.1.0/24 [110/11] via 172.16.255.1, 00:06:19, Serial1/0

免責聲明:以上內容源自網絡,版權歸原作者所有,如有侵犯您的原創版權請告知,我們將盡快刪除相關內容。

您可能還會對下面的文章感興趣:

河北十一选五开奖的 啄木鸟日韩成人片 av女优的 东京热原田樱 即时指数即时指数 真人麻将24小时上下分 江西南昌微乐麻将 海南飞鱼 方舟配资 辽宁十一选五开奖号 幸运飞艇开奖直播 国王vs火箭 中文字幕 东京热 贵州快三 黑龙江彩6十1开奖结果 常见的日本av片商介绍 投资理财平台前10名