在各交换机配置STP,使得A交换机是根桥,D是备份桥
C交换机的e0/0/1接口处于闭塞状态(discarding)
交换机之间的路径开销计算标准采用华为私有方法(legacy)
关闭C交换机的e0/0/2接口之后,在查看该交换机的e0/0/1接口
此时的状态是forwarding,则说明配置成功

<Huawei>undo terminal monitor
<Huawei>system-view
Huaweisysname SA
SAstp enable
SAstp mode stp
SAstp priority 4096
SAstp pathcost-standard legacy

<Huawei>system-view
Huaweisysname SB
SBstp enable
SBstp mode stp
SBstp pathcost-standard legacy
SBint e0/0/3
SB-Ethernet0/0/3stp edged-port enable
SB-Ethernet0/0/3stp bpdu-filter enable
SB-Ethernet0/0/3q

Huaweisysname SC
SCstp enable
SCstp mode stp
SCstp pathcost-standard legacy
SCin e0/0/1
SC-Ethernet0/0/1stp cost 20000
SC-Ethernet0/0/1in e0/0/3
SC-Ethernet0/0/3stp edged-port enable
SC-Ethernet0/0/3stp bpdu-filter enable
SC-Ethernet0/0/3q

<Huawei>system-view
Enter system view, return user view with Ctrl+Z.
Huaweisysname SD
SDstp enable
SDstp mode stp
SDstp priority 8192
SDstp pathcost-standard legacy

配置结束,开始测试

关闭0001C的2口,
SC-Ethernet0/0/2undo shutdown
关闭接口,连接超时
继续查看SC的配置

Ping通
