mstp實例分析

拓撲:api

 

 

SW1配置:網絡

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 1
instance 1 vlan 10-19
instance 2 vlan 20-29
!
spanning-tree mst 1-2 priority 24576
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10ide

SW2配置:spa

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 1
instance 1 vlan 10-19
instance 2 vlan 20-29
!
spanning-tree mst 1-2 priority 28672
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
duplex auto
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 103d

SW3配置:blog

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 2
instance 1 vlan 10-19
instance 2 vlan 20-29
!
spanning-tree mst 1-2 priority 24576
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
duplex auto
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/2
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10get

SW4配置:it

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 2
instance 1 vlan 10-19
instance 2 vlan 20-29
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10io

SW5配置:class

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 2
instance 1 vlan 10-19
instance 2 vlan 20-29
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/2
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10

SW6配置:

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 3
instance 1 vlan 10-19
instance 2 vlan 20-29
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10

interface Ethernet0/2
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10

SW7配置:

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 3
instance 1 vlan 10-19
instance 2 vlan 20-29
!
spanning-tree mst 1-2 priority 24576
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/2
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10

SW8配置:

spanning-tree mode mst
spanning-tree extend system-id
!
spanning-tree mst configuration
name mst
revision 3
instance 1 vlan 10-19
instance 2 vlan 20-29
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10
!
interface Ethernet0/1
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point
spanning-tree mst 0-2 cost 10

SW9配置:

spanning-tree mode rapid-pvst
spanning-tree extend system-id
!
interface Ethernet0/0
switchport
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree link-type point-to-point

分析:

區域A

 因爲SW1的優先級(24577)小於SW2的優先級(28637)因此對於區域A來講SW1是跟橋。

因爲SW3的優先級大於SW4 SW5的優先級,因此在區域B中被選位跟橋。

因爲SW7的優先級大於SW6 SW8的優先級,因此在區域C中被選位跟橋。

從上面分析能夠看出在區域內的行爲和RSTP相似。從這個交換機網絡來講無論是MST區域仍是非MST區域(SW9)選舉跟橋(總根)的行爲是同樣的既最小的橋ID。

 

 

從上圖看出若是把區域看作是一個虛擬的交換機,那個在整個區域的行爲和RSTP相似。

相關文章
相關標籤/搜索