拓扑图
配置
根桥选举
- 比较桥ID(优先级+MAC地址),优先级默认32768,值越小越优先,优先级相同,MAC地址小的优先
端口角色确定
- 根桥的接口为指定端口
- 非根桥的端口比较顺序
- 根路径开销RPC
- 发送者桥ID
- 发送者PID
- 自己的PID
sysname SW1
#
vlan batch 10 20 30 40
#
stp instance 1 priority 8192
stp instance 2 root secondary
#
stp region-configuration
region-name MST
revision-level 123
instance 1 vlan 10 30
instance 2 vlan 20 40
active region-configuration
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
sysname SW2
#
vlan batch 10 20 30 40
#
stp instance 1 priority 16384
stp instance 2 root primary
#
stp region-configuration
region-name MST
revision-level 123
instance 1 vlan 10 30
instance 2 vlan 20 40
active region-configuration
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 2 to 4094
sysname SW3
#
vlan batch 10 20 30 40
#
stp region-configuration
region-name MST
revision-level 123
instance 1 vlan 10 30
instance 2 vlan 20 40
active region-configuration
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 2 to 4094
查看实例1、2阻塞端口
查看实例的根桥
查看映射关系