H3C-stp-链路聚合-端口安全

STP

实验拓扑

image-20220711161442592


实验需求

  1. 开启所有设备,等待STP收敛后观察STP状态
  2. 使SW4成为根网桥
  3. 使闭塞端口出现在SW2上
  4. 把SW1上连接的PC的端口配置为边缘端口

实验步骤:

1.开启stp           #交换机默认运行mstp
SW1
[sw1]stp mode stp   #手动修改模式为stp

sw2
[sw2]stp mode stp 

sw3
[sw3]stp mode stp

sw4
[sw4]stp mode stp

sw1
[sw1]dis int GigabitEthernet 1/0/4                 #查看接口
GigabitEthernet1/0/4
Current state: DOWN
Line protocol state: DOWN
IP packet frame type: Ethernet II, hardware address: 409e-e6a0-0100             #本机的mac地址
Description: GigabitEthernet1/0/4 Interface
Bandwidth: 1000000 kbps

##查看完所有mac(优先级都是默认的),可以看到sw4<sw3<sw2<sw1
##所以 可以得知sw1为根,到时候sw4上会有一个蔽塞端口(AP)

观察STP状态
sw1
[sw1]dis stp
-------[CIST Global Info][Mode STP]-------
 Bridge ID           : 32768.409e-e6a0-0100
 Bridge times        : Hello 2s MaxAge 20s FwdDelay 15s MaxHops 20
 Root ID/ERPC        : 32768.409e-e6a0-0100, 0                      #可以看出根为自己
 RegRoot ID/IRPC     : 32768.409e-e6a0-0100, 0
 RootPort ID         : 0.0
 BPDU-Protection     : Disabled
 Bridge Config-
 Digest-Snooping     : Disabled
 TC or TCN received  : 4
 Time since last TC  : 0 days 0h:14m:13s

sw4
[sw4]dis stp
-------[CIST Global Info][Mode STP]-------
 Bridge ID           : 32768.409f-0322-0400
 Bridge times        : Hello 2s MaxAge 20s FwdDelay 15s MaxHops 20
 Root ID/ERPC        : 32768.409e-e6a0-0100, 40                          #根为sw1
 RegRoot ID/IRPC     : 32768.409f-0322-0400, 0
 RootPort ID         : 128.2
 BPDU-Protection     : Disabled
 Bridge Config-
 Digest-Snooping     : Disabled
 TC or TCN received  : 20
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值