• 产品与解决方案
  • 行业解决方案
  • 服务
  • 支持
  • 合作伙伴
  • 新华三人才研学中心
  • 关于我们

H3C SR6600 SR6600-X系列路由器 典型配置案例集-R8128-6W101

06-H3C SR6600_SR6600-X路由器 以太网链路聚合典型配置举例

本章节下载  (276.78 KB)

docurl=/cn/Service/Document_Software/Document_Center/Home/Routers/00-Public/Configure/Typical_Configuration_Example/H3C_SR6600_SR6600-X_CE(V7)-R7607-2683/202208/1674298_30005_0.htm

06-H3C SR6600_SR6600-X路由器 以太网链路聚合典型配置举例

H3C SR6600/SR6600-X系列路由器

以太网链路聚合配置举例

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Copyright © 2022 新华三技术有限公司 版权所有,保留一切权利。

非经本公司书面许可,任何单位和个人不得擅自摘抄、复制本文档内容的部分或全部,并不得以任何形式传播。

除新华三技术有限公司的商标外,本手册中出现的其它公司的商标、产品标识及商品名称,由各自权利人拥有。

本文档中的信息可能变动,恕不另行通知。



1  简介

本文档介绍以太网链路聚合特性的配置举例。

2  配置前提

本文档中的配置均是在实验室环境下进行的配置和验证,配置前设备的所有参数均采用出厂时的缺省配置。如果您已经对设备进行了配置,为了保证配置效果,请确认现有配置和以下举例中的配置不冲突。

本文档假设您已了解以太网链路聚合特性。

3  三层链路聚合配置举例

3.1  组网需求

图1所示,Device A与Device B通过以太网链路互连。要求在Device A和Device B上分别配置三层链路聚合组,并为对应的三层聚合接口配置IP地址和子网掩码,从而提高两设备之间的带宽与可靠性。

图1  三层聚合配置示例图

 

3.2  使用版本

本举例是在R8128版本上进行配置和验证的。

3.3  配置注意事项

链路聚合分为静态聚合和动态聚合两种模式,用户可根据这两种模式的特点,结合具体组网情况选择其中一种进行配置。

·     静态聚合组在完成配置后,端口的选中/非选中状态不受网络环境的影响,比较稳定,但不能根据对端的状态调整成员端口的选中/非选中状态。

·     动态聚合组能够根据对端和本端的信息调整端口的选中/非选中状态,比较灵活,但其成员端口的选中/非选中状态容易受网络环境的影响。

3.4  配置步骤

3.4.1  Device A的配置

# 创建三层聚合接口1。(根据具体情况选择下面两种方式之一)

·     采用静态聚合模式

<DeviceA> system-view

[DeviceA] interface route-aggregation 1

·     采用动态聚合模式

<DeviceA> system-view

[DeviceA] interface route-aggregation 1

[DeviceA-Route-Aggregation1] link-aggregation mode dynamic

# 为三层聚合接口1配置IP地址和子网掩码。

[DeviceA-Route-Aggregation1] ip address 192.168.1.1 24

[DeviceA-Route-Aggregation1] quit

# 将接口GigabitEthernet1/0/1~GigabitEthernet1/0/3加入聚合组1

[DeviceA] interface range gigabitethernet 1/0/1 to gigabitethernet 1/0/3

[DeviceA-if-range] port link-aggregation group 1

[DeviceA-if-range] quit

3.4.2  Device B的配置

Device B上的配置与Device A相同,配置过程略。

3.5  验证配置

# 通过display link-aggregation verbose命令来显示聚合组的相关信息,以验证配置是否成功。

·     采用静态聚合模式的聚合组信息

[DeviceA] display link-aggregation verbose

Loadsharing Type: Shar -- Loadsharing, NonS -- Non-Loadsharing

Port Status: S -- Selected, U -- Unselected, I -- Individual

Flags:  A -- LACP_Activity, B -- LACP_Timeout, C -- Aggregation,

        D -- Synchronization, E -- Collecting, F -- Distributing,

        G -- Defaulted, H -- Expired

 

Aggregate Interface: Route-Aggregation1

Aggregation Mode: Static

Loadsharing Type: Shar

  Port             Status  Priority Oper-Key

--------------------------------------------------------------------------------

  GE1/0/1          S       32768    1

  GE1/0/2          S       32768    1

  GE1/0/3          S       32768    1

结果说明:本端加入到静态聚合组内的成员端口都处于Selected状态,与对端对应端口是否是Selected状态无关。

·     采用动态聚合模式的聚合组信息

[DeviceA] display link-aggregation verbose

Loadsharing Type: Shar -- Loadsharing, NonS -- Non-Loadsharing

Port Status: S -- Selected, U -- Unselected, I -- Individual

Flags:  A -- LACP_Activity, B -- LACP_Timeout, C -- Aggregation,

        D -- Synchronization, E -- Collecting, F -- Distributing,

        G -- Defaulted, H -- Expired

 

Aggregate Interface: Route-Aggregation1

Aggregation Mode: Dynamic

Loadsharing Type: Shar

System ID: 0x8000, 000f-e267-6c6a

Local:

  Port             Status  Priority Oper-Key  Flag

--------------------------------------------------------------------------------

  GE1/0/1          S       32768    1         {ACDEF}

  GE1/0/2          S       32768    1         {ACDEF}

  GE1/0/3          S       32768    1         {ACDEF}

Remote:

  Actor            Partner Priority Oper-Key  SystemID               Flag

--------------------------------------------------------------------------------

  GE1/0/1          1       32768    1         0x8000, 000f-e267-57ad {ACDEF}

  GE1/0/2          2       32768    1         0x8000, 000f-e267-57ad {ACDEF}

  GE1/0/3          3       32768    1         0x8000, 000f-e267-57ad {ACDEF}

结果说明:本端和对端设备上聚合组内的成员端口都处于Selected状态。原因是在动态链路聚合中通过LACP协议报文交互,可使两端聚合组内的成员端口选中状态达成一致,可顺利实现对用户数据的转发。

3.6  配置文件

·     Device A:

#

¡     采用静态聚合模式

#

interface route-aggregation1

 ip address 192.168.1.1 255.255.255.0

#

¡     采用动态聚合模式

#

interface route-aggregation1

 ip address 192.168.1.1 255.255.255.0

 link-aggregation mode dynamic

#

interface GigabitEthernet1/0/1

 port link-mode route

port link-aggregation group 1

#

interface GigabitEthernet1/0/2

 port link-mode route

port link-aggregation group 1

#

interface GigabitEthernet1/0/3

 port link-mode route

port link-aggregation group 1

#

·     Device B:

Device B上的配置文件与Device A类似。

4  三层聚合负载分担配置举例

4.1  组网需求

图2所示:

·     Device A与Device B通过各自的三层以太网接口GigabitEthernet1/0/1~GigabitEthernet1/0/4相互连接。

·     在Device A和Device B上分别配置两个三层静态链路聚合组,并为对应的三层聚合接口都配置IP地址和子网掩码。

·     通过在聚合组1上按照源IP地址进行聚合负载分担、在聚合组2上按照目的IP地址进行聚合负载分担的方式,来实现数据流量在各成员端口间的负载分担。

图2 三层聚合负载分担配置组网图

 

4.2  使用版本

本举例是在R8128版本上进行配置和验证的。

4.3  配置注意事项

聚合负载分担类型支持全局配置或在聚合组内配置两种方式;对于一个聚合组来说,优先采用该聚合组内的配置。本例在聚合组内配置。

4.4  配置步骤

4.4.1  Device A的配置

# 创建三层聚合接口1,配置该接口对应的聚合组内按照源IP地址进行聚合负载分担,并为其配置IP地址和子网掩码。

<DeviceA> system-view

[DeviceA] interface route-aggregation 1

[DeviceA-Route-Aggregation1] link-aggregation load-sharing mode source-ip

[DeviceA-Route-Aggregation1] ip address 192.168.1.1 24

[DeviceA-Route-Aggregation1] quit

# 创建三层聚合接口2,配置该接口对应的聚合组内按照目的IP地址进行聚合负载分担,并为其配置IP地址和子网掩码。

[DeviceA] interface route-aggregation 2

[DeviceA-Route-Aggregation2] link-aggregation load-sharing mode destination-ip

[DeviceA-Route-Aggregation2] ip address 192.168.2.1 24

[DeviceA-Route-Aggregation2] quit

# 将接口GigabitEthernet1/0/1和GigabitEthernet1/0/2加入聚合组1,接口GigabitEthernet1/0/3和GigabitEthernet1/0/4加入聚合组2

[DeviceA] interface range gigabitethernet 1/0/1 gigabitethernet 1/0/2

[DeviceA-if-range] port link-aggregation group 1

[DeviceA-if-range] quit

[DeviceA] interface range gigabitethernet 1/0/3 gigabitethernet 1/0/4

[DeviceA-if-range] port link-aggregation group 2

[DeviceA-if-range] quit

4.4.2  Device B的配置

Device B的配置与Device A相同,配置过程略。

4.5  验证配置

# 查看Device A上所有聚合组的详细信息。

[DeviceA] display link-aggregation verbose

Loadsharing Type: Shar -- Loadsharing, NonS -- Non-Loadsharing

Port Status: S -- Selected, U -- Unselected, I -- Individual

Flags:  A -- LACP_Activity, B -- LACP_Timeout, C -- Aggregation,

        D -- Synchronization, E -- Collecting, F -- Distributing,

        G -- Defaulted, H -- Expired

 

Aggregate Interface: Route-Aggregation1

Aggregation Mode: Static

Loadsharing Type: Shar

  Port             Status  Priority Oper-Key

--------------------------------------------------------------------------------

  GE1/0/1          S       32768    1

  GE1/0/2          S       32768    1

 

Aggregate Interface: Route-Aggregation2

Aggregation Mode: Static

Loadsharing Type: Shar

  Port             Status  Priority Oper-Key

--------------------------------------------------------------------------------

  GE1/0/3          S       32768    2

  GE1/0/4          S       32768    2

以上信息表明,聚合组1和聚合组2都是负载分担类型的三层静态聚合组,各包含有两个选中端口。

# 查看Device A上所有聚合接口所对应聚合组内采用的聚合负载分担类型。

[DeviceA] display link-aggregation load-sharing mode interface

Route-Aggregation1 Load-Sharing Mode:

source-ip address

 

Route-Aggregation2 Load-Sharing Mode:

destination-ip address

以上信息表明,三层聚合组1按照报文的源IP地址进行聚合负载分担,三层聚合组2按照报文的目的IP地址进行聚合负载分担。

4.6  配置文件

·     Device A:

#

interface Route-Aggregation1

 ip address 192.168.1.1 255.255.255.0

 link-aggregation load-sharing mode source-ip

#

interface Route-Aggregation2

 ip address 192.168.2.1 255.255.255.0

 link-aggregation load-sharing mode destination-ip

#

interface GigabitEthernet1/0/1

 port link-mode route

 port link-aggregation group 1

#

interface GigabitEthernet1/0/2

 port link-mode route

 port link-aggregation group 1

#

interface GigabitEthernet1/0/3

 port link-mode route

 port link-aggregation group 2

#

interface GigabitEthernet1/0/4

 port link-mode route

 port link-aggregation group 2

#

·     Device B:

Device B上的配置文件与Device A类似。

5  端口聚合与Cisco互通配置举例

5.1  组网需求

图3所示:

·     两个楼宇之间分别使用H3C Device A(简称Device A)与Cisco Device B(简称Device B)通过各自的三层以太网接口相互连接。

·     为提高设备间链路带宽与可靠性,并考虑不同厂商设备互联的兼容性,配置动态链路聚合,在Device A和Device B上分别配置三层链路聚合组,并为对应的三层聚合接口配置IP地址和子网掩码。

图3 三层链路聚合配置示例

 

 

5.2  配置思路

·     Device A:创建三层聚合接口,配置该接口为动态聚合模式。将端口加入到聚合接口中。

·     Device B:创建通道组,配置封装协议为LACP,并配置LACP工作模式为主动(Active)。

5.3  使用版本

本举例是在R8128版本上进行配置和验证的。

5.4  配置注意事项

·     由于静态聚合组中端口选中状态不受对端端口是否在聚合组中及是否处于选中状态的影响。这样有可能导致两端设备所确定的Selected状态端口不一致,当两端都支持配置静态和动态聚合组的情况下,建议用户优选动态聚合组。

·     对于Cisco设备,需配置通道组为LACP协议,并将通道组类型配置为Active。关于更多通道组端口状态请查阅Cisco相关资料。

5.5  配置步骤

5.5.1  Device A的配置

# 创建三层聚合接口1,并采用动态聚合模式。

<DeviceA> system

[DeviceA] interface route-aggregation 1

[DeviceA-Route-Aggregation1] link-aggregation mode dynamic

# 为三层聚合接口1配置IP地址和子网掩码。

[DeviceA-Route-Aggregation1] ip address 192.168.1.1 24

[DeviceA-Route-Aggregation1] quit

# 将接口GigabitEthernet1/0/1~GigabitEthernet1/0/3加入聚合组1

[DeviceA] interface range gigabitethernet 1/0/1 to gigabitethernet 1/0/3

[DeviceA-if-range] port link-aggregation group 1

[DeviceA-if-range] quit

5.5.2  Device B的配置

# 为端口通道接口1配置IP地址和子网掩码。

DeviceB>enable

DeviceB#configure terminal

DeviceB(config)#interface port-channel 1

DeviceB(config-if)#ip address 192.168.1.2 255.255.255.0

# 将通道协议模式配置为LACP(缺省为PagP模式)。

DeviceB(config-if)#channel-protocol lacp

DeviceB(config-if)#exit

# 进入以太网接口视图。

DeviceB(config)#interface range gigabitethernet 1/1 – 3

#将端口批量加入通道组。

DeviceB(config-if-range)#no switchport

DeviceB(config-if-range)#channel-group 1 mode active

DeviceB(config-if-range)#exit

5.6  验证配置

(1)     Device A

# 通过display link-aggregation verbose命令来显示聚合组的相关信息,以验证配置是否成功。

 [DeviceA] display link-aggregation verbose

Loadsharing Type: Shar -- Loadsharing, NonS -- Non-Loadsharing

Port Status: S -- Selected, U -- Unselected, I -- Individual

Flags:  A -- LACP_Activity, B -- LACP_Timeout, C -- Aggregation,

        D -- Synchronization, E -- Collecting, F -- Distributing,

        G -- Defaulted, H -- Expired

 

Aggregate Interface: Route-Aggregation1

Aggregation Mode: Dynamic

Loadsharing Type: Shar

System ID: 0x8000, 000f-e267-6c6a

Local:

  Port             Status  Priority Oper-Key  Flag

--------------------------------------------------------------------------------

  GE1/0/1          S       32768    1         {ACDEF}

  GE1/0/2          S       32768    1         {ACDEF}

  GE1/0/3          S       32768    1         {ACDEF}

Remote:

  Actor            Partner Priority Oper-Key  SystemID               Flag

--------------------------------------------------------------------------------

  GE1/0/1          1       32768    1         0x8000, 000f-e267-57ad {ACDEF}

  GE1/0/2          2       32768    1         0x8000, 000f-e267-57ad {ACDEF}

  GE1/0/3          3       32768    1         0x8000, 000f-e267-57ad {ACDEF}

结果说明:本端和对端设备上聚合组内的成员端口都处于Selected状态。原因是在动态链路聚合中通过LACP协议报文交互,可使两端聚合组内的成员端口选中状态达成一致,可顺利实现对用户数据的转发。

(2)     Device B

# 通过show etherchannel summary show etherchannel port-channel命令来显示端口聚合的简要信息,以验证配置是否成功。

DeviceB#show etherchannel summary

Flags:  D - down        P - in port-channel

        I - stand-alone s - suspended

        H - Hot-standby (LACP only)

        R - Layer3      S - Layer2

        U - in use      f - failed to allocate aggregator

        u - unsuitable for bundling

        w - waiting to be aggregated

        d - default port

 

 

Number of channel-groups in use: 1

Number of aggregators:           1

 

Group  Port-channel  Protocol    Ports

------+-------------+-----------+----------------------------------------------

 

1      Po1(SU)           LACP   Gi1/1(P) Gi1/2(P) Gi1/3(P)

DeviceB#show etherchannel port-channel

                Channel-group listing:

                ----------------------

 

Group: 1

----------

                Port-channels in the group:

                ---------------------------

 

Port-channel: Po1    (Primary Aggregator)

------------

 

Age of the Port-channel   = 00d:00h:26m:35s

Logical slot/port   = 2/1       Number of ports = 3

GC                  = 0x00000000      HotStandBy port = null

Port state          = Port-channel

Protocol            =   LACP

Port Security       = Disabled

 

Ports in the Port-channel:

 

Index   Load   Port     EC state        No of bits

------+------+------+------------------+-----------

  0     00     Gi1/1    Active             0

  0     00     Gi1/2    Active             0

  0     00     Gi1/3    Active             0

Time since last port bundled:    00d:00h:12m:13s    Gi0/2

5.7  配置文件

·     Device A:

#

interface route-aggregation1

 ip address 192.168.1.1 255.255.255.0

 link-aggregation mode dynamic

#

interface GigabitEthernet1/0/1

 port link-mode route

port link-aggregation group 1

#

interface GigabitEthernet1/0/2

 port link-mode route

port link-aggregation group 1

#

interface GigabitEthernet1/0/3

 port link-mode route

port link-aggregation group 1

#

·     Device B:

Building configuration...

 

Current configuration : 1444 bytes

!

version 12.2

no service timestamps log datetime msec

no service timestamps debug datetime msec

no service password-encryption

!

hostname Switch

!

!

!

!

!

!

!

!

interface GigabitEthernet1/1

 no switchport

 channel-protocol lacp

 channel-group 1 mode active

!

interface GigabitEthernet1/2

 no switchport

 channel-protocol lacp

 channel-group 1 mode active

!

interface GigabitEthernet1/3

 no switchport

 channel-group 1 mode active

!

interface Port-channel 1

 no switchport

 channel-protocol lacp

 ip address 192.168.1.2 255.255.255.0

6  相关资料

·     H3C SR6600 SR6600-X 路由器 二层技术-以太网交换配置指导-R7607

·     H3C SR6600 SR6600-X 路由器 二层技术-以太网交换命令参考-R7607

不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!

新华三官网
联系我们