m

您所在的位置:网站首页 mlag配置端口聚合 m

m

2024-06-12 19:00| 来源: 网络整理| 查看: 265

m-lag:跨机箱的链路聚合 peer-link作用: 1.m-lag协商 2.表项同步 不同厂商的设备也可以做m-lag,不同型号也可而已,但是配置更多,比较麻烦

拓扑图: 在这里插入图片描述

m-lag配置: zerotouch cancel 取消设备0配置上线 show interface status 查看接口状态

配置链路聚合口: sw1: interface ethernet 1-2 channel-group 1 mode active 将peer-link接口加入链路聚合组1(peer-link必须加入链路聚合组,peer-link只支持聚合协商) interface port-channel1 switchport mode trunk 聚合端口模式改为trunk switchport trunk group peertrunk 聚合端口加入trunk聚合组,组名peertrunk sw2: interface ethernet 1-2 channel-group 1 mode active 将peer-link接口加入链路聚合组1(peer-link必须加入链路聚合组,peer-link只支持聚合协商) interface port-channel1 switchport mode trunk 聚合端口模式改为trunk switchport trunk group peertrunk 聚合端口加入trunk聚合组,组名peertrunk

创建peer-link管理vlan并为vlan配置ip,关闭生成树: sw1: vlan 4094 创建vlan,用于配置ip为peer-link链路协商做准备 trunk group peertrunk 将vlan加入到trunk组peertrunk中 interface vlan 4094 为vlan 4094配置ip ip address 172.16.1.1/24 no autostate exit no spanning-tree vlan-id 4094 禁用vlan 4094的生成树选举,以免阻塞接口 sw2: vlan 4094 创建vlan,用于配置ip为peer-link链路协商做准备 trunk group peertrunk 将vlan加入到trunk组peertrunk中 interface vlan 4094 为vlan 4094配置ip ip address 172.16.1.2/24 no autostate exit no spanning-tree vlan-id 4094 禁用vlan 4094的生成树选举,以免阻塞接口

配置peer-link协商: sw1: mlag configuration domain-id galaxy 配置mlag域名 heartbeat-interval 3000 配置心跳包文间隔3000毫秒(3秒)(每隔3秒发一次报文检测对端状态) local-interface vlan4094 用自己本地的vlan4094进行mlag协商 peer-address 172.16.1.2 peer-link port-channel1 协商peer-link链路为聚合port-channel1 reload-delay 150(默认配置) sw2: mlag configuration domain-id galaxy 配置mlag域名 heartbeat-interval 3000 配置心跳包文间隔3000毫秒(3秒)(每隔3秒发一次报文检测对端状态) local-interface vlan4094 用自己本地的vlan4094进行mlag协商 peer-address 172.16.1.1 peer-link port-channel1 协商peer-link链路为聚合port-channel1 reload-delay 150(默认配置)

配置m-lag: sw1: interface ethernet 3-4 channel-group 101 mode active 将接口3和4加入聚合组101 interface port-channel101 switchport mode trunk mlag 1 sw2: interface ethernet 3-4 channel-group 101 mode active 将接口3和4加入聚合组101(sw1和sw2接口号可以不同,但聚合组号必须相同) interface port-channel101 switchport mode trunk mlag 1

sw3: interface ethernet 1-4 channel-group 101 mode active 将四个口链路聚合 interface port-channel101 switchport mode trunk

sw1:show mlag 查看mlag对等体同步以及状态信息 sw3:show port-channel summary 查看端口链路聚合信息 sw1:show port-channel summary 查看端口链路聚合信息(包含mlag的聚合端口,包括对等体的两条,一共四条)

关闭二层口功能,配置ip sw1: interface ethernet 5 no switchport 关闭二层口功能 ip address 192.168.1.1/24 sw2: interface ethernet 5 no switchport 关闭二层口功能 ip address 192.168.2.1/24 ar: interface g0/0 ip address 192.168.1.2/24 interface g0/2 ip address 192.168.2.2/24 interface loopback1 ip address 100.1.1.1 32

配置ospf路由: sw1: ospf 1 router-id 1.1.1.1 network 10.1.1.0 0.0.0.255 area 0 network 192.168.1.0 0.0.0.255 area 0 sw2: ospf 1 router-id 2.2.2.2 network 10.1.1.0 0.0.0.255 area 0 network 192.168.2.0 0.0.0.255 area 0 show ip ospf neighbor show ip route sw1:ip routing

配置sw1/sw2业务vlan双活网关 sw1:vlan 10 interface vlan 10 ip address 10.1.1.1/24 mac address virtual-router

sw3: vlan 10 interface ethernet 5 switchport access vlan 10 spanning-tree portfast

配置pc pc: ip 10.1.1.0 255.255.255.0 10.1.1.1 sw3:show port-channel load-balance 查看链路聚合负载分担



【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3