1

Those are the default path cost for STP :

10 Mbps --> 100

100 Mbps --> 19

1 Gbps --> 4

I have this topology :

enter image description here

All interfaces are set to 100Mb/s so each path cost is equal to 19. I forced the speed to 10 Mbps on the interface on S1 connected to S4 (fa0/1). However the path cost is still set 19 (100 Mbps) instead of 100 (10 Mbps).

enter image description here

enter image description here

Am I missing something ?

[Edit]

Current configuration : 1142 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname S1
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
no ip icmp rate-limit unreachable
!
!
ip cef
no ip domain lookup
!
!
!         
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
ip tcp synwait-time 5
! 
!
!
!
!
interface FastEthernet0/0
!
interface FastEthernet0/1
 speed 10
!
interface FastEthernet0/2
 speed 100
!
interface FastEthernet0/3
!
interface FastEthernet0/4
!
interface FastEthernet0/5
!
interface FastEthernet0/6
!
interface FastEthernet0/7
!
interface FastEthernet0/8
!
interface FastEthernet0/9
!
interface FastEthernet0/10
!         
interface FastEthernet0/11
!
interface FastEthernet0/12
!
interface FastEthernet0/13
!
interface FastEthernet0/14
!
interface FastEthernet0/15
!
interface Vlan1
 no ip address
!
no ip http server
no ip http secure-server
!
!
!
no cdp log mismatch duplex
!
!
!
control-plane
!
!
!
!
!
!
!
!
!
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line aux 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line vty 0 4
 login
!
!
end

-

 VLAN1 is executing the ieee compatible Spanning Tree protocol
  Bridge Identifier has priority 32768, address cc05.2858.0000
  Configured hello time 2, max age 20, forward delay 15
  We are the root of the spanning tree
  Topology change flag set, detected flag set
  Number of topology changes 36 last change occurred 00:01:17 ago
          from FastEthernet0/2
  Times:  hold 1, topology change 35, notification 2
          hello 2, max age 20, forward delay 15 
  Timers: hello 0, topology change 14, notification 0, aging 300

 Port 1 (FastEthernet0/0) of VLAN1 is forwarding
   Port path cost 19, Port priority 128, Port Identifier 128.1.
   Designated root has priority 32768, address cc05.2858.0000
   Designated bridge has priority 32768, address cc05.2858.0000
   Designated port id is 128.1, designated path cost 0
   Timers: message age 0, forward delay 0, hold 0
   Number of transitions to forwarding state: 1
   BPDU: sent 4555, received 0

 Port 2 (FastEthernet0/1) of VLAN1 is forwarding
   Port path cost 19, Port priority 128, Port Identifier 128.2.
   Designated root has priority 32768, address cc05.2858.0000
   Designated bridge has priority 32768, address cc05.2858.0000
   Designated port id is 128.2, designated path cost 0
   Timers: message age 0, forward delay 0, hold 0
   Number of transitions to forwarding state: 1
   BPDU: sent 4744, received 755

 Port 3 (FastEthernet0/2) of VLAN1 is forwarding
   Port path cost 19, Port priority 128, Port Identifier 128.3.
   Designated root has priority 32768, address cc05.2858.0000
   Designated bridge has priority 32768, address cc05.2858.0000
   Designated port id is 128.3, designated path cost 0
   Timers: message age 0, forward delay 0, hold 0
   Number of transitions to forwarding state: 1
   BPDU: sent 4634, received 335
1
  • It might be worth considering using pathcost long (network-wide) as it brings some sanity back to modern link types.
    – rnxrx
    Dec 19, 2016 at 14:15

1 Answer 1

2

The STP port costs are based on the bandwidth setting, not the hardware port speed. The bandwidth parameter is also used in calculating routing link costs in OSPF and EIGRP.

You can change the setting by the bandwidth command:

interface fa 0/1
bandwidth 10000

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.