MSTP配置示例

        多生成树可以实现链路的防环、冗余备份、负载均衡功能

拓朴如下:

MSTP配置示例_第1张图片

主要配置如下:
[R1]
interface GigabitEthernet0/0/1
 ip address 10.1.1.254 255.255.255.0 
#
interface GigabitEthernet0/0/2
 ip address 10.2.2.254 255.255.255.0 
#

[S1]
interface GigabitEthernet0/0/23
 port link-type trunk
 port trunk allow-pass vlan 10 20
#
interface GigabitEthernet0/0/24
 port link-type trunk
 port trunk allow-pass vlan 10 20
#

[S2]
stp instance 1 root primary
stp instance 2 root secondary
#
stp region-configuration
 region-name 12
 revision-level 5
 instance 1 vlan 10
 instance 2 vlan 20
 active region-configuration
#

[S3]
stp instance 1 root secondary
stp instance 2 root primary
#
interface GigabitEthernet0/0/22
 port link-type trunk
 port trunk allow-pass vlan 10 20
#
interface GigabitEthernet0/0/23
#
interface GigabitEthernet0/0/24
 port link-type trunk
 port trunk allow-pass vlan 10 20
#

查证:

        可以看到:S2是实例1,也就是vlan 10的根桥,S2是实例2,vlan 20的根桥,S1上实例1和实例2,两个端口的角色分别为实例2和实例1的Alter角色,起到了负载均衡的作用,如果一根链路down掉后,另外一根链路起到了备份链路的作用。

你可能感兴趣的:(数通,运维,网络,运维,华为)