链路聚合

 

 

新建拓扑

拓扑开启前

 

 拓扑开启后

 

 

 

1.1 链路聚合

假设 S1不支持 LACP,S1和 S2互连的接口需要捆绑成一个二层逻辑接口。逻辑接口成员根据源目的 MAC进行负载分担。

S1配置如下:

interface Eth-Trunk 12  

mode manual load-balance

load-balance src-dst-mac

trunkport GigabitEthernet 0/0/23 0/0/24

 

 

S2配置如下:

int Eth-Trunk 12

mode manual load-balance

load-balance src-dst-mac

trunkport GigabitEthernet 0/0/23 0/0/24

 

 

1.2 Link-type

1.S1,S2,S3,S4互连接口的链路类型为 Trunk,允许除 VLAN1外的所有 VLAN通过。

解法:在S1,S2,S3,S4上分别创建vlan 10, vlan 20 ,配置交换机之间的链路为Trunk,并放行除VLAN1之外的VLAN通过。

S1配置如下:

vlan batch 10 20

interface GigabitEthernet 0/0/1

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface GigabitEthernet 0/0/2

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface GigabitEthernet 0/0/12

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface eth-trunk 12

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

 

 

S2配置如下:

vlan batch 10 20

interface GigabitEthernet 0/0/1

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface GigabitEthernet 0/0/2

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface GigabitEthernet 0/0/12

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface eth-trunk 12

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

 

 

S3配置如下:

vlan batch 10 20

interface GigabitEthernet 0/0/1

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface GigabitEthernet 0/0/2

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface Ethernet 0/0/1

port link-type access

port default vlan 10

 

 

 

S4配置如下:

vlan batch 10 20

interface GigabitEthernet 0/0/1

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface GigabitEthernet 0/0/2

port link-type trunk

port trunk allow-pass vlan all

undo port trunk allow-pass vlan 1

 

interface Ethernet 0/0/1

port link-type access

port default vlan 20

 

 

 

2.CE1,CE2的 VRRP虚拟 IP地址 10.3.1.254,为 PC1的网关。CE1会周期性发送 sender ip 为 10.3.1.254,源 MAC为 00-00-5E-00-01-01的免费 ARP。PC1与网关之间的数据 包封装在 VLAN10中(PC1收发 untag帧)

3.CE1,CE2 的 VRRP 虚拟 IP 地址 10.3.2.254,为 Sever1 的网关。CE2 会周期性发送 sender ip为 10.3.2.254,源 MAC为 00-00-5E-00-01-02的免费 ARP。Sever2与网关之间的数据包封装在 VLAN20中(sever1收发 untag帧)

4.VRRP的 master设备重启时,在 Ge0/0/2变为 UP 1 分钟后,才能重新成为 master.

解法:在CE1的G0/0/2.10和G0/0/2.20接口上配置VRRP协议,接口地址已经预配。

interface GigabitEthernet0/0/2.10

  vrrp vrid 1 virtual-ip 10.3.1.254

vrrp vrid 1 priority 120

  vrrp vrid 1 preempt-mode timer delay 60

  arp broadcast enable

 

interface GigabitEthernet0/0/2.20

vrrp vrid 2 virtual-ip 10.3.2.254

arp broadcast enable

 

 

在CE2的G0/0/2.10和G0/0/2.20接口上配置VRRP协议,接口地址已经预配。

interface GigabitEthernet0/0/2.10

vrrp vrid 1 virtual-ip 10.3.1.254

arp broadcast enable

 

interface GigabitEthernet0/0/2.20

vrrp vrid 2 virtual-ip 10.3.2.254

vrrp vrid 2 priority 120

vrrp vrid 2 preempt-mode timer delay 60

arp broadcast enable

 

 

 

1.3 MSTP

1.S1,S2,S3,S4都运行 MSTP,VLAN10在 instance10中,S1为 primary root,S2为 secondary root。VLAN20在 instance20中,S1为 secondary root ,S2为 primary root。MSTP的 region name为 HUAWEI,revision level为 12。

2.除了交换机互连的接口,其他接口要确保不参与 MSTP 计算,直接由 disable 变为 forwarding状态。

解法:分别在S1,S2,S3,S4上配置MSTP,配置如下:

stp region-configuration

 region-name HUAWEI

 revision-level 12

 instance 10 vlan 10

 instance 20 vlan 20

 active region-configuration

(四个设备都要配置)

 

 

在S1上配置Instance 10和Instance 20的根桥和备份根桥。

stp instance 10 root primary

stp instance 20 root secondary

 

 

在S2上配置Instance 10和Instance 20的根桥和备份根桥。

stp instance 10 root secondary

stp instance 20 root primary

 

 

分别在S1,S2,S3,S4配置边缘端口。

[S1]stp edged-port default

[S2]stp edged-port default

[S3]stp edged-port default

[S4]stp edged-port default

    分别在S1,S2的Trunk接口配置非边缘端口。

interface Eth-Trunk12

stp edged-port disable

interface GigabitEthernet0/0/1

stp edged-port disable

interface GigabitEthernet0/0/12

stp edged-port disable

 

 

 

 

 

分别在S3,S4的Trunk接口配置非边缘端口。

interface GigabitEthernet0/0/1

stp edged-port disable

interface GigabitEthernet0/0/2

stp edged-port disable

 

 

 

 

 

1.4 WAN

1.PE1-RR1的互连的 Serial接口,绑定为一个逻辑接口,成员采用 HDLC。逻辑接口的 IPV4,IPV6地址,按照图 1.5 配置。

解法:在PE1上配置IP-Trunk,并配置IPv4和IPv6地址。

int s0/0/0

link-protocol hdlc

y

int s0/0/1

link-protocol hdlc

y

interface Ip-Trunk1

trunkport Serial 0/0/0 0/0/1

ip address 10.1.13.1 30

ipv6 enable

ipv6 address 2000:EAD8:99EF:CC3E:B2AD:9EFF:32DD:1300 127

在RR1上配置IP-Trunk,并配置IPv4和IPv6地址 。

int s0/0/0

link-protocol hdlc

y

int s0/0/1

link-protocol hdlc

y

interface Ip-Trunk1

trunkport Serial 0/0/0 0/0/1

ip address 10.1.13.2 30

ipv6 enable

ipv6 address 2000:EAD8:99EF:CC3E:B2AD:9EFF:32DD:1301 127

2.PE3-CE3 的互连接口 POS 接口,绑定为一个逻辑接口,成员采用 PPP,逻辑接口的 IPV4地址,按照图 1 配置。

解法:在PE3上配置MP-Group接口,并配置IPv4地址。

interface Mp-group 0/0/1

 ip address 10.2.33.2 30

int Pos 4/0/0

ppp mp Mp-group 0/0/1

int Pos 6/0/0

ppp mp mp-group 0/0/1

 

在CE3上配置MP-Group接口,并配置IPv4地址。

interface Mp-group 0/0/1

ip address 10.2.33.1 30

int Pos 4/0/0

ppp mp Mp-group 0/0/1

int Pos 6/0/0

ppp mp mp-group 0/0/1

posted @   年年哎  阅读(762)  评论(0编辑  收藏  举报
编辑推荐:
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
阅读排行:
· winform 绘制太阳,地球,月球 运作规律
· AI与.NET技术实操系列(五):向量存储与相似性搜索在 .NET 中的实现
· 超详细:普通电脑也行Windows部署deepseek R1训练数据并当服务器共享给他人
· 上周热点回顾(3.3-3.9)
· AI 智能体引爆开源社区「GitHub 热点速览」
点击右上角即可分享
微信分享提示