Sie sind auf Seite 1von 4

STP

Here are the basic rules of STP


Lowest bridge ID (Priority: MAC Address) switch becomes the Root- .1
Bridge
Each non-root bridge should have ONE root port (RP) which is the .2
.port having lowest path-cost to Root Bridge
All ports in Root Bridge become Designated Ports (DP) .3
Each segment should have one Designated Port (DP) .4
All RP/DPs will be in FORWARDING state & all other ports will be in .5
.BLOCKING state
According to the topology CAT1 is having lowest MAC address (hence
lowest bridge ID) & will become the Root Bridge. Butif you do not
want to rely on MAC addreses you can lower priority of a given switch
to make them as the Root Bridge for all VLANs. In my case will make
.priority for all Vlans to lowest value( which is 0) in CAT1
Now we will look at which port become Root Port in each non-root
bridges (CAT2,CAT3,CAT4). Root Port selection is based on the port
having lowest cost to the Root Bridge (CAT1). For PVST (Per VLAN

Spanning Tree) path cost will depend on bandwidth of links and cost
.value is as shown below for most commonly used links
10Gbps -> 2
Gbps -> 4 1
Mbps -> 19 100
Mbps -> 100 10
Also it is important to understand how path cost calculate. From Root
Bridge it will send BPDU with cost to Root Bridge as 0. When this
BPDU receive by any other switch it will add its own port cost
(according to the above mentioned value). So if BPDU receive by a
Fast Ethernet port (100 Mbps) it will calculate path cost to root as 19
.(0+19)
For CAT3, it has 3 different option (label b,t,p). Here Root Port choice
is obvious, only via Fa 0/22 (b) is having lowest path cost to Root
.Bridge. So that will become the Root Port
For CAT2s it has 4 different ports (label d,f,u,r). Out of which two
ports (d & f) are having same path cost (19) to Root Bridge. Via port
u it is having path cost of 38 & via port r it is having path cost of
57. Since we have two equal cost paths, you need to know tie
,breaking rules in this scenario. Here they are
Lowest Sending Bridge ID .1
Lowest Port Priority (of sender) .2
Lowest Interface number (of sender) .3
In our case both port d & f receiving BPDU from same bridge
(CAT1) which suggest lowest port priority of sender will be the tie
breaker. By default each port is having priority value of 128 (can be
0-256 multiplier of 16). This makes lowest interface number of
sender it tie breaker. In our case CAT1s fa1/0/23 is having lower
interface number & therefore that BPDU received by CAT2s fa1/0/24
.will become root port

For CAT4, both port G0/3 q & G0/2 s are having equal path
cost(38) to root bridge(CAT1). But in this case port s is getting
BPDU from a lower bridge id switch CAT2 (32778: 001a.e3a7.ff00)

comparison to port q from CAT3 (32778: 0024.137b.5a00). In this


case Port s G0/2 become root port & Port Priority or Interface ID
wont come into play.
But in here if you want to make G0/3 as root port you can change its
port cost to a lower value which results lower path cost to root. In this
example I will change it to cost of 1 which resulting path cost to root
is 20 via that port. So that will become root port.
Now you know which port becomes a root port in each non-root
switches. So Port b, f & q will become root port in this topology.
If you want to identify which ports become Designated Ports (DP) you
.can follow below rules
All ports in Root Bridge will become Designated Ports .1
.Each segment (link) will have ONE Designated Port .2
If a given link does not have a Root Port, either of them could be a
designated port. But lower bridge ID switch port wins in this situation
(u in t-u link & r in r-s link ) become a DP. In this way ports
other than d, t & s will become either DP or RP. Hence those will
become FORWARDING ports & others (d,t,s) become BLOCKING
.Ports as shown in the below diagram

Das könnte Ihnen auch gefallen