千兆不够用?一根网线跑万兆的魔法!


步骤1:创建Eth-Trunk组
sys
interface eth-trunk 1 # 创建聚合组1
步骤2:绑定物理接口
interface gigabitethernet 0/0/1
eth-trunk 1 # 将接口加入聚合组
interface gigabitethernet 0/0/2
eth-trunk 1
步骤3:配置Trunk口属性
interface Eth-Trunk1
description uT:HJ-SW-1-Eth-Trunk-2
port link-type trunk
undo port trunk allow-pass vlan 1
port trunk allow-pass vlan 100 200
⚠️ 关键细节:
两端设备LACP模式必须一致(active/active或active/passive)
聚合组成员速率/双工模式需完全相同
方案1:静态路由+聚合(适合小型网络)
# 路由器配置
ip route-static x.x.x.x x.x.x.x 100.1.1.1
优势:配置简单,资源消耗低
局限:链路故障需手动切换
方案2:OSPF动态路由+聚合(中大型网络首选)
# 核心交换机
routerid2.2.2.2
ospf 1
area 0.0.0.0
network 12.1.1.0 0.0.0.255 # 宣告聚合链路网段
智能效果:
-
自动检测聚合链路状态
-
多条路径负载均衡(ECMP)
-
毫秒级故障收敛
某电子厂改造前后数据


以上图拓扑为例说明:
-
研发网只允许企业内网间访问,不允许访问互联网
-
办公网可访问研发网与互联网
-
研发网只允许受限访问终端
-
研发网跑静态路由,办公网跑动态OSPF路由协议
-
研发终端1可实现DHCP动态获取或手工配置静态ip地址入网方式
sysname R1
#
undo info-centerenable
#
interface Eth-Trunk1
description dT-Core-SW-Eth-Trunk-1
ip address 12.1.1.1 255.255.255.252
#
interface GigabitEthernet0/0/0
description dT:Core-SW-Gi0/0/1
eth-trunk 1
#
interface GigabitEthernet0/0/1
description dT:Core-SW-Gi0/0/2
eth-trunk 1
#
interface GigabitEthernet0/0/2
description uT:Internet_ZX
ip address 100.1.1.2 255.255.255.252
#
ospf 1
default-route-advertise always
area 0.0.0.0
network 12.1.1.0 0.0.0.255
#
ip route-static 0.0.0.0 0.0.0.0 100.1.1.1
sysname Core-SW
#
undo info-centerenable
#
vlan batch 12 23 to 24
#
interface Vlanif12
ip address 12.1.1.2 255.255.255.252
ospfenable1 area 0.0.0.0
#
interface Vlanif23
ip address 23.1.1.1 255.255.255.252
#
interface Vlanif24
ip address 24.1.1.1 255.255.255.252
ospfenable1 area 0.0.0.0
#
interface Eth-Trunk1
description uT:R1-Eth-Trunk-1
port link-type access
port default vlan 12
#
interface Eth-Trunk2
description dT:HJ-SW-1-Eth-Trunk-1
port link-type access
port default vlan 23
#
interface Eth-Trunk3
description dT:HJ-SW-2-Eth-Trunk-1
port link-type access
port default vlan 24
#
interface GigabitEthernet0/0/1
description uT:R1-Gi0/0/0
eth-trunk 1
#
interface GigabitEthernet0/0/2
description uT:R1-Gi0/0/1
eth-trunk 1
#
interface GigabitEthernet0/0/3
description dT:HJ-SW-1-Gi0/0/1
eth-trunk 2
#
interface GigabitEthernet0/0/4
description dT:HJ-SW-1-Gi0/0/2
eth-trunk 2
#
interface GigabitEthernet0/0/5
description dT:HJ-SW-2-Gi0/0/1
eth-trunk 3
#
interface GigabitEthernet0/0/6
description dT:HJ-SW-2-Gi0/0/2
eth-trunk 3
#
ospf 1 router-id 2.2.2.2
import-route static
area 0.0.0.0
network 12.1.1.0 0.0.0.255
#
ip route-static 172.168.0.0 255.255.0.0 23.1.1.2
#
sysname HJ_SW1
#
undo info-centerenable
#
vlan batch 23 100 200
#
acl number 3001
rule 5 deny ipsource172.168.2.250 0 destination 172.168.1.250 0
acl number 3002#仅允许192.168.1.250访问172.168.1.250,其余默认拒绝
rule 5 permit ipsource192.168.1.250 0 destination 172.168.1.250 0
rule 10 deny ip
#
interface Vlanif23
ip address 23.1.1.2 255.255.255.252
#
interface Vlanif100
ip address 172.168.1.254 255.255.255.0
dhcpselectinterface#vlan100开启dhcp服务
#
interface Vlanif200
ip address 172.168.2.254 255.255.255.0
#
interface Eth-Trunk1
description uT:Core-SW-Eth-Trunk-2
port link-type access
port default vlan 23
#
interface Eth-Trunk2
description dT:JR-SW-Eth-Trunk-1
port link-type trunk
undo port trunk allow-pass vlan 1
port trunk allow-pass vlan 100 200
#
interface GigabitEthernet0/0/1
description uT:Core-SW-Gi0/0/3
eth-trunk 1
#
interface GigabitEthernet0/0/2
description uT:Core-SW-Gi0/0/4
eth-trunk 1
#
interface GigabitEthernet0/0/3
description dT:JR-SW-Gi0/0/1
eth-trunk 2
#
interface GigabitEthernet0/0/4
description dT:JR-SW-Gi0/0/2
eth-trunk 2
#
ip route-static 192.168.0.0 255.255.0.0 23.1.1.1
#
traffic-filter vlan 200 inbound acl 3001#实现vlan200的访问控制策略
traffic-filter vlan 100 inbound acl 3002#实现vlan100的访问控制策略
#
sysname HJ_SW2
#
undo info-centerenable
#
vlan batch 24 300 400
#
interface Vlanif24
ip address 24.1.1.2 255.255.255.252
ospfenable1 area 0.0.0.0
#
interface Vlanif300
ip address 192.168.1.254 255.255.255.0
#
interface Vlanif400
ip address 192.168.2.254 255.255.255.0
#
interface MEth0/0/1
#
interface Eth-Trunk1
description uT:Core-SW-Eth-Trunk-3
port link-type access
port default vlan 24
#
interface Eth-Trunk2
description dT:JR-SW-2-Eth-Trunk-1
port link-type trunk
undo port trunk allow-pass vlan 1
port trunk allow-pass vlan 300 400
#
interface GigabitEthernet0/0/1
description uT:Core-SW-gi0/0/5
eth-trunk 1
#
interface GigabitEthernet0/0/2
description uT:Core-SW-Gi0/0/6
eth-trunk 1
#
interface GigabitEthernet0/0/3
description dT:JR-SW-2-Gi0/0/1
eth-trunk 2
#
interface GigabitEthernet0/0/4
description dT:JR-SW-2-Gi0/0/2
eth-trunk 2
#
ospf 1
area 0.0.0.0
network 192.168.0.0 0.0.255.255
#
sysname JR_SW1
#
undo info-centerenable
#
vlan batch 100 200
#
interface Eth-Trunk1
description uT:HJ-SW-1-Eth-Trunk-2
port link-type trunk
undo port trunk allow-pass vlan 1
port trunk allow-pass vlan 100 200
#
interface GigabitEthernet0/0/1
eth-trunk 1
#
interface GigabitEthernet0/0/2
eth-trunk 1
#
interface GigabitEthernet0/0/3
port link-type access
port default vlan 100
#
interface GigabitEthernet0/0/4
port link-type access
port default vlan 200
#






发表回复