Eth-trunk : LACP模式链路聚合实战

需求描述

  • PC1和PC3数据vlan10 ,网段为192.168.10.0 /24
  • PC2和PC4数据vlan20 ,网段为192.168.20.0 /24
  • 确保设备之间互联互通,使用最大互联带宽并没有环路
  • 确保相同网段的PC可以互通
  • 判断交换机之间的每个端口的角色和状态

拓扑图

配置思路

  • 配置终端设备

    • 配置PC机的IP地址参数
  • 配置网络设备
    • 先初始化
    • 创建vlan
    • 将接口加入vlan并设置端口模式access
    • eth-trunk
      • 创建eth-trunk的端口
      • 设置eth-trunk模式
      • 添加接口成员
      • 设备端口trunk并允许所有vlan通过

配置命令

二层交换机配置 s3 s4 s5 s6

  • s3
 1. S3交换机的初始配置<Huawei>u  t  m       \\关闭信息干扰<Huawei>system-view   \\进入系统视图[Huawei]sysname  S3     \\设置交换机的名字为S3
2. S3创建vlan 10 20[S3]vlan  batch  10  20    \\创建vlan 10  20
3. S3将e0/0/1加入vlan10 并设置链路是access链路[S3]int e0/0/1   [\\进入接口0/0](file:///\\\\进入接口0/0)/1[S3-Ethernet0/0/1]port link-type access    \\设置链路为接入链路(access链路)[S3-Ethernet0/0/1]port default  vlan  10   [\\将接口加入vlan10](\\\\将接口加入vlan10)
4. 创建链路聚合接口eth-trunk 1 并将设置模式为lacp、加入成员并设置链路为tunk并允许所有vlan通过[S3]interface  Eth-Trunk 1        \\[创建链路聚合的端口1](file:///\\\\创建链路聚合的端口1)[S3-Eth-Trunk1]mode lacp-static    \\设置链路为动态lacp[S3-Eth-Trunk1]trunkport e0/0/3    \\将接口加入到负载模式[S3-Eth-Trunk1]trunkport e0/0/4      [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S3-Eth-Trunk1]port link-type trunk  \\设置为trunk链路[S3-Eth-Trunk1] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S3-Eth-Trunk1]display eth-trunk 1       \\查看 eth-trunk
  • s4
 1. S4交换机的初始配置<Huawei>u  t  m       \\关闭信息干扰<Huawei>system-view   \\进入系统视图[Huawei]sysname  S4     \\设置交换机的名字为S4
2. S4创建vlan 10 20[S4]vlan  batch  10  20    \\创建vlan 10  20
3. S4将e0/0/1加入vlan10 并设置链路是access链路[S4]int e0/0/1   [\\进入接口0/0](file:///\\\\进入接口0/0)/1[S4-Ethernet0/0/1]port link-type access    \\设置链路为接入链路(access链路)[S4-Ethernet0/0/1]port default  vlan  20   \\将接口加入vlan20
4. 创建链路聚合接口eth-trunk 1 并将设置模式为lacp、加入成员并设置链路为tunk并允许所有vlan通过[S4]interface  Eth-Trunk 2        \\[创建链路聚合的端口2](file:///\\\\创建链路聚合的端口1)[S4-Eth-Trunk2]mode lacp-static    \\设置链路为动态lacp[S4-Eth-Trunk2]trunkport e0/0/5    \\将接口加入到负载模式[S4-Eth-Trunk2]trunkport e0/0/6      [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S4-Eth-Trunk2]port link-type trunk  \\设置为trunk链路[S4-Eth-Trunk2] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S4-Eth-Trunk2]display eth-trunk 1       \\查看 eth-trunk
  • s5
 1. S5交换机的初始配置<Huawei>u  t  m       \\关闭信息干扰<Huawei>system-view   \\进入系统视图[Huawei]sysname  S5     \\设置交换机的名字为S5
2. S5创建vlan 10 20[S5]vlan  batch  10  20    \\创建vlan 10  20
3. S5将e0/0/1加入vlan10 并设置链路是access链路[S5]int e0/0/1   [\\进入接口0/0](file:///\\\\进入接口0/0)/1[S5-Ethernet0/0/1]port link-type access    \\设置链路为接入链路(access链路)[S5-Ethernet0/0/1]port default  vlan  10   [\\将接口加入vlan10](\\\\将接口加入vlan10)
4. 创建链路聚合接口eth-trunk 1 并将设置模式为lacp、加入成员并设置链路为tunk并允许所有vlan通过[S5]interface  Eth-Trunk 1        \\[创建链路聚合的端口1](file:///\\\\创建链路聚合的端口1)[S5-Eth-Trunk1]mode lacp-static    \\设置链路为动态lacp[S5-Eth-Trunk1]trunkport e0/0/3    \\将接口加入到负载模式[S5-Eth-Trunk1]trunkport e0/0/4      [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S5-Eth-Trunk1]port link-type trunk  \\设置为trunk链路[S5-Eth-Trunk1] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S5-Eth-Trunk1]display eth-trunk 1       \\查看 eth-trunk
  • s6
 1. S6交换机的初始配置<Huawei>u  t  m       \\关闭信息干扰<Huawei>system-view   \\进入系统视图[Huawei]sysname  S6     \\设置交换机的名字为S6
2. S6创建vlan 10 20[S6]vlan  batch  10  20    \\创建vlan 10  20
3. S6将e0/0/1加入vlan10 并设置链路是access链路[S6]int e0/0/1   [\\进入接口0/0](file:///\\\\进入接口0/0)/1[S6-Ethernet0/0/1]port link-type access    \\设置链路为接入链路(access链路)[S6-Ethernet0/0/1]port default  vlan  20   \\将接口加入vlan20
4. 创建链路聚合接口eth-trunk 1 并将设置模式为lacp、加入成员并设置链路为tunk并允许所有vlan通过[S6]interface  Eth-Trunk 2        \\[创建链路聚合的端口2](file:///\\\\创建链路聚合的端口1)[S6-Eth-Trunk2]mode lacp-static    \\设置链路为动态lacp[S6-Eth-Trunk2]trunkport e0/0/5    \\将接口加入到负载模式[S6-Eth-Trunk2]trunkport e0/0/6      [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S6-Eth-Trunk2]port link-type trunk  \\设置为trunk链路[S6-Eth-Trunk2] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S6-Eth-Trunk2]display eth-trunk 1       \\查看 eth-trunk

三层交换机配置 s1 s2

  • s1
 S1交换机的初始配置<Huawei>u  t  m    \\关闭信息干扰<Huawei>system-view   \\进入系统视图[Huawei]sysname  S1     \\设置交换机的名字为S1
S1创建vlan 10 20[S1]vlan  batch  10  20         \\创建vlan 10  203.创建链路聚合接口eth-trunk 1 、2并将设置模式为lacp、加入成员并设置链路为tunk并允许所有vlan通过[S1]interface  Eth-Trunk 1        \\[创建链路聚合的端口1](file:///\\\\创建链路聚合的端口1)[S1-Eth-Trunk1]mode lacp-static    \\设置链路为动态lacp[S1-Eth-Trunk1]trunkport g0/0/3    \\将接口加入到负载模式[S1-Eth-Trunk1]trunkport g0/0/4        [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S1-Eth-Trunk1]port link-type trunk  \\设置为trunk链路[S1-Eth-Trunk1] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S1]interface  Eth-Trunk 2        \\[创建链路聚合的端口2](file:///\\\\创建链路聚合的端口1)[S1-Eth-Trunk2]mode lacp-static    \\设置链路为动态lacp[S1-Eth-Trunk2]trunkport g0/0/5    \\将接口加入到负载模式[S1-Eth-Trunk2]trunkport g0/0/6     [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S1-Eth-Trunk2]port link-type trunk  \\设置为trunk链路[S1-Eth-Trunk2] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S1]interface  Eth-Trunk 3        \\[创建链路聚合的端口3](file:///\\\\创建链路聚合的端口1)[S1-Eth-Trunk3]mode lacp-static    \\设置链路为动态lacp[S1-Eth-Trunk3]trunkport g0/0/7    \\将接口加入到负载模式[S1-Eth-Trunk3]trunkport g0/0/8    [S1-Eth-Trunk3]trunkport g0/0/9     [S1-Eth-Trunk3]port link-type trunk  \\设置为trunk链路[S1-Eth-Trunk3] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S1]display eth-trunk 1         \\查看 eth-trunk[S1]display eth-trunk 2       \\查看 eth-trunk[S1]display eth-trunk 3       \\查看 eth-trunk

[S1]display eth-trunk 1 \查看 eth-trunk

[S1]display eth-trunk 2 \查看 eth-trunk

  • s2
 <Huawei>u  t  m    \\关闭信息干扰
<Huawei>system-view   \\进入系统视图
[Huawei]sysname  S2     \\设置交换机的名字为S2
S2创建vlan 10 20
[S2]vlan  batch  10  20         \\创建vlan 10  20
创建链路聚合接口eth-trunk 1 、2并将设置模式为lacp、加入成员并设置链路为tunk并允许所有vlan通过[S2]interface  Eth-Trunk 1        \\[创建链路聚合的端口1](file:///\\\\创建链路聚合的端口1)[S2-Eth-Trunk1]mode lacp-static    \\设置链路为动态lacp[S2-Eth-Trunk1]trunkport g0/0/3    \\将接口加入到负载模式[S2-Eth-Trunk1]trunkport g0/0/4       [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S2-Eth-Trunk1]port link-type trunk  \\设置为trunk链路[S2-Eth-Trunk1] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S2-Eth-Trunk1]display eth-trunk 1       \\查看 eth-trunk[S2]interface  Eth-Trunk2        \\[创建链路聚合的端口2](file:///\\\\创建链路聚合的端口1)[S2-Eth-Trunk2]mode lacp-static    \\设置链路为动态lacp[S2-Eth-Trunk2]trunkport g0/0/5    \\将接口加入到负载模式[S2-Eth-Trunk2]trunkport g0/0/6       [\\将接口加入到负载模式](file:///\\\\将接口加入到负载模式)[S2-Eth-Trunk2]port link-type trunk  \\设置为trunk链路[S2-Eth-Trunk2] port  trunk allow-pass vlan all  [\\并允许所有vlan通过](\\\\并允许所有vlan通过)[S2-Eth-Trunk2]display eth-trunk 2        \\查看 eth-trunk[S2]interface  Eth-Trunk3        \\[创建链路聚合的端口3](file:///\\\\创建链路聚合的端口1)[S2-Eth-Trunk3]mode lacp-static    \\设置链路为动态lacp[S2-Eth-Trunk3]trunkport g0/0/7    \\将接口加入到负载模式[S2-Eth-Trunk3]trunkport g0/0/8      [S1-Eth-Trunk3]trunkport g0/0/9  [S2-Eth-Trunk3]port link-type trunk  \\设置为trunk链路[S2-Eth-Trunk3] port  trunk allow-pass vlan all  \\并允许所有vlan通过[S2-Eth-Trunk3]display eth-trunk 3         \\查看 eth-trunk

[S2-Eth-Trunk2]display eth-trunk 2 \查看 eth-trunk

[S2-Eth-Trunk3]display eth-trunk 3 \查看 eth-trunk

设置最大 链路数,及开启抢占功能

Local:本地信息 Partner:对端信息
Svstem Prioritv:32768 系统的优先级
System ID:4clf-cc4e-5 系统的mac地址
MAX Active-linknumber:8 最大的活动链路数是8条
链路数是可以进行调整的我们可以调整为2条
Number of Up Port In Trunk:0 目前有几条

S2设置他的链路为2:[S2]display eth-trunk 1        \\查看 eth-trunk[S2]int  eth-trunk 1          \\进入eth-trunk1[S2-Eth-Trunk1]max active-linknumber 2    [\\设置为2](file:///\\\\设置为2)条链路修改sw2为主设备,默认值是32768 我们可以设置为100[S2]lacp priority 100          \\设置默认值为100[S2]display eth-trunk  1        \\查看 eth-trunk配置启用抢占模式 S1  S2都需要开启[S2]display eth-trunk 3                   \\查看 eth-trunk[S2-Eth-Trunk1]lacp preempt enable    [\\配置抢占模式](file:///\\\\配置抢占模式)[S1]display eth-trunk 3                \\查看 eth-trunk[S1-Eth-Trunk1]lacp preempt enable        [\\配置抢占模式](file:///\\\\配置抢占模式)Preempt Delay Time:30  当前抢占功能已开启 30秒后抢

[S2]display eth-trunk \查看 eth-trunk


总结:

 1、进入eth-trunk 视图interface eth-trunk 1 设置模式mode lacp-static添加链路trunkport g0/0/1设置端口模式port link-type trunk port trunk allow-pass vlan all设置最大链路数max-active-linknumber 2 开启抢占模式lacp preempt enable 设置主设备的优先级默认值是32768 我们可以设置为100[S2]lacp priority 100

Eth-trunk :LACP模式链路聚合实战相关推荐

  1. lacp静态和动态区别_HCNA配置静态LACP模式链路聚合

    1.静态LACP模式 静态LACP模式是一种利用LACP协议进行聚合参数协商.确定活动接口和非活动接口的链路聚合方式.该模式下,需手工创建Eth-Trunk,手工加入Eth-Trunk成员接口,由LA ...

  2. 玩转华为数据中心交换机系列 | 配置手工负载分担模式链路聚合示例

    素材来源:华为数据中心交换机配置指南 一边学习一边整理试验笔记,并与大家分享,侵权即删,谢谢支持! 附上汇总贴:玩转华为数据中心交换机系列 | 汇总_COCOgsta的博客-CSDN博客 组网需求 如 ...

  3. 使用nmcli配置主备模式链路聚合(team端口绑定)

    现在让我们在CentOS 7中配置网卡绑定,运行ip link命令查看可以使用的网卡 [root@localhost ~]# ip link 1: lo: <LOOPBACK,UP,LOWER_ ...

  4. 链路聚合_使用nmcli配置主备模式链路聚合

    主备模式的链路聚合将其中一个接口置于备份状态,并且仅当活动接口断开链接时才会使其处于活动状态. 现在让我们在CentOS 7中配置网卡绑定,运行ip link命令查看可以使用的网卡 [root@loc ...

  5. Linux测试lacp,linux – 链路聚合(LACP / 802.3ad)最大吞吐量

    我在 Linux下看到一些关于绑定接口的令人困惑的行为,我想把这种情况抛到那里,希望有人可以为我清理它. 我有两台服务器:服务器1(S1)有4x 1Gbit以太网连接;服务器2(S2)具有2x 1Gb ...

  6. 链路聚合的手工模式和LACP模式

    链路聚合的手工模式和LACP模式 链路聚合可以提高可靠性,链路带宽的利用,还可以实现负载均衡,如果单线链路故障不会影响到整体的数据转发,除非所有都down了 手工模式: 所有链路都会参与流量转发,设备 ...

  7. 玩转华为数据中心交换机系列 | 配置动态LACP模式的链路聚合示例

    素材来源:华为数据中心交换机配置指南 一边学习一边整理试验笔记,并与大家分享,侵权即删,谢谢支持! 附上汇总贴:玩转华为数据中心交换机系列 | 汇总_COCOgsta的博客-CSDN博客 组网需求 如 ...

  8. ruijie交换机lacp动态_华为交换机LACP模式(动态)链路聚合配置示例

    华为交换机LACP模式(动态)链路聚合配置示例 猫先生 • 2019 年 06 月 15 日 LACP 模式链路聚合简介 以太网链路聚合是指将多条以太网物理链路捆绑在一起成为一条逻辑链路,从而实现增加 ...

  9. ENSP演示:配置LACP模式的链路聚合

    一.LACP模式链路聚合简介 以太网链路聚合是指将多条以太网物理链路捆绑在一起成为一条逻辑链路,从而实现增加链路带宽的目的.链路聚合分为手工模式和LACP模式. LACP模式需要有链路聚合控制协议LA ...

最新文章

  1. 【Tools】Markdown数学符号公式(史上最全公式表)
  2. Exchange2010server证书申请及分配服务
  3. Python数据分析很难学?60天就够了!
  4. mysql-ubuntu16.04彻底卸载mysql
  5. Navicat Premium 实用快捷键
  6. 在车上偶遇一位阿里大佬
  7. 计算(a+b)/c的值(信息学奥赛一本通-T1008)
  8. OpenVR——驱动接口之IClientTrackedDeviceProvider简介
  9. OpenShift 4 之Kafka(2)-配置Kafka Bridge,通过HTTP访问Kafka Topic
  10. 关于PHP在企业级开发领域的访谈——企业级开发,PHP准备好了吗?
  11. 人脸识别python face_recognize_python人脸识别库-face_recognition详解
  12. 探索GIS+物联网应用场景 MapGIS IoT实时大数据解决方案
  13. 13、腾讯云轻量应用服务器挂载文件系统
  14. 【项目实践】海康威视工业相机SDK开发小白版入门教程(VS2015+OpenCV4.5.1)
  15. Exponial欧拉降幂
  16. 亚马逊、敦煌、速卖通、阿里国际站、lazada、shopee、ebay、wish、wayfair、mercari、沃尔玛、newegg 跨境电商运营实战攻略
  17. 放for循环里面和外面区别
  18. Python tkinter 学习笔记(2)-- 控件、组件(二)
  19. KTorrent 2.2 公布
  20. 【八月英语----照亮我心】

热门文章

  1. (转载)Javanbsp;Collectionamp;nbs…
  2. 2017,不能再咸鱼了
  3. No module named 'torchvision.ops'的解决办法
  4. 虚拟内存与虚拟存储器的区别
  5. 计算机网络----宽带速度kbps、KB、Mbps
  6. 基于python爬取有道翻译,并在线翻译
  7. ARCore:从哪里冒出来的ARCore
  8. 全球隔离,生出不少坏毛病
  9. Android模拟器检测体系梳理,android驱动开发入门
  10. 电脑提示d3dcompiler_47.dll缺失怎么修复?