RSTP协议原理与配置整——RSTP配置实例

261 阅读1分钟

RSTP协议原理与配置整——RSTP配置实例


RSTP配置需求

SWA、SWB和SWC组成了一个环形的交换网络,为了消除环路对网络的影响,故使交换机都运行RSTP,最终将环形网络结构修剪成无环路的树形网络结构。

RSTP配置实现

配置实现:

stp enable //全局开启STP

stp mode rstp //配置STP模式为RSTP

stp root primary //配置SWA为根桥

stp bpdu-protection //全局开启BPDU防护,配合边缘端口一起使用

stp edged-port enable //配置端口为边缘端口

RSTP配置验证

display stp brief

MSTID Port Role STP State Protection

0 GigabitEthernet0/0/1 DESI FORWARDING NONE

0 GigabitEthernet0/0/2 DESI FORWARDING NONE

display stp

-------[CIST Global Info][Mode RSTP]-------

CIST Bridge :0 .4c1f-cc5f-55e4

Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20

Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20

CIST Root/ERPC :0 .4c1f-cc5f-55e4 / 0

CIST RegRoot/IRPC :0 .4c1f-cc5f-55e4 / 0

CIST RootPortId :0.0

BPDU-Protection :Disabled

RSTP配置验证

在SWB上查看生成树信息

[SWB]display stp brief

MSTID Port Role STP State Protection

0 GigabitEthernet0/0/1 ROOT FORWARDING NONE

0 GigabitEthernet0/0/3 DESI FORWARDING NONE

0 GigabitEthernet0/0/4 DESI FORWARDING BPDU

在SWC上查看生成树信息:

display stp brief

MSTID Port Role STP State Protection

0 GigabitEthernet0/0/2 ROOT FORWARDING NONE

0 GigabitEthernet0/0/3 ALTE DISCARDING NONE

0 GigabitEthernet0/0/4 DESI FORWARDING BPDU