华为mstp.docx

上传人:b****5 文档编号:28552158 上传时间:2023-07-18 格式:DOCX 页数:15 大小:23.49KB
下载 相关 举报
华为mstp.docx_第1页
第1页 / 共15页
华为mstp.docx_第2页
第2页 / 共15页
华为mstp.docx_第3页
第3页 / 共15页
华为mstp.docx_第4页
第4页 / 共15页
华为mstp.docx_第5页
第5页 / 共15页
点击查看更多>>
下载资源
资源描述

华为mstp.docx

《华为mstp.docx》由会员分享,可在线阅读,更多相关《华为mstp.docx(15页珍藏版)》请在冰豆网上搜索。

华为mstp.docx

华为mstp

配置MSTP的基本功能示例

组网需求

交换机S9300A、S9300B、S9300C和S9300D都支持MSTP,本例中的交换机都使用二层接口运行MSTP。

图1配置MSTP的基本功能组网图

配置思路

采用如下的思路配置MSTP的基本功能:

1.将S9300A和S9300C配置到一个域内,域名为RG1,创建实例1。

2.将S9300B和S9300D配置到另外一个域,域名为RG2,创建实例1。

3.配置交换机S9300A为CIST总根。

4.在域RG1内,交换机S9300A为CIST域根,S9300A为实例1的域根。

在S9300A的GE端口6/0/2和GE端口6/0/1上应用根保护功能。

5.在域RG2内,交换机S9300B为CIST域根,S9300D为实例1的域根。

6.S9300C和S9300D的GE端口1/0/1与PC机相连,设置为边缘端口,同时在S9300C和S9300D上应用BPDU保护功能。

7.在S9300A、S9300B、S9300C和S9300D使用华为私有计算方法计算路径开销。

数据准备

为完成此配置例,需准备如下的数据:

∙S9300A和S9300C的域名为RG1

∙S9300B和S9300D的域名为RG2

∙各GE端口号如图1所示

∙VLAN号是1~20

操作步骤

1.配置交换机S9300A

#配置S9300A的MST域。

system-view

[S9300A]stpregion-configuration

[S9300A-mst-region]region-nameRG1

[S9300A-mst-region]instance1vlan1to10

#激活域配置。

[S9300A-mst-region]checkregion-configuration

[S9300A-mst-region]activeregion-configuration

[S9300A-mst-region]quit

#配置S9300A在实例0中的优先级为0,保证S9300A作为CIST的总根。

[S9300A]stpinstance0priority0

#配置S9300A在实例1中的优先级为0,保证S9300A作为实例1的域根。

[S9300A]stpinstance1priority0

#配置端口路径开销的计算方法为华为私有计算方法。

[S9300A]stppathcost-standardlegacy

#创建VLAN1到20。

[S9300A]vlanbatch2to20

#将端口6/0/2加入VLAN。

[S9300A]interfaceGigabitEthernet6/0/2

[S9300A-GigabitEthernet6/0/2]portlink-typetrunk

[S9300A-GigabitEthernet6/0/2]porttrunkallow-passvlan1to20

[S9300A-GigabitEthernet6/0/2]quit

#将端口6/0/1加入VLAN。

[S9300A]interfaceGigabitEthernet6/0/1

[S9300A-GigabitEthernet6/0/1]portlink-typetrunk

[S9300A-GigabitEthernet6/0/1]porttrunkallow-passvlan1to20

[S9300A-GigabitEthernet6/0/1]quit

#在端口6/0/1上启动根保护。

[S9300A]interfaceGigabitEthernet6/0/1

[S9300A-GigabitEthernet6/0/1]stproot-protection

[S9300A-GigabitEthernet6/0/1]quit

#在端口6/0/2上启动根保护。

[S9300A]interfaceGigabitEthernet6/0/2

[S9300A-GigabitEthernet6/0/2]stproot-protection

[S9300A-GigabitEthernet6/0/2]quit

#启动MSTP。

[S9300A]stpenable

2.配置交换机S9300B

#配置S9300B的MST域。

[S9300B]stpregion-configuration

[S9300B-mst-region]region-nameRG2

[S9300B-mst-region]instance1vlan1to10

#激活域配置。

[S9300B-mst-region]checkregion-configuration

[S9300B-mst-region]activeregion-configuration

[S9300B-mst-region]quit

#配置S9300B在实例0中的优先级为4096,保证S9300B作为CIST的域根。

[S9300B]stpinstance0priority4096

#配置端口路径的开销计算方法为华为私有计算方法。

[S9300B]stppathcost-standardlegacy

#创建VLAN1到20。

[S9300B]vlanbatch2to20

#将端口6/0/1加入VLAN。

[S9300B]interfaceGigabitEthernet6/0/1

[S9300B-GigabitEthernet6/0/1]portlink-typetrunk

[S9300B-GigabitEthernet6/0/1]porttrunkallow-passvlan1to20

[S9300B-GigabitEthernet6/0/1]quit

#将端口6/0/2加入VLAN。

[S9300B]interfaceGigabitEthernet6/0/2

[S9300B-GigabitEthernet6/0/2]portlink-typetrunk

[S9300B-GigabitEthernet6/0/2]porttrunkallow-passvlan1to20

[S9300B-GigabitEthernet6/0/2]quit

#启动MSTP。

[S9300B]stpenable

3.配置S9300C

#配置S9300C的MST域。

[S9300C-mst-region]checkregion-configuration

[S9300C]stpregion-configuration

[S9300C-mst-region]region-nameRG1

[S9300C-mst-region]instance1vlan1to10

#激活域配置。

[S9300C-mst-region]activeregion-configuration

[S9300C-mst-region]quit

#配置端口路径开销的计算方法为华为私有计算方法。

[S9300C]stppathcost-standardlegacy

#启动BPDU保护功能

[S9300C]stpbpdu-protection

#创建VLAN1到20。

[S9300C]vlanbatch2to20

#将端口1/0/2加入VLAN。

[S9300C]interfaceGigabitEthernet1/0/2

[S9300C-GigabitEthernet1/0/2]portlink-typetrunk

[S9300C-GigabitEthernet1/0/2]porttrunkallow-passvlan1to20

[S9300C-GigabitEthernet1/0/2]quit

#将端口2/0/1加入VLAN。

[S9300C]interfaceGigabitEthernet2/0/1

[S9300C-GigabitEthernet2/0/1]portlink-typetrunk

[S9300C-GigabitEthernet2/0/1]porttrunkallow-passvlan1to20

[S9300C-GigabitEthernet2/0/1]quit

#将端口1/0/1配置成边缘端口。

[S9300C]interfaceGigabitEthernet1/0/1

[S9300C-GigabitEthernet1/0/1]stpedged-portenable

[S9300C-GigabitEthernet1/0/1]porthybridpvidvlan20

[S9300C-GigabitEthernet1/0/1]porthybriduntaggedvlan20

[S9300C-GigabitEthernet1/0/1]quit

#启动MSTP。

[S9300C]stpenable

4.配置S9300D

#配置S9300D的MST域。

[S9300D-mst-region]checkregion-configuration

[S9300D]stpregion-configuration

[S9300D-mst-region]region-nameRG2

[S9300D-mst-region]instance1vlan1to10

#激活域配置。

[S9300D-mst-region]activeregion-configuration

[S9300D-mst-region]quit

#配置S9300D在实例1中的优先级为0,保证S9300D做为实例1的域根。

[S9300D]stpinstance1priority0

#配置端口路径开销的计算方法为华为私有计算方法。

[S9300D]stppathcost-standardlegacy

#启动BPDU保护功能。

[S9300D]stpbpdu-protection

#创建VLAN1到20。

[S9300D]vlanbatch2to20

#将端口1/0/2加入VLAN。

[S9300D]interfacegigabitEthernet1/0/2

[S9300D-GigabitEthernet1/0/2]portlink-typetrunk

[S9300D-GigabitEthernet1/0/2]porttrunkallow-passvlan1to20

[S9300D-GigabitEthernet1/0/2]quit

#将端口2/0/1加入VLAN。

[S9300D]interfaceGigabitEthernet2/0/1

[S9300D-GigabitEthernet2/0/1]portlink-typetrunk

[S9300D-GigabitEthernet2/0/1]porttrunkallow-passvlan1to20

[S9300D-GigabitEthernet2/0/1]quit

#将端口1/0/1配置成边缘端口。

[S9300D]interfaceGigabitEthernet1/0/1

[S9300D-GigabitEthernet1/0/1]stpedged-portenable

[S9300D-GigabitEthernet1/0/1]porthybridpvidvlan10

[S9300D-GigabitEthernet1/0/1]porthybriduntaggedvlan10

[S9300D-GigabitEthernet1/0/1]quit

#启动MSTP。

[S9300D]stpenable

5.验证配置结果

经过以上配置,在网络计算稳定后,执行以下操作,验证配置结果。

#在S9300A上执行displaystpbrief命令,查看端口状态和端口的保护类型,结果如下:

displaystpbrief

MSTIDPortRoleSTPStateProtection

0GigabitEthernet6/0/2DESIFORWARDINGROOT

0GigabitEthernet6/0/1DESIFORWARDINGROOT

1GigabitEthernet6/0/2DESIFORWARDINGROOT

1GigabitEthernet6/0/1DESIFORWARDINGROOT

由于交换机S9300A在CIST内优先级最高,所以S9300A被选择为CIST总根,同时它也是RG1的域根。

S9300A的端口6/0/2和6/0/1在CIST上都是指定端口。

交换机S9300A实例1上的优先级在域RG1内最高,所以S9300A被选择为实例1的域根。

端口6/0/2和6/0/1在实例1上都被计算为指定端口。

#在S9300C上执行displaystpinterfacebrief命令,结果如下:

displaystpinterfaceGigabitEthernet2/0/1brief

MSTIDPortRoleSTPStateProtection

0GigabitEthernet2/0/1ROOTFORWARDINGNONE

1GigabitEthernet2/0/1ROOTFORWARDINGNONE

displaystpinterfaceGigabitEthernet1/0/2brief

MSTIDPortRoleSTPStateProtection

0GigabitEthernet1/0/2DESIFORWARDINGNONE

1GigabitEthernet1/0/2DESIFORWARDINGNONE

S9300C的端口2/0/1在CIST和实例1中为根端口。

S9300C的另一个端口1/0/2,在CIST和实例1中都是指定端口。

#在交换机S9300B上执行displaystpbrief命令,结果如下:

displaystpbrief

MSTIDPortRoleSTPStateProtection

0GigabitEthernet6/0/2ROOTFORWARDINGNONE

0GigabitEthernet6/0/1DESIFORWARDINGNONE

1GigabitEthernet6/0/2MASTFORWARDINGNONE

1GigabitEthernet6/0/1ROOTFORWARDINGNONE

交换机S9300B在CIST上的优先级低于S9300A,端口6/0/2在CIST被计算为根端口。

同时因为S9300A和S9300B不属于同一个域,所以端口6/0/2在实例1上被计算为Master端口。

在实例1中,S9300B的优先级低于S9300D,所以端口6/0/1被计算为根端口。

S9300B在CIST中的优先级高于S9300D,端口6/0/1在CIST被计算为指定端口。

#在S9300D上执行displaystpinterfacebrief命令,结果如下:

displaystpinterfaceGigabitEthernet2/0/1brief

MSTIDPortRoleSTPStateProtection

0GigabitEthernet2/0/1ROOTFORWARDINGNONE

1GigabitEthernet2/0/1DESIFORWARDINGNONE

displaystpinterfaceGigabitEthernet1/0/2brief

MSTIDPortRoleSTPStateProtection

0GigabitEthernet1/0/2ALTEDISCARDINGNONE

1GigabitEthernet1/0/2ALTEDISCARDINGNONE

因为S9300D的端口1/0/2在CIST上为Alternate端口,又因为S9300D与S9300C不在同一个域,所以端口1/0/2在实例1中的也被选择为Alternate端口。

端口2/0/1在CIST为根端口,因为S9300D在实例1中的优先级比S9300B高,所以端口2/0/1在实例1上被作为指定端口。

配置文件

∙S9300A的配置文件

#

sysnameS9300A

#

vlanbatch2to20

#

stpinstance0priority0

stpinstance1priority0

stppathcost-standardlegacy

stpenable

stpregion-configuration

region-nameRG1

instance1vlan1to10

activeregion-configuration

#

interfaceGigabitEthernet6/0/2

portlink-typetrunk

porttrunkallow-passvlan1to20

stproot-protection

#

interfaceGigabitEthernet6/0/1

portlink-typetrunk

porttrunkallow-passvlan1to20

stproot-protection

#

return

∙S9300B的配置文件

#

sysnameS9300B

#

vlanbatch2to20

#

stpinstance0priority4096

stppathcost-standardlegacy

stpenable

stpregion-configuration

region-nameRG2

instance1vlan1to10

activeregion-configuration

#

interfaceGigabitEthernet6/0/2

portlink-typetrunk

porttrunkallow-passvlan1to20

#

interfaceGigabitEthernet6/0/1

portlink-typetrunk

porttrunkallow-passvlan1to20

#

return

∙S9300C的配置文件

#

sysnameS9300C

#

vlanbatch2to20

#

stpbpdu-protection

stppathcost-standardlegacy

stpenable

stpregion-configuration

region-nameRG1

instance1vlan1to10

activeregion-configuration

#

interfaceGigabitEthernet1/0/1

porthybridpvidvlan20

porthybriduntaggedvlan20

stpedged-portenable

#

interfaceGigabitEthernet1/0/2

portlink-typetrunk

porttrunkallow-passvlan1to20

#

interfaceGigabitEthernet2/0/1

portlink-typetrunk

porttrunkallow-passvlan1to20

#

return

∙S9300D的配置文件

#

sysnameS9300D

#

vlanbatch2to20

#

stpinstance1priority0

stpbpdu-protection

stppathcost-standardlegacy

stpenable

stpregion-configuration

region-nameRG2

instance1vlan1to10

activeregion-configuration

#

interfaceGigabitEthernet1/0/1

porthybridpvidvlan10

porthybriduntaggedvlan10

stpedged-portenable

#

interfaceGigabitEthernet1/0/2

portlink-typetrunk

porttrunkallow-passvlan1to20

#

interfaceGigabitEthernet2/0/1

portlink-typetrunk

porttrunkallow-passvlan1to20

#

Return

父主题:

配置举例

华为所有和机密

版权所有©华为技术有限公司

出师表

两汉:

诸葛亮

  先帝创业未半而中道崩殂,今天下三分,益州疲弊,此诚危急存亡之秋也。

然侍卫之臣不懈于内,忠志之士忘身于外者,盖追先帝之殊遇,欲报之于陛下也。

诚宜开张圣听,以光先帝遗德,恢弘志士之气,不宜妄自菲薄,引喻失义,以塞忠谏之路也。

  宫中府中,俱为一体;陟罚臧否,不宜异同。

若有作奸犯科及为忠善者,宜付有司论其刑赏,以昭陛下平明之理;不宜偏私,使内外异法也。

  侍中、侍郎郭攸之、费祎、董允等,此皆良实,志虑忠纯,是以先帝简拔以遗陛下:

愚以为宫中之事,事无大小,悉以咨之,然后施行,必能裨补阙漏,有所广益。

  将军向宠,性行淑均,晓畅军事,试用于昔日,先帝称之曰“能”,是以众议举宠为督:

愚以为营中之事,悉以咨之,必能使行阵和睦,优劣得所。

  亲贤臣,远小人,此先汉所以兴隆也;亲小人,远贤臣,此后汉所以倾颓也。

先帝在时,每与臣论此事,未尝不叹息痛恨于桓、灵也。

侍中、尚书、长史、参军,此悉贞良死节之臣,愿陛下亲之、信之,则汉室之隆,可计日而待也

  臣本布衣,躬耕于南阳,苟全性命于乱世,不求闻达于诸侯。

先帝不以臣卑鄙,猥自枉屈,三顾臣于草庐之中,咨臣以当世之事,由是感激,遂许先帝以驱驰。

后值倾覆,受任于败

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 工作范文 > 行政公文

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1