以太交换机原理讲解_第1页
以太交换机原理讲解_第2页
以太交换机原理讲解_第3页
以太交换机原理讲解_第4页
以太交换机原理讲解_第5页
已阅读5页,还剩31页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

C

培不需要stp了,改为以太网工作原理以太网交换机原理中心机房数据专业李世发课程目标通过本章的学习,你可以有以下收获:掌握交换机的工作原理和过程了解环路的危害了解交换机避免环路的方式目录交换机的工作原理环路带来的问题解决环路问题的方法交换机的工作原理Station

ASegment

A1/1Segment

B

1/2Station

BSlide1of1Purpose:Emphasize:Thenextfewslidesdiscussthebasicfunctionofabridge/switch.1.Howitlearnsthelocationofthehostsbyreadingthesourcemacaddressofincomingframes.2.Howitmakesforwarding/filteringdecisions.Threeconditionswhenaswitchwillfloodaframeoutonallportsexcepttotheportwheretheframecameinon:UnknownunicastaddressBroadcastframeMulticastframe3.HowSTPisusedtoavoidloopsinaswitched/bridgednetwork.交换机的三个功能地址学习转发/过滤避免环路Slide1of1Purpose:Emphasize:The1900enmaxmacaddresstablesizeis1024.Oncethetableisfull,itwillfloodallnewaddressesuntilexistingentriesageout.Thecommandtochangethemacaddresstableagingtimeis:wg_sw_a(config)#mac-address-tableaging-time?<10-1000000>AgingtimevalueThedefaultis300sec.TheMACaddresstableisalsoreferredtoastheCAMtable(ContentAddressMemory)onsomeswitches.地址学习最开始的地址表是空的MAC地址表A:00d0.d001.1111C:00d0.d001.2222B:00d0.d001.3333D:00d0.d001.4444E0E1E2E3Slide

1

of

1Purpose:Emphasize:Station

A发送一个帧(frame)给StationC交换机从端口E0学习到station

A的MAC地址将该帧做“洪泛(flooding)”转发。C:00d0.d001.2222B:00d0.d001.3333D:00d0.d001.4444MAC地址表E0:

00d0.d001.1111E0E1E2E3地址学习A:00d0.d001.1111Slide

1

of

1Purpose:Emphasize:

Once

C

replies,

the

switch

will

also

cache

station

C’s

MAC

address

to

port

E2

as

shown

in

the

next

slide.A:00d0.d001.1111B:00d0.d001.3333MAC地址表E0:

00d0.d001.1111E2:

00d0.d001.2222E0E1E2E3地址学习C:00d0.d001.2222 D:00d0.d001.4444StationC回应一个帧(frame)给StationA交换机从端口E2学习到stationC的MAC地址Slide

1

of

1Purpose:Emphasize:过滤StationA发送一个帧(frame)给stationC目标地址已经知道,不再“洪泛”发送,直接从E2端口发送出去。A:00d0.d001.1111C:00d0.d001.2222B:00d0.d001.3333D:00d0.d001.4444E0E1E2XXE3MAC地址表E0:

00d0.d001.1111E2:

00d0.d001.2222E1:

00d0.d001.3333E3:

00d0.d001.4444Slide

1

of

1Purpose:Emphasize:A:00d0.d001.1111C:00d0.d001.2222B:00d0.d001.3333D:00d0.d001.4444MAC

address

table

E0:

00d0.d001.1111E2:

00d0.d001.2222E1:

00d0.d001.3333E3:

00d0.d001.4444E0

E1E2

E3广播和多播帧Station

D发送一个广播或多播帧(frame)给C

交换机将广播(broadcast)或多播(multicast)帧“泛洪”转发给其他所有端口(不包括进来的那个端口)。课程大纲交换机的工作原理环路带来的问题解决环路问题的方法Purpose:Thisisanintroductorygraphictotellstudentsthatredundantconnectionsintheswitchblockareverynecessaryinordertoprovidearedundant,fault-tolerantnetwork.WewillbediscussingthechallengesofredundantconnectionsinaLayer2networkandthesolutionstothosechallenges.Emphasize:Theinstructorshouldtakethestudentsthroughsomeofthepossiblescenariosthatareonthegraphic.Emphasizethepossibilitiesfordisasterifthephysicalredundancywasnotalreadyinplaceandhowthatisonlyapartialsolution.Bridgingandswitchingaretermsthatareusedinterchangeablyinthischapter.Forthepurposesofspanningtreetheyareconsideredtobethesamething.Transition:Wearegoingtostartwithanoverviewoftransparentbridgingandlookatwhathappenswhenaredundantlinkcausesaloop.AccessLayerDistributionLayerSW

1Link

ALink

BSW

2保证网络的可靠性Slide

1

of

1Purpose:Emphasize:

Layer

2

has

no

mechanism(like

a

TTL)

to

stop

loops.Segment

1Server/host

XRouter

YSegment2在冗余拓扑中,出现了环路(loop)冗余拓扑Slide

1

of

1Purpose:Emphasize:

Layer

2

has

no

mechanism(like

a

TTL)

to

stop

loops.冗余拓扑Segment

1Segment2环路(loop)带来的问题:·广播风暴·帧的重复复制·交换机MAC地址表的不稳定Server/host

XRouter

YSlide

1

of

3Purpose:Emphasize:

Broadcast

frames

are

flooded.Segment

1Server/host

XRouter

YBroadcastSwitch

ASwitch

BSegment

2Host

X发送一个广播帧广播风暴Slide

2

of

3Purpose:Emphasize:Segment

1Server/host

XRouter

YBroadcastSwitch

ASwitch

BSegment

2Host

X发送一个广播帧广播风暴Slide

3

of

3Purpose:Emphasize:

Layer

2

has

no

TTL

mechanismto

stop

loopingframes.Segment

1Server/host

XRouter

YBroadcastSegment

2交换机不断的转发该广播帧Switch

ASwitch

B广播风暴Slide

1

of

2Purpose:Emphasize:

This

slide

assumes

Router

Y

Mac

address

has

not

been

learned

by

Switch

Aand

Switch

B

yet

so

the

unknown

unicast

frame

toRouter

Y

will

be

flooded.Segment

1Segment

2Server/host

XRouter

YUnicastSwitch

ASwitch

B复制出多个重复的帧Host

X发送一个单播帧到Router

Y

任何一台交换机都没有学到过Router

Y的MAC地址Slide

2

of

2Purpose:Emphasize:Segment

1Server/host

XRouter

YUnicastSwitch

ASwitch

BUnicastUnicast复制出多个重复的帧Segment

2Host

X发送一个单播帧到Router

Y任何一台交换机都没有学到过Router

Y的MAC地址Router

Y将收到两个完全一样的重复帧Slide

1

of

2Purpose:Emphasize:

This

slide

assumes

Router

Y

Mac

address

has

not

been

learned

by

Switch

Aand

Switch

B

yet

so

the

unknown

unicast

frame

toRouter

Y

will

be

flooded.Server/host

XRouter

YUnicastSegment

1UnicastSwitch

APort

0Port

1Port

0Switch

B

Port

1MAC地址表的不稳定Segment

2Host

X发送一个单播帧到Router

Y任何一台交换机都没有学到过Router

X的MAC地址Switch

A和B从各自的port

0学到Router

X的MAC地址Slide

2

of

2Purpose:Emphasize:Segment

1Segment

2Server/host

XRouter

YUnicastUnicastSwitch

APort

0Port

1Port

0Switch

BPort

1MAC地址表的不稳定任何一台交换机都没有学到过Router

Y的MAC地址该帧被洪泛(flooding)转发Switch

A和B错误的从port

1学到Router

X的MAC地址Slide

1

of

1Purpose:Emphasize:环路问题面对这么多的环路,怎么办?WorkstationsLoopLoopServer/hostLoopBroadcast课程大纲交换机的工作原理环路带来的问题解决环路问题的方法环路解决办法1:网络结构采用星型结构组建交换网络,从根本上防范物理环路的产生BRAS园区交换机:T40G/3228/3252/3206/3928/3952/3906等汇聚交换机:T160G/T64G/T40GGEGEFE/GEIP城域网以太汇聚层用户接入层驻地网DSLAM:8220/9210等FE/GESRPESlide1of1Purpose:Emphasize:Aloopedtopologyisoftendesiredtoprovideredundancy,butloopedtrafficisundesirable.TheSpanningTreeprotocolwasoriginallydesignedforbridges.Today,itisalsoappliedtoLANswitchesandroutersoperatingasabridge.STPensuresallbridgedsegmentsarereachablebutanypointswhereloopsoccurwillbeblocked.生成树协议能够发现并自动消除冗余网络拓扑中的环路。Blockx环路解决办法2:生成树协议

(Spanning-Tree

Protocol)加加4条条Slide1of1Purpose:Emphasize:ThethreegeneralruleswhendealingwithSTP:1.Onerootbridgepernetwork.TherootisthebridgewiththelowestBridgeID.Alltheportsontherootbridgearedesignatedports(forwarding).2.Foreverynonrootbridge,thereisarootport(forwarding).Therootportistheportwiththelowestaccumulatedpathcosttotherootbridge.3.Foreverysegment,thereisonlyonedesignatedport.Thedesignatedportforwardstrafficforthesegment.Thedesignatedporthasthelowestaccumulatedpathcosttotherootbridge.xDesignated

port

(F)Root

port

(F)Designated

port

(F)Nondesignated

port

(B)Root

bridgeNonroot

bridge100baseTSpanning-Tree的运作10baseT1.选出一个根桥Root(rootbridge)2.在一个链路上选出指定端口DP(designatedport)3.在非根网桥上选出根端口RP(rootport) 4.未成为指定端口或根端口的端口被阻塞,即阻隔端口,Blocked(blockedport)。ABZXR10配置STPzte#

configure

terzte(config)#

spanning-tree

enablezte(config)#

spanning-tree

mode

sstp在全局配置模式下启动生成树协议STP配置生成树协议的当前模式为sstpSTP的配置实例ABC1211212Switch

AZXR10-A#

configure

tZXR10-A(config)#

spanning-tree

enableZXR10-A(config)#

spanning-tree

mode

sstpSwitch

BZXR10-B#

configure

tZXR10-B(config)#

spanning-tree

enableZXR10-B(config)#

spanning-tree

mode

sstpSwitch

CZXR10-C#

configure

tZXR10-C(config)#

spanning-tree

enableZXR10-C(config)#

spanning-tree

mode

sstpSTP的配置实例ZXR10-A(config)#show

spanning-tree

instance

0Spanning

tree

enabled

protocolMSTPRoot

ID:

Priority 32768;

Address

00d0.d0c2.0101Hello-Time 2sec;

Max-Age

20

secForward-Delay

15

sec;RegRootID:

PriorityBridgeID:

Priority32768;

Address

00d0.d0c2.010132768;

Address

00d0.d0c2.0101Hello-Time 2sec;

Max-Age

20

secForward-Delay

15

sec;

Max-Hops

20Message-Age

1

sec;

RemainHops

20Interface

Prio.NbrName

Port

ID

Cost

Sts

Role

LinkType

Boundfei_1/1

128.41fei_1/2

128.42200000

ForwardDesignated

p2p200000

Forward

Designated

p2pSSTPSSTPABC1211212ZXR10-B(config)#show

spanning-tree

instance

0Name PortID

Cost

Sts

Role

LinkType

Boundfei_1/1fei_1/2200000

Forward

Root

p2p200000

Forward

Designated

p2pSSTPSSTPZXR10-B(config)#show

spanning-tree

instance

0Name PortID

Cost

Sts

Role

LinkType

Boundfei_1/1128.41200000Forward

Rootp2p

SSTPfei_1/2128.42200000Discard

Alternatep2p

SSTPSTP的问题收敛速度慢 RSTP大型网络中的分组问题 MSTP需要大量的计算,严重耗费内存、CPU资源环路解决办法3:单端口环路检测作用: 此功能能检测到交换机下接的用户或者交换机上的环回,从而对此端口进行处理,避免因下面用户或者设备的环回导致交换机广播风暴等异常,将影响限制到某个端口。单端口环路检测的工作原理 交换机从某个端口发送一个检测报文,如果这个检测报文原封不动(或者仅打了一个tag头)地从这个端口接收回来,说明这个端口存在环路,交换机将自动关闭该端口。单端口环路检测的配置实例switchAswitchBFei_1/1ZXR10(config)#interface

fei_1/1ZXR10(config-if)#switchport

mode

trunkZXR10(config-if)#switchport

trunk

vlan

1-2ZXR10(config-if)#exitZXR10(config)#loop-detect

interface

f

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论