实验拓扑
实验需求:
- SW1和SW2之间的链路聚合Eth-trunk1使用静态LACP模式,要求最大活动链路为2条,并且G0/0/1链路作为备份链路,优先级值为50000。S2作为主动端,优先级值为100,开启抢占,抢占延时为20s。
- SW2和SW3之间的链路聚合Eth-trunk2使用手工负载分担模式。
- PC1和PC4属于VLAN 10,所在网段为192.168.10.0/24,PC2和PC3属于VLAN 20,所在网段为172.16.10.0/24;VLAN 10和VLAN 20所属网段的网关配置在AR1上,使用单臂路由技术,最终实现所有用户主机都能互相通信。
实验步骤:
路由器1:
#
sysname zst-r1
#
undo info-center enable
#
interface Ethernet0/0/0
#
interface Ethernet0/0/0.10
dot1q termination vid 10
ip address 192.61.10.1 255.255.255.0
arp broadcast enable
#
interface Ethernet0/0/0.20
dot1q termination vid 20
ip address 172.61.10.1 255.255.255.0
arp broadcast enable
#
interface Ethernet0/0/1
#
interface Serial0/0/0
link-protocol ppp
交换机1:
#
sysname zst-s1
#
undo info-center enable
#
vlan batch 10 20
#
drop illegal-mac alarm
#
diffserv domain default
#
drop-profile default
#
interface MEth0/0/1
#
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 10 20
mode lacp-static
max active-linknumber 2
#
interface Eth-Trunk2
port link-type trunk
port trunk allow-pass vlan 10 20
#
interface Ethernet0/0/1
port link-type trunk
port trunk allow-pass vlan 10 20
#
interface Ethernet0/0/2
eth-trunk 1
lacp priority 50000
#
interface Ethernet0/0/3
eth-trunk 1
#
interface Ethernet0/0/4
eth-trunk 1
#
interface Ethernet0/0/5
eth-trunk 2
#
interface Ethernet0/0/6
eth-trunk 2
交换机2:
#
sysname zst-s2
#
undo info-center enable
#
vlan batch 10 20
#
lacp priority 100
#
interface Vlanif1
#
interface MEth0/0/1
#
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 10 20
mode lacp-static
lacp preempt enable
lacp preempt delay 20
#
interface Ethernet0/0/1
port link-type access
port default vlan 10
#
interface Ethernet0/0/2
eth-trunk 1
#
interface Ethernet0/0/3
eth-trunk 1
#
interface Ethernet0/0/4
eth-trunk 1
#
interface Ethernet0/0/5
port link-type access
port default vlan 20
交换机3:
#
sysname zst-s3
#
undo info-center enable
#
vlan batch 10 20
#
cluster enable
ntdp enable
ndp enable
#
drop illegal-mac alarm
#
diffserv domain default
#
drop-profile default
#
interface Vlanif1
#
interface MEth0/0/1
#
interface Eth-Trunk2
port link-type trunk
port trunk allow-pass vlan 10 20
#
interface Ethernet0/0/1
port link-type access
port default vlan 20
#
interface Ethernet0/0/2
port link-type access
port default vlan 10
实验截图: