Prioritizing traffic by VLAN
Prioritizing traffic by VLAN VLANS 1–2 VLANS 3–4 set spantree portvlanpri 1/1 16 1-2 set spantree portvlanpri 1/2 16 3-4 1/1 1/2 Scaling the Spanning Tree Protocol 515 Terry_4000> (enable) set spantree portvlanpri 1/1 16 1-2 Port 1/1 vlans 1-2 using portpri 16. Port 1/1 vlans 3-1004 using portpri 20. Port 1/1 vlans 1005 using portpri 4. Terry_4000> (enable) set spantree portvlanpri 1/2 16 3-4 Port 1/2 vlans 1-2,5-1004 using portpri 32. Port 1/2 vlans 3-4 using portpri 16. Port 1/2 vlans 1005 using portpri 4. Terry_4000> (enable) The preceding switch output displays the VLAN priority information. We set both VLAN port priorities to 16. Notice that for VLANs 1–4, the priority is 16. However, on port 1/1, all the other VLANs are listed as having a port priority of 20 because that is what we set the port priority to earlier in this chapter. On port 1/2, the switch thinks all the other ports have a port priority of 32, except for VLAN 1005, which becomes a default priority of 4. You can view the changes by using the show spantree slot/port command, as shown here: Terry_4000> (enable) show spantree 1/1 Port Vlan Port-State Cost Priority Fast-Start --------- ---- ------------- ----- -------- ---------- 1/1 1 forwarding 10 16 disabled 1/1 2 forwarding 10 16 disabled 1/1 3 forwarding 10 20 disabled 1/1 4 forwarding 10 20 disabled 1/1 1003 not-connected 10 20 disabled 1/1 1005 not-connected 10 4 disabled
Terry_4000> (enable) show spantree 1/2 Port Vlan Port-State Cost Priority Fast-Start --------- ---- ------------- ----- -------- ---------- 1/2 1 forwarding 19 32 disabled 1/2 2 forwarding 19 32 disabled 1/2 3 forwarding 19 16 disabled 1/2 4 forwarding 19 16 disabled 1/2 1003 not-connected 19 32 disabled 1/2 1005 not-connected 19 4 disabled Terry_4000> (enable) Setting the VLAN priority on the IOS-based switches is carried out using the interface command spanning-tree vlan vlan_number port-priority priority. Looking at the default configuration, we can see that the port priority is set to 128.
Terry_2950#show spanning-tree VLAN0001 Spanning tree enabled protocol ieee [Output cut] Interface Port ID Designated Port ID Name Prio.Nbr Cost Sts Cost Bridge ID Prio.Nbr ---------------- -------- --------------- -------------------- -------- Fa0/1 128.1 100 BLK 0 1 00b0.6414.1180 128.1 Fa0/24 128.24 20 FWD 0 1 00b0.6414.1180 128.12 If we want to change the VLAN port priority on the 2950 switch to make the port more desirable, then we can reduce the priority as follows: Terry_2950#conf t Terry_2950(config)#interface fa0/1 Terry_2950(config-if)#spanning-tree vlan 1 port-priority 20 Terry_2950(config-if)#^Z Terry_2950#sho span VLAN0001 Spanning tree enabled protocol ieee Root ID Priority 1 Address 00b0.6414.1180 Cost 20 Port 24 (FastEthernet0/24) Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Bridge ID Priority 32769 (priority 32768 sys-id-ext 1) Address 000b.be53.2c00 Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec Aging Time 300 Interface Port ID Designated Port ID Name Prio.Nbr Cost Sts Cost Bridge ID Prio.Nbr ---------------- -------- ------------- --------- -------------------- Fa0/1 20.1 20 FWD 0 1 00b0.6414.1180 128.1 Fa0/24 128.24 20 BLK 0 1 00b0.6414.1180 128.12
By changing either the port priority or the port cost, you can persuade the switch to use your chosen paths. However, there are some miscellaneous other STP variables that you can change. We’ll discuss those next.
407 times read
|
|
|
Did you enjoy this article?
(total 0 votes)
|