3. 三台交换机VSU组网案例

一、组网需求

1、组建三台S2910-24GT4XS-E环网,S2910-24GT4XS-E-1、S2910-24GT4XS-E-2和S2910-24GT4XS-E-3组成虚拟设备VSU(domain ID为1),S2910-24GT4XS-E-1的优先级是200,S2910-24GT4XS-E-2的优先级是150,S2910-24GT4XS-E-3的优先级是100。如下图所示,VSL链路采用两两互联的方式连接;

注意:建议为了稳定性期间,建议两台设备的VSL至少为两条。如果条件限制,一条也是可以做VSU的;

2、采用基于BFD检测双主机,G1/0/24和G2/0/24是一对BFD心跳接口,并且测试VSL链路断开后的情况;

3、VSU使用过程中需要增加一条VSL的操作;

二、组网拓扑

三、配置要点

1、3台S2910-24GT4XS-E设备之间分别通过一条VSL链路互联;

注:11.X软件平台中,为了防止实际场景连错,VSL AP 采用动态协商。我们只需要负责将接口配置为VSL口,不用配置VSL组号,设备将自动判断该接口对端连接的设备来进行自动协商,将接口加入对应的VSL组,以区别不同设备间互联VSL线路。

2、关于多台设备环形或是线性构建VSU防止双主机问题:

1)基于BFD检测:

一般情况下:无论线性还是环形,建议首尾两台设备互联BFD即可(环形VSU使用任意两台互联)。

特殊情况:如果要完全防止双主机的产生,需要交换机之间两两互联来实现,也就是有n台交换机的话,需要使用n*(n-1)/2条BFD线路。

特殊情况如图:3台设备做VSU,如果要完全防止双主机问题,需要3*(3-1)/2=3条的BFD线路

注意:基于BFD检测的配置见配置步骤第四步,本节这里不举例。

2)基于聚合口检测

在多台VSU要完全防止双主机,最好的方式采用聚合检测,这样不用像BFD那样,需要多条BFD线路两两互联。聚合检测只需要n条线路即可。但是前提是下联的接入交换机是锐捷设备,这样保证锐捷的私有报文可以正常转发。

注意:如果需要使用MAD配置,必须接入交换机支持MAD功能,否则无法用MAD功能来进行双主机检测,

待VSU组建成功后,配置命令如下:

VSU交换机配置:

Ruijie(config)# switch virtual domain 1

Ruijie(config-vs-domain)# dual-active detection aggregateport

Ruijie(config-vs-domain)# dual-active interface aggregatePort 1

Ruijie(config-vs-domain)# exit

在接入交换机上配置:

Ruijie(config)#interface aggregateport 1

Ruijie(config-if-AggregatePort 1)# dad relay enable

Ruijie(config-if-AggregatePort 1)# exit

四、配置步骤

1、配置S2910-24GT4XS-E-1、S2910-24GT4XS-E-2及S2910-24GT4XS-E-3的VSU域标识,设备编号和优先级

S2910-24GT4XS-E-1交换机配置

S2910-24GT4XS-E-1>enable

S2910-24GT4XS-E-1# configure terminal

S2910-24GT4XS-E-1(config)# switch virtual domain 1     
//创建VSU domain id

S2910-24GT4XS-E-1(config-vs-domain)# switch 1         
//创建switch id

S2910-24GT4XS-E-1(config-vs-domain)# switch 1 priority 200  
//配置switch id的优先级

S2910-24GT4XS-E-1(config-vs-domain)# switch 1 description S2910-24GT4XS-E-1   
//配置switch id的描述信息

S2910-24GT4XS-E-1(config-vs-domain)# exit

S2910-24GT4XS-E-1(config)# vsl-port
//进入VSL配置模式,建议至少采用2条VSL链路来提升VSU的可靠性,如果条件限制,一条VSL链路也可以

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/25  
//将Tengigabitethernet 1/0/25加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/26  
//将Tengigabitethernet 1/0/26加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/27  
//将Tengigabitethernet 1/0/27加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/28  
//将Tengigabitethernet 1/0/28加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# exit

S2910-24GT4XS-E-1(config)# exit

S2910-24GT4XS-E-2交换机配置

S2910-24GT4XS-E-2>enable

S2910-24GT4XS-E-2# configure terminal

S2910-24GT4XS-E-2(config)# switch virtual domain 1   
//创建VSU domain id
S2910-24GT4XS-E-2(config-vs-domain)# switch 2     
//创建switch id

S2910-24GT4XS-E-2(config-vs-domain)# switch 2 priority 150   
//配置switch id的优先级

S2910-24GT4XS-E-2(config-vs-domain)# switch 2 description  S2910-24GT4XS-E-2
//配置switch id的描述信息

S2910-24GT4XS-E-2(config-vs-domain)# exit

S2910-24GT4XS-E-1(config)# vsl-port
//进入VSL配置模式,建议至少采用2条VSL链路来提升VSU的可靠性,如果条件限制,一条VSL链路也可以

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/25  
//将Tengigabitethernet 1/0/25加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/26 
//将Tengigabitethernet 1/0/26加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/27  
//将Tengigabitethernet 1/0/27加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/28  
//将Tengigabitethernet 1/0/28加入VSL

S2910-24GT4XS-E-2(config-vsl-port)# exit

S2910-24GT4XS-E-2(config)# exit

S2910-24GT4XS-E-3交换机配置

S2910-24GT4XS-E-3>enable

S2910-24GT4XS-E-3# configure terminal

S2910-24GT4XS-E-3(config)# switch virtual domain 1   
//创建VSU domain id

S2910-24GT4XS-E-3(config-vs-domain)# switch 3    
//创建switch id

S2910-24GT4XS-E-3(config-vs-domain)# switch 3 priority 150   
//配置switch id的优先级

S2910-24GT4XS-E-3(config-vs-domain)# switch 3 description S2910-24GT4XS-E-3    
//配置switch id的描述信息

S2910-24GT4XS-E-3(config-vs-domain)# exit

S2910-24GT4XS-E-1(config)# vsl-port
//进入VSL配置模式,建议至少采用2条VSL链路来提升VSU的可靠性,如果条件限制,一条VSL链路也可以

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/25 
//将Tengigabitethernet 1/0/25加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/26  
//将Tengigabitethernet 1/0/26加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/27  
//将Tengigabitethernet 1/0/27加入VSL

S2910-24GT4XS-E-1(config-vsl-port)# port-member interface Tengigabitethernet 0/28  
//将Tengigabitethernet 1/0/28加入VSL

S2910-24GT4XS-E-3(config-vsu-ap)# exit

S2910-24GT4XS-E-3(config)# exit

S2910-24GT4XS-E-3(config)# exit

2、把S2910-24GT4XS-E-1、S2910-24GT4XS-E-2和S2910-24GT4XS-E-3转换到VSU模式

S2910-24GT4XS-E-1#switch convert mode virtual   
//将交换机转换为VSU模式

Convert switch mode will automatically backup the "config.text" file and then delete it, and reload the switch. Do you want to convert switch to virtual mode? [no/yes]y
//输入y

S2910-24GT4XS-E-2#switch convert mode virtual   
//将交换机转换为VSU模式

Convert switch mode will automatically backup the "config.text" file and then delete it, and reload the switch. Do you want to convert switch to virtual mode? [no/yes]y
//输入y

S2910-24GT4XS-E-3#switch convert mode virtual   
//将交换机转换为VSU模式

Convert switch mode will automatically backup the "config.text" file and then delete it, and reload the switch. Do you want to convert switch to virtual mode? [no/yes]y
//输入y

接着交换机会进行重启,并且进行VSU的选举,这个时间可能会比较长,请耐心等待

3、等待VSU建立成功后,进行BFD配置

Ruijie#configure terminal

Ruijie(config)#interface GigabitEthernet 1/0/24  
//第一台VSU设备的第24个接口

Ruijie(config-if-GigabitEthernet 1/0/24)#no switchport   
//只需要在BFD接口上敲no sw,无需其他配置

Ruijie(config-if-GigabitEthernet 1/0/24)#exit

Ruijie(config)#interface GigabitEthernet 2/0/24  
//第二台VSU设备的第24个接口

Ruijie(config-if-GigabitEthernet 1/0/24)#no switchport  
//只需要在BFD接口上敲no sw,无需其他配置

Ruijie(config-if-GigabitEthernet 2/0/24)#exit

Ruijie(config)#switch virtual domain 1

Ruijie(config-vs-domain)#dual-active detection bfd

Ruijie(config-vs-domain)#dual-active bfd interface GigabitEthernet 1/0/24

Ruijie(config-vs-domain)#dual-active bfd interface GigabitEthernet 2/0/24

4、VSU情况下,需要增加一条VSL线路设置

VSU模式下可以配置增加或者删除某个VSL链路,11.X软件平台中,修改直接生效无需重启设备。

举例:

1)当前要把S2910-24GT4XS-E-1设备的VSL 1/1口中将Te1/0/25移除

Ruijie(config)#vsl-port

Ruijie(config-vsl-port)#port-member interface tenGigabitEthernet 1/0/25

The configuration of port TenGigabitEthernet 1/0/25 will be removed, confirm to continue?[yes/no]:y  
//1/0/25口下的配置将被清空,并确认加入到VSL链路中

2)将Te1/0/25再加入到S2910-24GT4XS-E-1设备的VSL 1/1口中

Ruijie(config-vsl-port)#no port-member interface tenGigabitEthernet 1/0/25

% The port TenGigabitEthernet 1/0/25 will be in shutdown status after the port type is converted.  
//当1/0/25口从VSL链路移除后,1/0/25口将被Shutdown

五、功能验证

1、查看VSU的基本信息,VSU的三种状态 ACTIVE STANDBY CANDIADATE

Ruijie#show switch virtual role

Switch_id  Domain_id  Priority  Position  Status  Role      Description                     
---------  ---------  --------  --------  ------  ----      -----------
1(1)       1(1)       200(200)  LOCAL     OK      ACTIVE    S2910-24GT4XS-E-1  
2(2)       1(1)       150(200)  LOCAL     OK      STANDBY   S2910-24GT4XS-E-2        
3(3)       1(1)       100(200)  LOCAL     OK      CANDIDATE S2910-24GT4XS-E-3  

2、通过show switch virtual config 可以查看当前设备VSU的配置信息

3、查看show switch virtual dual-active summary可以查看VSU的BFD检测信息

Ruijie#show switch virtual dual-active summary

BFD dual-active detection enabled: Yes         
//BFD的状态

Aggregateport dual-active detection enabled: No

Interfaces excluded from shutdown in recovery mode:

In dual-active recovery mode: No

4、通过show switch virtuanl link可以查看VSL信息

5、通过show switch virtual topology可以查看当前VSU拓扑信息

Last updated