In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >
Share
Shulou(Shulou.com)06/01 Report--
Configure MST to achieve load balancing
1. Experimental topology:
(Huawei eNSP Simulator)
2. Requirements of the experimental environment:
1. VLAN planning is shown in the figure.
2. Link bundling between SW1 and SW2
3. Configure MST to achieve load balancing
3. Configuration files and steps:
1. Configuration of SW1
Configure Ethernet Channel
Sy
[Huawei] sysname SW1
[SW1] vlan batch 1 to 4 / / batch create vlan 1 to 4
[SW1] int Eth-Trunk 1 / / create layer 2 Eth-Trunk interface
[SW1-Eth-Trunk1] q
[SW1] int Ethernet 0/0/1
[SW1-Ethernet0/0/1] eth-trunk 1 / / add the interface to eth-trunk 1
[SW1-Ethernet0/0/1] q
[SW1] int Ethernet 0/0/2
[SW1-Ethernet0/0/2] eth-trunk 1
[SW1] dis eth-trunk 1
[SW1] int Eth-Trunk 1
[SW1-Eth-Trunk1] port link-type trunk / / set Eth-Trunk1 to trunk type
[SW1-Eth-Trunk1] port trunk allow-pass vlan all / / allow all VLAN traffic to pass through
[SW1-Eth-Trunk1] int e0/0/3
[SW1-Ethernet0/0/3] port link-type trunk
[SW1-Ethernet0/0/3] port trunk allow-pass vlan all
Dis vlan
Configure mstp
[SW1] stp mode mstp / / sets the working mode of the switch to mstp
[SW1] stp region-configuration / / enter the MST domain configuration is fine
[SW1-mst-region] region-name test / / configure the domain name of the MST domain to be test
[SW1-mst-region] instance 1 vlan 1 to 2 / / configure the mapping between multiple spanning tree instances and VLAN. Instance 1 corresponds to VLAN1 to 2
[SW1-mst-region] instance 2 vlan 3 to 4
[SW1-mst-region] active region-configuration / / activate the configuration of MST domain
[SW1-mst-region] q
[SW1] stp instance 1 root primary / / configuration SW1 is the root bridge of instance 1
[SW1] stp instance 2 root secondary / / configuration SW1 is the backup root bridge of instance 2
Or [SW1] stp instance 1 priority0
[SW2] stp instance 2 priority 0
Or [SW1] stp instance 2 priority4096
[SW2] stpinstance 1 priority 4096
[SW1] stp enable / / enable the mstp function of the switch
[SW1] int Eth-Trunk 1
[SW1-Eth-Trunk1] stp enable / / enable the mstp function of the switch port
[SW1-Eth-Trunk1] stp root-protection / / enable Root Guard
[SW1-Eth-Trunk1] int e0/0/3
[SW1-Ethernet0/0/3] stp enable
[SW1-Ethernet0/0/3] stp root-protecti
2. Configuration of SW2
Configure Ethernet Channel
Sy
[Huawei] sysname SW2
[SW2] int Eth-Trunk 1
[SW2-Eth-Trunk1] q
[SW2] int Ethernet 0/0/1
[SW2-Ethernet0/0/1] eth-trunk 1
[SW2] int Ethernet 0/0/2
[SW2-Ethernet0/0/2] eth-trunk 1
[SW2] dis eth-trunk 1
[SW2] vlan batch 1 to 4
[SW2] int Eth-Trunk 1
[SW2-Eth-Trunk1] port link-type trunk
[SW2-Eth-Trunk1] port trunk allow-pass vlan all
[SW2-Eth-Trunk1] int e0/0/3
[SW2-Ethernet0/0/3] port link-type trunk
[SW2-Ethernet0/0/3] port trunk allow-pass vlan all
Dis vlan
Configure mstp
[SW2] stpmode mstp
[SW2] stp region-configuration
[SW2-mst-region] region-nametest
[SW2-mst-region] instance 1vlan 1 to 2
[SW2-mst-region] instance 2vlan 3 to 4
[SW2-mst-region] activeregion-configuration
[SW2-mst-region] q
[SW2] stp instance 2 rootprimary
[SW2] stp instance 1 rootsecondary
[SW2] stp enable
[SW2] int Eth-Trunk 1
[SW2-Eth-Trunk1] stp enable
[SW2-Eth-Trunk1] stp root-protection
[SW2-Eth-Trunk1] int e0/0/3
[SW2-Ethernet0/0/3] stp enable
[SW2-Ethernet0/0/3] stproot-protection
3. Configuration of SW3
Configure Ethernet Channel
Sy
[Huawei] sysname SW3
[SW3] vlan batch 1 to 4
[SW3] int e0/0/1
[SW3-Ethernet0/0/1] port link-type trunk
[SW3-Ethernet0/0/1] port trunk allow-pass vlan all
[SW3-Ethernet0/0/1] int e0/0/2
[SW3-Ethernet0/0/2] port link-type trunk
[SW3-Ethernet0/0/2] port trunk allow-pass vlan all
Dis vlan
Configure mstp
[SW3] stp mode mstp
[SW3] stp region-configuration
[SW3-mst-region] region-name test
[SW3-mst-region] instance 1 vlan 1 to 2
[SW3-mst-region] instance 2 vlan 3 to 4
[SW3-mst-region] active region-configuration
[SW3] stp enable
[SW3] int e0/0/1
[SW3-Ethernet0/0/1] stp enable
[SW3-Ethernet0/0/1] int e0/0/2
[SW3-Ethernet0/0/2] stp enable
4. Verification of the results:
[SW1] dis stp brief / / View port status and port protection type
From the figure above, we can see that SW1 is the root bridge of instance 1, namely VLAN1 and 2, and Eth-Trunk1 and Ethernet0/0/3 are both designated ports; in instance 2, VLAN3 and 4, it is non-root bridge, Eth-Trunk1 is the root port, and Ethernet0/0/3 is the designated port.
[SW2] dis stp brief
From the figure above, we can see that SW2 is the root bridge of instance 2, and Eth-Trunk1 and Ethernet0/0/3 are both designated ports; in instance 1, it is non-root bridge, Eth-Trunk1 is the root port, and Ethernet0/0/3 is the designated port.
[SW3] dis stp brief
From the above figure, we can see that SW3 is neither the root bridge of instance 1 nor the root bridge of instance 2. In instance 1, Ethernet0/0/1 is the root port and Ethernet0/0/2 is the blocking port. In instance 2, Ethernet0/0/2 is the root port and Ethernet0/0/1 is the blocking port.
Conclusion:
RSTP and MSTP
RSTP: all VLAN in the local area network share a spanning tree, so it is impossible to achieve load balancing of data traffic among VLAN. When the link is blocked, it will not carry any traffic, resulting in a waste of bandwidth and possibly causing some VLAN messages not to be forwarded.
MSTP: you can generate a spanning tree for each VLAN. Different VLAN forwards traffic through different spanning tree. Each spanning tree is independent of each other and does not affect each other. Load balancing can be realized among VLAN.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.