华为交换机RRPP环协议

配置RRPP单实例单环示例

组网需求

1所示,在组网中存在由SwitchA、SwitchB、SwitchC组成的环网结构。对于这种组网结构,需要当环网完整时,可以避免报文成环;当环网发生故障时,可以实现快速收敛迅速恢复环网上各节点间的通信。在SwitchA、SwitchB和SwitchC上配置RRPP功能,可以很好地满足这两个需求。

1 配置RRPP单环组网图


配置思路

采用如下的思路配置RRPP单环示例:

1. 配置设备上将要加入RRPP的各接口,使其可以通过RRPP环上需要通过的VLAN数据,并去使能与RRPP相冲突的功能(例如STP功能)。

2. 创建RRPP域和控制VLAN,为后续配置RRPP环做好准备。

3. RRPP环上需要通过的VLAN数据映射到实例1,包括数据VLAN100~VLAN300和控制VLAN20、VLAN21(其中VLAN21是设备自动生成的子控制VLAN),为后续配置保护VLAN做好准备。

4. RRPP域中,配置保护VLAN并创建RRPP环,将SwitchA、SwitchB和SwitchC配置为域1环1的节点。其中配置SwitchA为环1的主节点,SwitchB和SwitchC为环1的传输节点。

5. 在各设备上使能RRPP环和RRPP协议,使得RRPP功能生效。

说明:

此例中未提及的VLAN默认为不存在。但是由于缺省情况下,设备上的接口都加入了VLAN1,需要将配置涉及的接口退出VLAN1。配置过程略。

操作步骤

1. 创建RRPP域,同时创建域的控制VLAN

# 配置环1的主节点SwitchA的域为1,主控制VLAN的VLAN ID为20。

<HUAWEI> system-view

[HUAWEI] sysname SwitchA

[SwitchA] rrpp domain 1

[SwitchA-rrpp-domain-region1] control-vlan 20

[SwitchA-rrpp-domain-region1] quit

# SwitchB和SwitchC配置过程和SwitchA类似,此处省略,详见配置文件。

2. 配置实例1映射控制VLAN20、VLAN21和数据VLAN100~VLAN300。创建VLAN的过程略。

3. [SwitchA] stp region-configuration

4. [SwitchA-mst-region] instance 1 vlan 20 21 100 to 300

5. [SwitchA-mst-region] active region-configuration

[SwitchA-mst-region] quit

# SwitchB和SwitchC配置过程和SwitchA类似,此处省略,详见配置文件。

6. 将即将加入RRPP环的接口配置为Trunk类型接口,允许VLAN100~300通过,并去使能接口的STP功能

# 配置SwitchA。

[SwitchA] interface gigabitethernet 0/0/1

[SwitchA-GigabitEthernet0/0/1] port link-type trunk

[SwitchA-GigabitEthernet0/0/1] port trunk allow-pass vlan 100 to 300  

[SwitchA-GigabitEthernet0/0/1] stp disable

[SwitchA-GigabitEthernet0/0/1] quit

[SwitchA] interface gigabitethernet 0/0/2

[SwitchA-GigabitEthernet0/0/2] port link-type trunk

[SwitchA-GigabitEthernet0/0/2] port trunk allow-pass vlan 100 to 300 

[SwitchA-GigabitEthernet0/0/2] stp disable

[SwitchA-GigabitEthernet0/0/2] quit

# SwitchB和SwitchC配置过程和SwitchA类似,此处省略,详见配置文件。

7. 配置保护VLAN,创建RRPP环并使能RRPP环

# 在SwitchA配置保护VLAN,并配置SwitchA为RRPP环1的主节点,并指定主副接口。

[SwitchA] rrpp domain 1

[SwitchA-rrpp-domain-region1] protected-vlan reference-instance 1

[SwitchA-rrpp-domain-region1] ring 1 node-mode master primary-port gigabitethernet 0/0/1 secondary-port gigabitethernet 0/0/2 level 0

[SwitchA-rrpp-domain-region1] ring 1 enable

[SwitchA-rrpp-domain-region1] quit

# 在SwitchB配置保护VLAN,并配置SwitchB为RRPP主环1的传输节点,并指定主副接口。

[SwitchB] rrpp domain 1

[SwitchB-rrpp-domain-region1] protected-vlan reference-instance 1

[SwitchB-rrpp-domain-region1] ring 1 node-mode transit primary-port gigabitethernet 0/0/1 secondary-port gigabitethernet 0/0/2 level 0

[SwitchB-rrpp-domain-region1] ring 1 enable

[SwitchB-rrpp-domain-region1] quit

# 在SwitchC配置保护VLAN,并配置SwitchC为RRPP环1的传输节点,并指定主副接口。

[SwitchC] rrpp domain 1

[SwitchC-rrpp-domain-region1] protected-vlan reference-instance 1

[SwitchC-rrpp-domain-region1] ring 1 node-mode transit primary-port gigabitethernet 0/0/1 secondary-port gigabitethernet 0/0/2 level 0

[SwitchC-rrpp-domain-region1] ring 1 enable

[SwitchC-rrpp-domain-region1] quit

8. 使能RRPP协议

在完成配置RRPP环后,需要在环上的每个节点上使能RRPP协议,这样RRPP环才能够被激活,配置步骤如下:

# 配置SwitchA上RRPP协议使能。

[SwitchA] rrpp enable

# 配置SwitchB上RRPP协议使能。

[SwitchB] rrpp enable

# 配置SwitchC上RRPP协议使能。

[SwitchC] rrpp enable

9. 检查配置结果

经过以上配置,在网络稳定后,执行以下操作,验证配置结果。以SwitchA为例。

· SwitchA上执行display rrpp brief命令,查看结果如下:

· <SwitchA> display rrpp brief

· Abbreviations for Switch Node Mode :

· M - Master , T - Transit , E - Edge , A - Assistant-Edge

· 

· RRPP Protocol Status:  Enable

· RRPP Working Mode: HW

· RRPP Linkup Delay Timer: 0 sec (0 sec default)

· Number of RRPP Domains: 1

· 

· Domain Index  : 1

· Control VLAN  : major 20    sub 21

· Protected VLAN : Reference Instance 1

· Hello Timer   : 1 sec(default is 1 sec)  Fail Timer : 6 sec(default is 6 sec)

· 

·  Ring   Ring    Node     Primary/Common           Secondary/Edge          Is

·  ID     Level   Mode     Port                     Port                    Enabled

·  --------------------------------------------------------------------------------

·  1      0       M        GigabitEthernet0/0/1     GigabitEthernet0/0/2    Yes

可以看到SwitchA的RRPP协议状态使能了,在域1中的主控制Vlan为20,子控制Vlan为21,SwitchA为主环1中的主节点。主端口为GigabitEthernet0/0/1,副端口为GigabitEthernet0/0/2。

· SwitchA上执行display rrpp verbose domain命令,查看结果如下:

# 查看SwitchA上域1中的详细信息。

<SwitchA> display rrpp verbose domain 1

Domain Index   : 1

Control VLAN   : major 20    sub 21

Protected VLAN : Reference Instance 1

Hello Timer    : 1 sec(default is 1 sec)  Fail Timer : 6 sec(default is 6 sec)

 

RRPP Ring      : 1

Ring Level     : 0

Node Mode      : Master

Ring State     : Complete

Is Enabled     : Enable                       Is Active : Yes

Primary port   : GigabitEthernet0/0/1         Port status: UP

Secondary port : GigabitEthernet0/0/2         Port status: BLOCKED

可以看到RRPP环的状态处于完整状态。

配置文件

· SwitchA的配置文件

· #

· sysname SwitchA

· #

· vlan batch 20 to 21 100 to 300

· #

· rrpp enable

· #                                                                               

· stp region-configuration                                                       

·  instance 1 vlan 20 to 21 100 to 300                                                    

·  active region-configuration                                                   

· #

· rrpp domain 1

·  control-vlan 20

·  protected-vlan reference-instance 1

·  ring 1 node-mode master primary-port GigabitEthernet0/0/1 secondary-port GigabitEthernet0/0/2 level 0

·  ring 1 enable

· #

· interface GigabitEthernet0/0/1

·  port link-type trunk

·  undo port trunk allow-pass vlan 1

·  port trunk allow-pass vlan 20 to 21 100 to 300

·  stp disable

· #

· interface GigabitEthernet0/0/2

·  port link-type trunk

·  undo port trunk allow-pass vlan 1

·  port trunk allow-pass vlan 20 to 21 100 to 300

·  stp disable

· #

· SwitchB的配置文件

· #

· sysname SwitchB

· #

· vlan batch 20 to 21 100 to 300

· #

· rrpp enable

· #                                                                               

· stp region-configuration                                                       

·  instance 1 vlan 20 to 21 100 to 300                                                      

·  active region-configuration                                                   

· #

· rrpp domain 1

·  control-vlan 20

·  protected-vlan reference-instance 1

·  ring 1 node-mode transit primary-port GigabitEthernet0/0/1 secondary-port GigabitEthernet0/0/2 level 0

·  ring 1 enable

· #

· interface GigabitEthernet0/0/1

·  port link-type trunk

·  undo port trunk allow-pass vlan 1

·  port trunk allow-pass vlan 20 to 21 100 to 300

·  stp disable

· #

· interface GigabitEthernet0/0/2

·  port link-type trunk

·  undo port trunk allow-pass vlan 1

·  port trunk allow-pass vlan 20 to 21 100 to 300

·  stp disable

· #

return

· SwitchC的配置文件

· #

· sysname SwitchC

· #

· vlan batch 20 to 21 100 to 300

· #

· rrpp enable

· #                                                                               

· stp region-configuration                                                       

·  instance 1 vlan 20 to 21 100 to 300                                                     

·  active region-configuration                                                   

· #

· rrpp domain 1

·  control-vlan 20

·  protected-vlan reference-instance 1

·  ring 1 node-mode transit primary-port GigabitEthernet0/0/1 secondary-port GigabitEthernet0/0/2 level 0

·  ring 1 enable

· #

· interface GigabitEthernet0/0/1

·  port link-type trunk

·  undo port trunk allow-pass vlan 1

·  port trunk allow-pass vlan 20 to 21 100 to 300

·  stp disable

· #

· interface GigabitEthernet0/0/2

·  port link-type trunk

·  undo port trunk allow-pass vlan 1

·  port trunk allow-pass vlan 20 to 21 100 to 300

·  stp disable

· #

return






猜你喜欢

转载自blog.csdn.net/weixin_41515615/article/details/80959219