1、准备工作
SW1 和 SW2 之间的堆叠线先不连接,配置完成之后再连接。防止激活IFR端口后,没有保存配置导致配置丢失。

2、SW1交换机配置

配置IRF端口
system-view
irf member 1 priority 32 # 配置优先级(数值越大优先级越高,主设备应设较高值)
irf domain 1
int range te1/0/49 to te1/0/50
shutdown
quit
irf-port 1/1
port group interface Te1/0/49
port group interface Te1/0/50
int range te1/0/49 to te1/0/50
undo shutdown
quit
save
irf-port-configuration active #激活IRF端口配置

3、SW2交换机配置

配置IRF端口
system-view
irf member 1 renumber 2	 # 配置成员编号,确保该编号在IRF中唯一
y
quit
save
y
reboot	# 重启使编号生效
irf domain 1
int range te2/0/49 to te2/0/50
shutdown
irf-port 2/2  # 注意不要使用跟第一台交换机同样的端口编号如果第一台是1/1,第二台不能是2/1,必须是2/2,否则irf建立不起来
port group interface Te2/0/49
port group interface Te2/0/50
quit
int range te2/0/49 to te2/0/50
undo shutdown
quit
save
quit
irf-port-configuration active #激活IRF端口配置,当设备IRF端口激活后,交换机会重启(线已经连接的状态下),所以一定要先保存再激活

4、连接堆叠线

5、验证IRF堆叠状态

# 查看IRF成员信息
display irf
# 查看IRF拓扑信息
display irf topology
# 查看IRF配置
display irf configuration
posted on 2026-04-01 21:11  LBTZ  阅读(0)  评论(0)    收藏  举报