howtonetwork.net

Cisco Certification Training

  • Products
  • CCNA
    • CCNA Videos
    • CCNA Lectures
    • CCNA Practice Exams
    • Challenge Labs
      • Challenge Video Solutions
    • Cisco Commands
  • CCNP ROUTE
    • ROUTE Exams
  • CCNP SWITCH
    • SWITCH Exams
  • CCNP TSHOOT
  • Home
  • Join
  • Downloads
  • About Us
  • Whitepapers
  • Feature Articles
  • Helpdesk
  • FAQ
  • Free Training
You are here: Home / spanning-tree vlan cost

spanning-tree vlan cost

Command

Spanning-Tree Vlan Cost

Use

This command modifies the interface cost used in calculating the root port for spanning-tree on a switch for a specified vlan range. Lower is better.

Syntax

Switch(config-if)#spanning-tree vlan <vlan range> cost <cost>

Example

In the below example we will configure SW2 to use Fa0/24 as the VLAN 10’s root port.

SW2(config)#do show spanning vlan 10

VLAN0010
Spanning tree enabled protocol ieee
Root ID Priority 8202
Address 0019.060c.4f80
Cost 19
Port 25 (FastEthernet0/23)
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 16394 (priority 16384 sys-id-ext 10)
Address 0019.060c.cb00
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Aging Time 15

Interface Role Sts Cost Prio.Nbr Type
—————- —- — ——— ——– ——————————–
Fa0/19 Desg LRN 19 128.21 P2p
Fa0/20 Desg LRN 19 128.22 P2p
Fa0/21 Desg FWD 19 128.23 P2p
Fa0/22 Desg LRN 19 128.24 P2p
Fa0/23 Root LRN 19 128.25 P2p
Fa0/24 Altn BLK 19 128.26 P2p

 

Next, we configure Fa0/24 for VLAN 10 to have a cost of 1.

SW2(config)#int fa0/24
SW2(config-if)#spanning vlan 10 cost 1

After we change Fa0/24 to have a lower cost, it becomes the root port on SW2.

SW2(config-if)#do show spanning vlan 10

VLAN0010
Spanning tree enabled protocol ieee
Root ID Priority 8202
Address 0019.060c.4f80
Cost 1
Port 26 (FastEthernet0/24)
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec

Bridge ID Priority 16394 (priority 16384 sys-id-ext 10)
Address 0019.060c.cb00
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Aging Time 300

Interface Role Sts Cost Prio.Nbr Type
—————- —- — ——— ——– ——————————–
Fa0/19 Desg FWD 19 128.21 P2p
Fa0/20 Desg FWD 19 128.22 P2p
Fa0/21 Desg FWD 19 128.23 P2p
Fa0/22 Desg FWD 19 128.24 P2p
Fa0/23 Altn BLK 19 128.25 P2p
Fa0/24 Root FWD 1 128.26 P2p

Get access to over 5 hours of IT webinar videos as well as regular study tips and ideas when you
join our mailing list

About This Site

We replaced this site some time ago with an upgraded version. Please feel free to enjoy the content and if you like what you see check out our brilliant new site:

howtonetwork.com

Keep In Touch

About Us

This is a free access website which has now been replaced by howtonetwork.com.

Navigation

  • Home
  • Join
  • Downloads
  • About Us
  • Whitepapers
  • Feature Articles
  • Helpdesk
  • FAQ
  • Free Training

Copyright

All content is protected by international copyright laws. Copyright Reality Press Ltd.

Copyright © 2023 · Dynamik Website Builder on Genesis Framework · WordPress · Log in