用HCL模拟器做堆叠实验
实验要求,不同的IRF中的同一vlan可以相互访问
设计堆叠和链路聚合
图中有13个设备,1-6 是交换机,7-13是PC机,
目的:13号设备可以访问10号设备具体如下
组网图,按下图连线组网:
hcl操作
1. 左边管理交换机
划分member,优先级
交换机1和2使用双线40g光口堆叠,并划分vlan 100 300
设置链路聚合端口 1 ,并涵盖1/0/1 2/0/1 端口
vlan 100 : 2/0/3 , vlan 300 :1/0/2 2/0/2
设置 pc13 /192.168.1.13 /vlan 100
pc11 /192,168.3.11 /vlan 300
pc12 /192.168.3.12 /vlan 300
2. 右边业务交换机
划分member,优先级
交换机3-6 ,使用单线40g光口堆叠,并划分vlan 100 200
设置链路聚合口 3/0/1 5/0/1 ,trunk permit all vlan
vlan 100 :3/0/2 4/0/2 ;vlan 200 :5/0/2 6/0/2
设置pc7 :192.168.2.7 , pc8 :192.168.2.8
pc9:192.168.1.9 ,pc10:192.168.1.10
一 左边 1和2 号交换机堆叠
1号交换机
<H3C>sys
[H3C]irf member 1 priority 10
[H3C]interface FortyGigE 1/0/53
[H3C-FortyGigE1/0/53]shutdown
[H3C-FortyGigE1/0/53]interface FortyGigE 1/0/54
[H3C-FortyGigE1/0/54]shutdown
[H3C-FortyGigE1/0/54]quit
[H3C]irf-port 1/2
[H3C-irf-port1/2]port group interface FortyGigE 1/0/53
[H3C-irf-port1/2]port group interface FortyGigE 1/0/54
[H3C-irf-port1/2]quit
[H3C]interface FortyGigE 1/0/53
[H3C-FortyGigE1/0/53]undo shutdown
[H3C-FortyGigE1/0/53]interface FortyGigE 1/0/54
[H3C-FortyGigE1/0/54]undo shutdown
[H3C-FortyGigE1/0/54]quit
[H3C]save
[H3C]irf-port-configuration active
[H3C]dis irf
MemberID Role Priority CPU-Mac Description
*+1 Master 10 2ecd-6f6b-0104 ---
--------------------------------------
* indicates the device is the master.
+ indicates the device through which the user logs in.
---------------------
2号交换机
<H3C>sys
[H3C]irf member 1 renumber 2
Renumbering the member ID may result in configuration change or loss. Continue?[Y/N]:y
[H3C]quit
<H3C>reboot
Press ENTER to get started.
<H3C>sys
[H3C]display irf
MemberID Role Priority CPU-Mac Description
*+2 Master 1 28be-3dcf-0204 ---
--------------------------------------------------
* indicates the device is the master.
+ indicates the device through which the user logs in
[H3C]interface FortyGigE 2/0/53
[H3C-FortyGigE2/0/53]shutdown
[H3C-FortyGigE2/0/53]interface FortyGigE 2/0/54
[H3C-FortyGigE2/0/54]shutdown
[H3C-FortyGigE2/0/54]quit
[H3C]irf-port 2/1
[H3C-irf-port2/1]port group interface FortyGigE 2/0/53
[H3C-irf-port2/1]port group interface FortyGigE 2/0/54
[H3C-irf-port2/1]quit
[H3C]interface FortyGigE 2/0/53
[H3C-FortyGigE2/0/53]undo shutdown
[H3C-FortyGigE2/0/53]interface FortyGigE 2/0/54
[H3C-FortyGigE2/0/54]undo shutdown
[H3C-FortyGigE2/0/54]quit
[H3C]save
[H3C]irf-port-configuration active
[H3C]dis irf
MemberID Role Priority CPU-Mac Description
*+2 Master 1 28be-3dcf-0204 ---
--------------------------------------------------
* indicates the device is the master.
+ indicates the device through which the user logs in
---------------------
设置好之后,进入1号交换机查询堆叠结果。
[H3C]dis irf link
Member 1
IRF Port Interface Status
1 disable --
2 FortyGigE1/0/53 UP
FortyGigE1/0/54 UP
Member 2
IRF Port Interface Status
1 FortyGigE2/0/53 UP
FortyGigE2/0/54 UP
2 disable --
---------------------
先把四个交换机的member priority 改了 重启
交换机3 设置优先级最高 10
<H3C>sys
[H3C]irf member 1 renumber 3
Renumbering the member ID may result in configuration change or loss. Continue?[Y/N]:y
[H3C]quit
<H3C>reboot
Press ENTER to get started.
<H3C>sys
[H3C]irf member 1 priority 10
[H3C]interface FortyGigE 3/0/53
[H3C-FortyGigE3/0/53]shutdown
[H3C-FortyGigE3/0/53]interface FortyGigE 3/0/54
[H3C-FortyGigE3/0/54]shutdown
[H3C-FortyGigE3/0/54]quit
[H3C]irf-port 3/1
[H3C-irf-port3/1]port group interface FortyGigE 3/0/53
[H3C-irf-port3/1]quit
[H3C]irf-port3/2
[H3C-irf-port3/2]port group interface FortyGigE 3/0/54
[H3C-irf-port3/2]quit
[H3C]interface FortyGigE 3/0/53
[H3C-FortyGigE3/0/53]undo shutdown
[H3C-FortyGigE3/0/53]interface FortyGigE 3/0/54
[H3C-FortyGigE3/0/54]undo shutdown
[H3C-FortyGigE3/0/54]quit
[H3C]save
[H3C]irf-port-configuration active
---------------------
4 5 6 三个交换机和3号设置一样,需要修改member 为 4 5 6 ,优先级不设置,四个全部设置好后,随便登录一个交换机查证
[H3C]dis irf
MemberID Role Priority CPU-Mac Description
*+3 Master 10 2ecd-834f-0304 ---
4 Standby 1 2ecd-889c-0404 ---
5 Standby 1 2ecd-8ed5-0504 ---
6 Standby 1 2ecd-9264-0604 ---
--------------------------------------------------
* indicates the device is the master.
+ indicates the device through which the user logs in.
Auto upgrade : yes
Mac persistent : 6 min
Domain ID : 0
---------------------
三 ,堆叠完成后,测试同一IRF中的vlan划分,先把PC 设备 7 8 9 10 11 12 按图中部署好
1. 左边
划分vlan 100 300
vlan 100 : 2/0/3 , vlan 300 :1/0/2 2/0/2
设置 pc13 /192.168.1.13 /vlan 100
pc11 /192,168.3.11 /vlan 300
pc12 /192.168.3.12 /vlan 300
启动交换机1终端
sys
System View: return to User View with Ctrl+Z.
[H3C]vlan 100
[H3C-vlan100]port GigabitEthernet 2/0/3
[H3C-vlan100]quit
[H3C]vlan 300
[H3C-vlan300]port GigabitEthernet 1/0/2
[H3C-vlan300]port GigabitEthernet 2/0/2
[H3C-vlan300]quit
[H3C]save
设置好后,使用PC机11终端就可以和12终端通信了,没有分配vlan之前是不可以的。
2. 右边
堆叠后,进入任意一个交换机终端,并划分vlan 100 200
vlan 100 :3/0/2 4/0/2 ;vlan 200 :5/0/2 6/0/2
设置pc7 :192.168.2.7 , pc8 :192.168.2.8
pc9:192.168.1.9 ,pc10:192.168.1.10
<H3C>sys
System View: return to User View with Ctrl+Z.
[H3C]vlan 100
[H3C-vlan100]port GigabitEthernet 3/0/2
[H3C-vlan100]port GigabitEthernet 4/0/2
[H3C-vlan100]quit
[H3C]vlan 200
[H3C-vlan200]port GigabitEthernet 5/0/2
[H3C-vlan200]port GigabitEthernet 6/0/2
[H3C-vlan200]quit
[H3C]save
四 对俩边的irf进行链路聚合,使得俩个irf可以相互通讯
链路聚合物理端口为1/0/1 2/0/1 3/0/1 5/0/1
先进入交换机1终端
[H3C]dis irf
MemberID Role Priority CPU-Mac Description
*+1 Master 10 2ecd-6f6b-0104 ---
2 Standby 1 2ecd-7a5b-0204 ---
--------------------------------------------------
<H3C>sys
[H3C]interface Bridge-Aggregation 1
[H3C-Bridge-Aggregation1]quit
[H3C]interface GigabitEthernet 1/0/1
[H3C-GigabitEthernet1/0/1]port link-aggregation group 1
[H3C-GigabitEthernet1/0/1]quit
[H3C]interface GigabitEthernet 2/0/1
[H3C-GigabitEthernet2/0/1]port link-aggregation group 1
[H3C-GigabitEthernet2/0/1]quit
[H3C]interface Bridge-Aggregation 1
[H3C-Bridge-Aggregation1]port link-type trunk
Configuring GigabitEthernet1/0/1 done.
Configuring GigabitEthernet2/0/1 done.
[H3C-Bridge-Aggregation1]port trunk permit vlan 100 200 300
Configuring GigabitEthernet1/0/1 done.
Configuring GigabitEthernet2/0/1 done.
[H3C-Bridge-Aggregation1]quit
[H3C]save
<H3C>sys
[H3C]interface Bridge-Aggregation 1
[H3C-Bridge-Aggregation1]port link-type trunk
[H3C-Bridge-Aggregation1]port trunk permit vlan 100 200 300
[H3C-Bridge-Aggregation1]quit
[H3C]interface GigabitEthernet 3/0/1
[H3C-GigabitEthernet3/0/1]port link-aggregation group 1
[H3C-GigabitEthernet3/0/1]quit
[H3C]interface GigabitEthernet 5/0/1
[H3C-GigabitEthernet5/0/1]port link-aggregation group 1
[H3C-GigabitEthernet5/0/1]quit
[H3C]display link-aggregation summary
[H3C]save
设置好之后,设备13 就可以 和设备10 通讯了 。
实验小结:在规划堆叠成员交换机的端口时,本端的1号口要与对端的2号口对应,本端的2号口与对端的1号口对应,否则无法堆叠!