stp的基础配置
2023-09-11 14:22:31 时间
stp的基础配置
原理
1)BPDU bridge protocol data unit 桥协议数据单元
运行了生成树协议的交换机彼此之间用来交流生成树信息的数据包
类型:
配置BPDU :详细介绍生成树的基本信息
拓扑变更BPDU:把生成树的变化信息告诉别的交换机
内容:
根网桥的网桥ID、自己的网桥ID、到根网桥的成本、端口ID
2)stp端口状态
生成树选举需要一定的时间和过程:stp收敛
收敛:设备从不稳定到稳定的过程
禁用 disabled 强制关闭
阻塞 blocking 不能转发数据帧,可以接收BPDU;
侦听 listening 不能转发数据帧,可以发送和接收BPDU;
学习 leraning 构建 MAC地址表
转发 forwarding 转发数据帧
3)STP计时器
hello时间:2s,交换机发送BPDU的频率和周期
max-age(最大老化时间):20s, 表示的是交换机的接口如果在指定时间没有接收到
BPDU的更新,那就把原来BPDU信息删除;
forward-relay(转发延迟):15s
侦听---->学习 15s
学习---->转发 15s
拓扑图
配置命令
sw1
<Huawei>sys
[Huawei]sys
[Huawei]sysname sw1
[sw1]dis stp
-------[CIST Global Info][Mode MSTP]-------
CIST Bridge :32768.4c1f-ccf6-5fa1
Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC :32768.4c1f-cc14-43f4 / 200000
CIST RegRoot/IRPC :32768.4c1f-ccf6-5fa1 / 0
CIST RootPortId :128.1
BPDU-Protection :Disabled
TC or TCN received :5
TC count per hello :0
STP Converge Mode :Normal
Time since last TC :0 days 0h:31m:2s
Number of TC :3
[sw1]stp mode stp
Info: This operation may take a few seconds. Please wait for a moment...done.
[sw1]dis stp
-------[CIST Global Info][Mode STP]-------
CIST Bridge :32768.4c1f-ccf6-5fa1
Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC :32768.4c1f-cc14-43f4 / 200000
CIST RegRoot/IRPC :32768.4c1f-ccf6-5fa1 / 0
CIST RootPortId :128.1
BPDU-Protection :Disabled
TC or TCN received :5
TC count per hello :0
STP Converge Mode :Normal
Time since last TC :0 days 0h:31m:34s
Number of TC :3
Last TC occurred :Ethernet0/0/1
[sw1]display stp brief
MSTID Port Role STP State Protection
0 Ethernet0/0/1 ROOT FORWARDING NONE
0 Ethernet0/0/2 ALTE DISCARDING NONE
[sw1]quit
<sw1>display bridge mac-address
System bridge MAC address: 4c1f-ccf6-5fa1
<sw1>
sw2
<Huawei>u t m
<Huawei>sys
[Huawei]sys
[Huawei]sysname sw2
[sw2]dis stp
-------[CIST Global Info][Mode MSTP]-------
CIST Bridge :32768.4c1f-cc14-43f4
Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC :32768.4c1f-cc14-43f4 / 0
CIST RegRoot/IRPC :32768.4c1f-cc14-43f4 / 0
CIST RootPortId :0.0
BPDU-Protection :Disabled
TC or TCN received :5
TC count per hello :0
STP Converge Mode :Normal
Time since last TC :0 days 0h:31m:4s
Number of TC :5
Last TC occurred :Ethernet0/0/3
----[Port1(Ethernet0/0/1)][FORWARDING]----
Port Protocol :Enabled
[sw2]stp mode stp
Info: This operation may take a few seconds. Please wait for a moment...done.
[sw2]dis stp
-------[CIST Global Info][Mode STP]-------
CIST Bridge :32768.4c1f-cc14-43f4
Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC :32768.4c1f-cc14-43f4 / 0
CIST RegRoot/IRPC :32768.4c1f-cc14-43f4 / 0
CIST RootPortId :0.0
BPDU-Protection :Disabled
TC or TCN received :5
TC count per hello :0
STP Converge Mode :Normal
[sw2]display stp brief
MSTID Port Role STP State Protection
0 Ethernet0/0/1 DESI FORWARDING NONE
0 Ethernet0/0/3 DESI FORWARDING NONE
[sw2]display bridge mac-address
System bridge MAC address: 4c1f-cc14-43f4
[sw2]
sw3
<Huawei>sys
[Huawei]sysname sw3
[sw3]dis stp
-------[CIST Global Info][Mode MSTP]-------
CIST Bridge :32768.4c1f-cc96-3d85
Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC :32768.4c1f-cc14-43f4 / 200000
CIST RegRoot/IRPC :32768.4c1f-cc96-3d85 / 0
CIST RootPortId :128.3
BPDU-Protection :Disabled
TC or TCN received :2
TC count per hello :0
STP Converge Mode :Normal
Time since last TC :0 days 0h:31m:4s
Number of TC :4
Last TC occurred :Ethernet0/0/2
[sw3]stp mode stp
Info: This operation may take a few seconds. Please wait for a moment...done.
[sw3]dis stp
-------[CIST Global Info][Mode STP]-------
CIST Bridge :32768.4c1f-cc96-3d85
Config Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
Active Times :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC :32768.4c1f-cc14-43f4 / 200000
CIST RegRoot/IRPC :32768.4c1f-cc96-3d85 / 0
CIST RootPortId :128.3
BPDU-Protection :Disabled
TC or TCN received :3
TC count per hello :0
STP Converge Mode :Normal
<sw3>display stp brief
MSTID Port Role STP State Protection
0 Ethernet0/0/2 DESI FORWARDING NONE
0 Ethernet0/0/3 ROOT FORWARDING NONE
<sw3>display
<sw3>display br
<sw3>display bridge mac
<sw3>display bridge mac-address
System bridge MAC address: 4c1f-cc96-3d85
<sw3>
相关文章
- redis基础之安装和配置(一)
- 绝对详细!Nginx基本配置、性能优化指南
- SpringBoot2.0 基础案例(16):配置Actuator组件,实现系统监控
- SpringBoot2.0 基础案例(15):配置MongoDB数据库,实现增删改查逻辑
- JNDI数据源的配置
- 7 -- Spring的基本用法 -- 5... Spring容器中的Bean;容器中Bean的作用域;配置依赖;
- Myeclipse2014配置Tomcat 8.56(图解版)
- VC6.0下opencv1.0的环境配置
- SpringBoot配置自定义包扫描
- Centos7配置BIND开机自启动
- H3C RIP可选配置
- Apache Flink 零基础入门(二):开发环境搭建和应用的配置、部署及运行
- bean基础配置
- goj基础环境的配置
- Ubuntu下配置Mysql的远程管理
- 【UVM基础】sequence机制快速上手指南(数据激励的产生、配置方式)
- 【UVM基础】phase机制快速上手指南(包括:只能在build_phase配置?为什么建议先配置再实例化?什么时候用super.xxx_phase?)
- 利用华为ENSP模拟器分析和配置中小型企业网络的综合实验(上)
- Web 基础 之 Eclipse 中配置自己的 Maven ,并运行 Maven 工程简单整理
- Web 基础 之 Maven 下载和环境搭建配置的简单整理
- Linux下nginx的安装以及环境配置
- MySQL 教程(基础篇)第02话:MySQL 8.0 下载、安装和配置(Linux 版)——使用 Yum Repository 方式