26. [SW2-GigabitEthernet0/0/13]port trunk allow-pass vlan 1 to 20 27. [SW2]int g0/0/14
28. [SW2-GigabitEthernet0/0/14]port link-type trunk
29. [SW2-GigabitEthernet0/0/14]port trunk allow-pass vlan 1 to 20 30. 31. SW3:
32. [SW3]vlan batch 2 to 20 33. [SW3]int g0/0/1
34. [SW3-GigabitEthernet0/0/1]port link-type trunk
35. [SW3-GigabitEthernet0/0/1]port trunk allow-pass vlan 1 to 20 36. [SW3]int g0/0/13
37. [SW3-GigabitEthernet0/0/13]port link-type trunk
38. [SW3-GigabitEthernet0/0/13]port trunk allow-pass vlan 1 to 20 39. [SW3]int g0/0/23
40. [SW3-GigabitEthernet0/0/23]port link-type trunk
41. [SW3-GigabitEthernet0/0/23]port trunk allow-pass vlan 1 to 2 42. 43. SW4:
44. [SW4]vlan batch 2 to 20 45. [SW4]int g0/0/1
46. [SW4-GigabitEthernet0/0/1]port link-type trunk
47. [SW4-GigabitEthernet0/0/1]port trunk allow-pass vlan 1 to 20 48. [SW4]int g0/0/14
49. [SW4-GigabitEthernet0/0/14]port link-type trunk
50. [SW4-GigabitEthernet0/0/14]port trunk allow-pass vlan 1 to 20 51. [SW4]int g0/0/24
52. [SW4-GigabitEthernet0/0/24]port link-type trunk
53. [SW4-GigabitEthernet0/0/24]port trunk allow-pass vlan 1 to 2
配置mstp,定义vlan1-10属于instance 1,vlan11-20属于instance 2
[plain] view plain copy
1. SW1:
2. [SW1]stp mode mstp
3. [SW1]stp region-configuration 4. [SW1-mst-region]region-name RG1
5. [SW1-mst-region]instance 1 vlan 1 to 10 6. [SW1-mst-region]instance 2 vlan 11 to 20 7. [SW1-mst-region]active region-configuration 8. SW2:
9. [SW2]stp mode mstp
10. [SW2]stp region-configuration 11. [SW2-mst-region]region-name RG1
12. [SW2-mst-region]instance 1 vlan 1 to 10 13. [SW2-mst-region]instance 2 vlan 11 to 20 14. [SW2-mst-region]active region-configuration 15. SW3:
16. [SW3]stp mode mstp
17. [SW3]stp region-configuration 18. [SW3-mst-region]region-name RG1
19. [SW3-mst-region]instance 1 vlan 1 to 10 20. [SW3-mst-region]instance 2 vlan 11 to 20 21. [SW3-mst-region]active region-configuration 22. SW4:
23. [SW4]stp mode mstp
24. [SW4]stp region-configuration 25. [SW4-mst-region]region-name RG1
26. [SW4-mst-region]instance 1 vlan 1 to 10 27. [SW4-mst-region]instance 2 vlan 11 to 20 28. [SW4-mst-region]active region-configuration
查看mstp实例配置
配置vlan负载
[plain] view plain copy
1. SW1:
2. [SW1]stp instance 1 priority 4096 3. [SW1]stp instance 2 priority 8192 4. 5. SW2:
6. [SW2]stp instance 1 priority 8192 7. [SW2]stp instance 2 priority 4096
查看mstp实例状态信息,SW1为实例1的根桥,SW2为实例2的根桥。