Per VLAN Spanning Tree (PVST)

Since you are reading this I assume you understand how “classic” spanning-tree works. If you don’t, it’s best to read my Introduction to spanning-tree first before you continue.

Since you are reading this I assume you understand how "classic" spanning-tree works. If you don't, it's best to read my Introduction to spanning-tree first before you continue. Having said that, let's start with a nice picture: VLAN 10 is configured on SW1 and SW2. VLAN 20 is configured on SW1, SW2

Having said that, let’s start with a nice picture:

VLAN 10 is configured on SW1 and SW2.

VLAN 20 is configured on SW1, SW2 and SW3.

Question for you: do we have a loop in VLAN 10? What about VLAN 20?

There’s a big difference between our physical and logical topology. We don’t have a loop in VLAN 10 because it only runs on the link between SW1 and SW2. We DO have a loop within VLAN 20 however.

How does spanning-tree deal with this? Simple…we’ll just calculate a different spanning-tree for each VLAN! The oldest version of spanning-tree is called CST (Common Spanning-Tree) and is defined in the 802.1D standard. It only calculates a single spanning-tree for all VLANs.

Another version of spanning-tree is able to calculate a topology for each VLAN. This version is called PVST (Per VLAN Spanning-Tree) and it’s the default on Cisco switches.

Let’s look at an example where we have three switches and two VLANs. Both VLANs are available on all switches:

Above you can see that we have two root bridges. If we use PVST we can create a different root bridge for each VLAN if we want. SW1 could be the root bridge for VLAN 10 and SW2 could be the root bridge for VLAN 20. Why would you want to do this? Here’s an example:

If I would make one switch root bridge for both VLANs then one interface will be blocked for both VLANs. In my example above SW1 is the root bridge for VLAN 10 and 20 and as a result the fa0/16 interface on SW3 is blocked for both VLANs. No traffic will be forwarded on the fa0/16 interface at all. Imagine these were 10 Gigabit interfaces. It would be a shame if one of those expensive interfaces wasn’t doing anything right?

Since you are reading this I assume you understand how "classic" spanning-tree works. If you don't, it's best to read my Introduction to spanning-tree first before you continue. Having said that, let's start with a nice picture: VLAN 10 is configured on SW1 and SW2. VLAN 20 is configured on SW1, SW2

If I choose another switch as the root bridge for VLAN 20 we will see different results:

PVST+ is the default configuration on most modern Cisco switches. If you have changed this default and you want to revert back to PVST+ you can do this by issuing the following command: spanning-tree mode pvst.

Now the fact that the ‘+’ is not included can be a bit confusing. Keep in mind that plain PVST is no longer configurable on a switch, it’s always PVST+ so even if you see ‘pvst’ alone in the command, it is always PVST+ that is being referred to.

The advantage of PVST+ is that it sends 802.1D compatible BPDUs, as well as Cisco proprietary,