其他分享
首页 > 其他分享> > 配置交换机Trunk接口流量本地优先转发(集群/堆叠)

配置交换机Trunk接口流量本地优先转发(集群/堆叠)

作者:互联网

组网图形

Eth-Trunk接口流量本地优先转发简介

配置注意事项

组网需求

配置思路

操作步骤

  # 配置集群/堆叠交换机CSS。

<HUAWEI> system-view
[HUAWEI] sysname CSS
[CSS] interface eth-trunk 10 //创建并进入Eth-Trunk10接口。
[CSS-Eth-Trunk10] port link-type trunk  //配置接口类型为Trunk。
[CSS-Eth-Trunk10] port trunk allow-pass vlan all //配置接口允许通过所有VLAN。
[CSS-Eth-Trunk10] quit

   # 配置汇聚交换机PE。

<HUAWEI> system-view
[HUAWEI] sysname PE
[PE] interface eth-trunk 10 //创建并进入Eth-Trunk10接口。
[PE-Eth-Trunk10] port link-type trunk //配置接口类型为Trunk。
[PE-Eth-Trunk10] port trunk allow-pass vlan all //配置接口允许通过所有VLAN。
[PE-Eth-Trunk10] quit

  # 配置集群/堆叠交换机CSS。

[CSS] interface gigabitethernet 1/1/0/4
[CSS-GigabitEthernet1/1/0/4] eth-trunk 10 //将接口GE1/1/0/4加入到Eth-Trunk10中。
[CSS-GigabitEthernet1/1/0/4] quit
[CSS] interface gigabitethernet 2/1/0/4
[CSS-GigabitEthernet2/1/0/4] eth-trunk 10 //将接口GE2/1/0/4加入到Eth-Trunk10中。
[CSS-GigabitEthernet2/1/0/4] quit

   # 配置汇聚交换机PE。

[PE] interface gigabitethernet 1/0/1
[PE-GigabitEthernet1/0/1] eth-trunk 10 //将接口GE1/0/1加入到Eth-Trunk10中。
[PE-GigabitEthernet1/0/1] quit
[PE] interface gigabitethernet 1/0/2 
[PE-GigabitEthernet1/0/2] eth-trunk 10 //将接口GE1/0/2加入到Eth-Trunk10中。
[PE-GigabitEthernet1/0/2] quit
[CSS] interface eth-trunk 10
[CSS-Eth-Trunk10] local-preference enable //使能Eth-Trunk10接口流量本地优先转发功能。
[CSS-Eth-Trunk10] quit

  # 配置集群/堆叠CSS。

[CSS] vlan batch 2 3
[CSS] interface gigabitethernet 1/1/0/3
[CSS-GigabitEthernet1/1/0/3] port link-type trunk
[CSS-GigabitEthernet1/1/0/3] port trunk allow-pass vlan 2
[CSS-GigabitEthernet1/1/0/3] quit
[CSS] interface gigabitethernet 2/1/0/3
[CSS-GigabitEthernet2/1/0/3] port link-type trunk
[CSS-GigabitEthernet2/1/0/3] port trunk allow-pass vlan 3
[CSS-GigabitEthernet2/1/0/3] quit

   # 配置接入交换机Switch1。

<HUAWEI> system-view
[HUAWEI] sysname Switch1
[Switch1] vlan 2
[Switch1-vlan2] quit
[Switch1] interface gigabitethernet 1/0/1
[Switch1-GigabitEthernet1/0/1] port link-type trunk
[Switch1-GigabitEthernet1/0/1] port trunk allow-pass vlan 2
[Switch1-GigabitEthernet1/0/1] quit
[Switch1] interface gigabitethernet 1/0/2
[Switch1-GigabitEthernet1/0/2] port link-type trunk
[Switch1-GigabitEthernet1/0/2] port trunk allow-pass vlan 2
[Switch1-GigabitEthernet1/0/2] quit

   # 配置接入交换机Switch2。

<HUAWEI> system-view
[HUAWEI] sysname Switch2
[Switch2] vlan 3
[Switch2-vlan3] quit
[Switch2] interface gigabitethernet 1/0/1
[Switch2-GigabitEthernet1/0/1] port link-type trunk
[Switch2-GigabitEthernet1/0/1] port trunk allow-pass vlan 3
[Switch2-GigabitEthernet1/0/1] quit
[Switch2] interface gigabitethernet 1/0/2
[Switch2-GigabitEthernet1/0/2] port link-type trunk
[Switch2-GigabitEthernet1/0/2] port trunk allow-pass vlan 3
[Switch2-GigabitEthernet1/0/2] quit

  上述配置成功后,在任意视图下执行命令display trunkmembership eth-trunk,可以看到Eth-Trunk接口的成员口信息。例如:
  以集群/堆叠交换机CSS的显示为例。

<CSS> display trunkmembership eth-trunk 10
Trunk ID: 10
Used status: VALID
TYPE: ethernet
Working Mode : Normal
Number Of Ports in Trunk = 2
Number Of Up Ports in Trunk = 2
Operate status: up

Interface GigabitEthernet1/1/0/4, valid, operate up, weight=1
Interface GigabitEthernet2/1/0/4, valid, operate up, weight=1

 

标签:Trunk,GigabitEthernet1,接口,堆叠,交换机,trunk,Eth,CSS
来源: https://www.cnblogs.com/zhangwencheng/p/13947460.html