国产精品熟女视频一区二区,国产乱人伦真实精品视频,久久乐国产精品亚洲综合,免费国产 ,67194老司机精品午夜_黄色电影中文字幕免费在线_欧美一级看片免费观看视频在线_老妇

生成樹協(xié)議和 BPDU 數(shù)據(jù)包

2014-10-8 11:39| 發(fā)布者: 謝曉新| 查看: 3574| 評論: 0 |來自: csdn

 

STP - Spanning Tree Protocol 生成樹協(xié)議 // IEEE 802.1D

BPDU - Bridge Packet Data Unit

生成樹協(xié)議用于建立一個沒有環(huán)路的拓?fù);靖拍罹褪抢媒粨Q機之間互相交換BPDU數(shù)據(jù)包,使之甄別出冗余鏈接。

基本來講,要經(jīng)過幾個程序:

1. Root Bridge Election - 選擇根橋,以此為前提來分析之后的拓?fù)?// smaller priority <<< smaller MAC address

2. Root Port Election - 非根橋端口選擇根端口 (擁有到達(dá)根橋的最優(yōu)路徑 & 根橋 root path cost = 0)

3. Designated Port Election - 非根橋之間的連接,選擇Designated port // maller root path cost <<< smaller BPDU sender bridge ID // all rest port will be in blocked

STP定義了五種不同的端口狀態(tài):

  • disabled

  • listening

  • learning

  • blocking

  • forwarding

STP (802.1D) Port StateRSTP (802.1w) Port StateIs Port Included in Active Topology?Is Port Learning MAC Addresses?
DisabledDiscardingNoNo
BlockingDiscardingNoNo
ListeningDiscardingYesNo
LearningLearningYesYes
ForwardingForwardingYesYes

要點:

1 - root bridge has no root port, only designated port

2 - once converaged, root bridge generates BPDU, no-root bridge receive BPDU, then update info ( Bridge ID, path cost) then forward out via designated port.

3 - when topology change, non-bridge switch send TCN to root, then root update BPDU data field and send out BPDU to notify other switch topoloy has been changed.

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

在網(wǎng)上看到有人提問還有很清晰的回答,也解釋了我的一些疑問。

Ques:

1- Does only Root bridge generate BPDU packet for whole stp domain or another swtiches in stp domain generate BPDU?

In 802.1d Spanning-Tree, only the Root Bridge was responsible creating/generating fresh BPDUs every Hello-Time (2-seconds by default). The Root Bridge would then transmit those new BPDUs on all of its Designated Ports. A downstream bridge that was directly-connected to the Root Bridge would receive those BPDUs on a port that might be either a Root Port or Blocking Port (if that downstream switch had an alternative path to the Root with a lower cumulative Cost).

----a. If a downstream bridge received those BPDUs on a Blocked Port, it would process the BPDU and then drop it. It could NOT forward that BPDU any further.

----b. If a downstream bridge received those BPDUs on a Root Port, it would process that BPDU, change the Sending Bridge-ID to it's own ID, update the "Root Cost" field, and then forward that BPDU out any Designated Ports it had.


2- Do Designated ports and Root ports on other switches recieve BPDU from peer switches ?

In 802.1d, if the Root Bridge temporarily stopped sending BPDUs for a few seconds (maybe because it's CPU was spiked at 100%, or it was having memory shortage issues, yada, yada, yada) then you would notice that there were NO BPDUs anywhere in the switched topology for that duration of time. In other words, if you (as a non-Root bridge) didn't receive a BPDU, you had nothing to send to anyone else.

3. Does any change(included disconnect cable or port shutdown) on switches of one STP domain result in STP process from scratch for election of root bridge and all phases for convergence of STP,as same as creating STP for first time ?

Ans: Root Bridge election will happen only when the existing root goes down. Any link disconnect / port shutdown will not trigger the election of root bridge again.

4. what does one switch do after receiving BPDU on portfast port?

Ans: It depends on where you have enabled portfast. when portfast is enabled globally, that port will lose its portfast status and would start operating as normal STP port. But when the portfast is enabled on the interface mode, then since LIS/LRN stages are bypassed on the portfast enabled port, you may be at a risk of causing loop.


5. what is minimum and maximum of STP convergence time ? Is it based on number of switch in STP domain?

Ans: Well this depends on the time of failure.. generally , STP convergence will start from disabled -> Listening -> Learning -> Forwarding / Blocking.

Listening is 15 sec, Learning is 15 sec. so convergence time is 30 seconds for a link to come in forwarding state. but this depends on the type of failure as well.

if it is an indirect link failure, it could be Max age (20)sec + Lis (15) sec + lear (15 ) sec = 50 sec delay.

When a link goes down / comes up, the switch generates TCN and send it on its root port towards the root bridge. all the switches towards the root will relay this towards the root bridge.

when the root bridge receives this , it sets the TCN Flag on its BPDU to "Yes" and send it across to all the switches downstream. so all the switches will set the CAM table aging timeout to forward delay (for the vlan's in which the failure was detected) and starts learning the CAM table again.

<
>
在培訓(xùn)行業(yè)極度市場化的今天,在網(wǎng)絡(luò)工程師魚目混珠的時代,帆聯(lián)科技扎根技術(shù)的理念從來沒有改變,帆聯(lián)科技從不提倡短線功利性考證培訓(xùn),嚴(yán)格要求教師和學(xué)員,要為自己的未來做出辛苦的努力。一分辛勞,一份收獲。

聯(lián)系我們

南寧市大學(xué)東路162號東盟財經(jīng)廣場1402

0771-3185755(服務(wù)時間:9:00-17:30)

admin@sail-lab.net

在線咨詢新浪微博官方微信官方微信

部門熱線

前   臺:0771-3185755
培訓(xùn)部:15994437962
認(rèn)證部:15994437962
技術(shù)部:15578317196

培訓(xùn)服務(wù) 考試認(rèn)證 校企合作 聯(lián)系電話0771-3185755 返回頂部
返回頂部