Example: Configuring one subring

Network configuration

As shown in Figure 35, perform the following tasks to eliminate loops on the network:

Figure 35: Network diagram

Procedure


[IMPORTANT: ]

IMPORTANT:

By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface.


  1. Configure Device A.

    # Create VLANs 1 to 30, map these VLANs to MSTI 1, and activate the MST region configuration.

    <DeviceA> system-view
    [DeviceA] vlan 1 to 30
    [DeviceA] stp region-configuration
    [DeviceA-mst-region] instance 1 vlan 1 to 30
    [DeviceA-mst-region] active region-configuration
    [DeviceA-mst-region] quit
    

    # Set the link state change suppression interval to 0 seconds on FortyGigE 1/0/1.

    [DeviceA] interface fortygige 1/0/1
    [DeviceA-] link-delay 0
    

    # Disable the spanning tree feature on the port.

    [DeviceA-FortyGigE1/0/1] undo stp enable
    

    # Configure the port as a trunk port and assign it to VLANs 1 to 30.

    [DeviceA-FortyGigE1/0/1] port link-type trunk
    [DeviceA-FortyGigE1/0/1] port trunk permit vlan 1 to 30
    [DeviceA-FortyGigE1/0/1] quit
    

    # Configure FortyGigE 1/0/2 in the same way FortyGigE 1/0/1 is configured.

    [DeviceA] interface 
    [DeviceA-FortyGigE1/0/2] link-delay 0
    [DeviceA-FortyGigE1/0/2] undo stp enable
    [DeviceA-FortyGigE1/0/2] port link-type trunk
    [DeviceA-FortyGigE1/0/2] port trunk permit vlan 1 to 30
    [DeviceA-FortyGigE1/0/2] quit
    

    # Create ERPS ring 1.

    [DeviceA] erps ring 1
    

    # Configure ERPS ring member ports.

    [DeviceA-erps-ring1] port0 interface fortygige 1/0/1
    [DeviceA-erps-ring1] port1 interface fortygige 1/0/2
    

    # Create ERPS instance 1.

    [DeviceA-erps-ring1] instance 1
    

    # Configure the node role.

    [DeviceA-erps-ring1-inst1] node-role owner rpl port0
    

    # Configure the control VLAN.

    [DeviceA-erps-ring1-inst1] control-vlan 100
    

    # Configure the protected VLANs.

    [DeviceA-erps-ring1-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceA-erps-ring1-inst1] instance enable
    [DeviceA-erps-ring1-inst1] quit
    [DeviceA-erps-ring1] quit
    

    # Enable CFD, and create a level-5 MD named MD_A.

    [DeviceA] cfd enable
    [DeviceA] cfd md MD_A level 5
    

    # Create Ethernet service instance 1, in which the MA is identified by a VLAN and serves VLAN 1.

    [DeviceA] cfd service-instance 1 ma-id vlan-based md MD_A vlan 1
    

    # Configure a MEP list in Ethernet service instance 1, create outward-facing MEP 1001 in Ethernet service instance 1, and enable CCM sending on FortyGigE 1/0/1.

    [DeviceA] cfd meplist 1001 1002 service-instance 1
    [DeviceA] interface fortygige 1/0/1
    [DeviceA-FortyGigE1/0/1] cfd mep 1001 service-instance 1 outbound
    [DeviceA-FortyGigE1/0/1] cfd cc service-instance 1 mep 1001 enable
    [DeviceA-FortyGigE1/0/1] quit
    

    # Create Ethernet service instance 2, in which the MA is identified by a VLAN and serves VLAN 2.

    [DeviceA] cfd service-instance 2 ma-id vlan-based md MD_A vlan 2
    

    # Configure a MEP list in Ethernet service instance 2, create outward-facing MEP 2001 in Ethernet service instance 1, and enable CCM sending on FortyGigE 1/0/2.

    [DeviceA] cfd meplist 2001 2002 service-instance 2
    [DeviceA] interface fortygige 1/0/2
    [DeviceA-FortyGigE1/0/2] cfd mep 2001 service-instance 2 outbound
    [DeviceA-FortyGigE1/0/2] cfd cc service-instance 2 mep 2001 enable
    [DeviceA-FortyGigE1/0/2] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 1001 in Ethernet service instance 1.

    [DeviceA] track 1 cfd cc service-instance 1 mep 1001
    

    # Associate FortyGigE 1/0/1 with track entry 1 and bring up the port.

    [DeviceA] interface fortygige 1/0/1
    [DeviceA-FortyGigE1/0/1] port erps ring 1 instance 1 track 1
    [DeviceA-FortyGigE1/0/1] undo shutdown
    [DeviceA-FortyGigE1/0/1] quit
    

    # Create track entry 2 and associate it with the CC function of CFD for MEP 2001 in Ethernet service instance 2.

    [DeviceA] track 2 cfd cc service-instance 2 mep 2001
    

    # Associate FortyGigE 1/0/2 with track entry 2 and bring up the port.

    [DeviceA] interface fortygige 1/0/2
    [DeviceA-FortyGigE1/0/2] port erps ring 1 instance 1 track 2
    [DeviceA-] undo shutdown
    [DeviceA-FortyGigE1/0/2] quit
    

    # Enable ERPS.

    [DeviceA] erps enable
    
  2. Configure Device B.

    # Create VLANs 1 to 30, map these VLANs to MSTI 1, and activate the MST region configuration.

    <DeviceB> system-view
    [DeviceB] vlan 1 to 30
    [DeviceB] stp region-configuration
    [DeviceB-mst-region] instance 1 vlan 1 to 30
    [DeviceB-mst-region] active region-configuration
    [DeviceB-mst-region] quit
    

    # Set the link state change suppression interval to 0 seconds on FortyGigE 1/0/1.

    [DeviceB] interface fortygige 1/0/1
    [DeviceB-] link-delay 0
    

    # Disable the spanning tree feature on the port.

    [DeviceB-FortyGigE1/0/1] undo stp enable
    

    # Configure the port as a trunk port and assign it to VLANs 1 to 30.

    [DeviceB-FortyGigE1/0/1] port link-type trunk
    [DeviceB-FortyGigE1/0/1] port trunk permit vlan 1 to 30
    [DeviceB-FortyGigE1/0/1] quit
    

    # Configure FortyGigE 1/0/2 in the same way FortyGigE 1/0/1 is configured.

    [DeviceB] interface fortygige 1/0/2
    [DeviceB-FortyGigE1/0/2] link-delay 0
    [DeviceB-FortyGigE1/0/2] undo stp enable
    [DeviceB-FortyGigE1/0/2] port link-type trunk
    [DeviceB-FortyGigE1/0/2] port trunk permit vlan 1 to 30
    [DeviceB-FortyGigE1/0/2] quit
    

    # Create ERPS ring 1.

    [DeviceB] erps ring 1
    

    # Configure ERPS ring member ports.

    [DeviceB-erps-ring1] port0 interface fortygige 1/0/1
    [DeviceB-erps-ring1] port1 interface fortygige 1/0/2
    

    # Create ERPS instance 1.

    [DeviceB-erps-ring1] instance 1
    

    # Configure the node role.

    [DeviceB-erps-ring1-inst1] node-role neighbor rpl port0
    

    # Configure the control VLAN.

    [DeviceB-erps-ring1-inst1] control-vlan 100
    

    # Configure the protected VLANs.

    [DeviceB-erps-ring1-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceB-erps-ring1-inst1] instance enable
    [DeviceB-erps-ring1-inst1] quit
    [DeviceB-erps-ring1] quit
    

    # Enable CFD, and create a level-5 MD named MD_A.

    [DeviceB] cfd enable
    [DeviceB] cfd md MD_A level 5
    

    # Create Ethernet service instance 1, in which the MA is identified by a VLAN and serves VLAN 1.

    [DeviceB] cfd service-instance 1 ma-id vlan-based md MD_A vlan 1
    

    # Configure a MEP list in Ethernet service instance 1, create outward-facing MEP 1002 in Ethernet service instance 1, and enable CCM sending on FortyGigE 1/0/1.

    [DeviceB] cfd meplist 1001 1002 service-instance 1
    [DeviceB] interface fortygige 1/0/1
    [DeviceB-FortyGigE1/0/1] cfd mep 1002 service-instance 1 outbound
    [DeviceB-FortyGigE1/0/1] cfd cc service-instance 1 mep 1002 enable
    [DeviceB-FortyGigE1/0/1] quit
    

    # Create Ethernet service instance 3, in which the MA is identified by a VLAN and serves VLAN 3.

    [DeviceB] cfd service-instance 3 ma-id vlan-based md MD_A vlan 3
    

    # Configure a MEP list in Ethernet service instance 3, create outward-facing MEP 3002 in Ethernet service instance 2, and enable CCM sending on FortyGigE 1/0/2.

    [DeviceB] cfd meplist 3001 3002 service-instance 3
    [DeviceB] interface fortygige 1/0/2
    [DeviceB-FortyGigE1/0/2] cfd mep 3002 service-instance 3 outbound
    [DeviceB-FortyGigE1/0/2] cfd cc service-instance 3 mep 3002 enable
    [DeviceB-FortyGigE1/0/2] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 1002 in Ethernet service instance 1.

    [DeviceB] track 1 cfd cc service-instance 1 mep 1002
    

    # Associate FortyGigE 1/0/1 with track entry 1 and bring up the port.

    [DeviceB] interface 
    [DeviceB-FortyGigE1/0/1] port erps ring 1 instance 1 track 1
    [DeviceB-FortyGigE1/0/1] undo shutdown
    [DeviceB-FortyGigE1/0/1] quit
    

    # Create track entry 3 and associate it with the CC function of CFD for MEP 3002 in Ethernet service instance 3.

    [DeviceB] track 3 cfd cc service-instance 3 mep 3002
    

    # Associate with track entry 3 and bring up the port.

    [DeviceB] interface fortygige 1/0/2
    [DeviceB-FortyGigE1/0/2] port erps ring 1 instance 1 track 2
    [DeviceB-FortyGigE1/0/2] undo shutdown
    [DeviceB-FortyGigE1/0/2] quit
    

    # Enable ERPS.

    [DeviceB] erps enable
    
  3. Configure Device C.

    # Create VLANs 1 to 30, map these VLANs to MSTI 1, and activate the MST region configuration.

    <DeviceC> system-view
    [DeviceC] vlan 1 to 30
    [DeviceC] stp region-configuration
    [DeviceC-mst-region] instance 1 vlan 1 to 30
    [DeviceC-mst-region] active region-configuration
    [DeviceC-mst-region] quit
    

    # Set the link state change suppression interval to 0 seconds on FortyGigE 1/0/1.

    [DeviceC] interface fortygige 1/0/1
    [DeviceC-FortyGigE1/0/1] link-delay 0
    

    # Disable the spanning tree feature on the port.

    [DeviceC-FortyGigE1/0/1] undo stp enable
    

    # Configure the port as a trunk port and assign it to VLANs 1 to 30.

    [DeviceC-FortyGigE1/0/1] port link-type trunk
    [DeviceC-FortyGigE1/0/1] port trunk permit vlan 1 to 30
    [DeviceC-FortyGigE1/0/1] quit
    

    # Configure FortyGigE 1/0/2 in the same way FortyGigE 1/0/1 is configured.

    [DeviceC] interface fortygige 1/0/2
    [DeviceC-FortyGigE1/0/2] link-delay 0
    [DeviceC-FortyGigE1/0/2] undo stp enable
    [DeviceC-FortyGigE1/0/2] port link-type trunk
    [DeviceC-FortyGigE1/0/2] port trunk permit vlan 1 to 30
    [DeviceC-FortyGigE1/0/2] quit
    

    # Configure FortyGigE 1/0/3 in the same way FortyGigE 1/0/1 is configured.

    [DeviceC] interface 
    [DeviceC-FortyGigE1/0/3] link-delay 0
    [DeviceC-FortyGigE1/0/3] undo stp enable
    [DeviceC-] port link-type trunk
    [DeviceC-FortyGigE1/0/3] port trunk permit vlan 1 to 30
    [DeviceC-FortyGigE1/0/3] quit
    

    # Create ERPS ring 1.

    [DeviceC] erps ring 1
    

    # Configure ERPS ring member ports.

    [DeviceC-erps-ring1] port0 interface fortygige 1/0/1
    [DeviceC-erps-ring1] port1 interface fortygige 1/0/2
    

    # Create ERPS instance 1.

    [DeviceC-erps-ring1] instance 1
    

    # Configure the control VLAN.

    [DeviceC-erps-ring1-inst1] control-vlan 100
    

    # Configure the protected VLANs.

    [DeviceC-erps-ring1-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceC-erps-ring1-inst1] instance enable
    [DeviceC-erps-ring1-inst1] quit
    [DeviceC-erps-ring1] quit
    

    # Enable CFD, and create a level-5 MD named MD_A.

    [DeviceC] cfd enable
    [DeviceC] cfd md MD_A level 5
    

    # Create Ethernet service instance 3, in which the MA is identified by a VLAN and serves VLAN 3.

    [DeviceC] cfd service-instance 3 ma-id vlan-based md MD_A vlan 3
    

    # Configure a MEP list in Ethernet service instance 3, create outward-facing MEP 3001 in Ethernet service instance 3, and enable CCM sending on FortyGigE 1/0/2.

    [DeviceC] cfd meplist 3001 3002 service-instance 3
    [DeviceC] interface fortygige 1/0/2
    [DeviceC-] cfd mep 3001 service-instance 3 outbound
    [DeviceC-FortyGigE1/0/2] cfd cc service-instance 3 mep 3001 enable
    [DeviceC-FortyGigE1/0/2] quit
    

    # Create Ethernet service instance 4, in which the MA is identified by a VLAN and serves VLAN 4.

    [DeviceC] cfd service-instance 4 ma-id vlan-based md MD_A vlan 4
    

    # Configure a MEP list in Ethernet service instance 4, create outward-facing MEP 4001 in Ethernet service instance 4, and enable CCM sending on FortyGigE 1/0/1.

    [DeviceC] cfd meplist 4001 4002 service-instance 4
    [DeviceC] interface fortygige 1/0/1
    [DeviceC-FortyGigE1/0/1] cfd mep 4001 service-instance 4 outbound
    [DeviceC-FortyGigE1/0/1] cfd cc service-instance 4 mep 4001 enable
    [DeviceC-FortyGigE1/0/1] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 3001 in Ethernet service instance 3.

    [DeviceC] track 1 cfd cc service-instance 3 mep 3001
    

    # Associate with track entry 1 and bring up the port.

    [DeviceC] interface fortygige 1/0/2
    [DeviceC-FortyGigE1/0/2] port erps ring 1 instance 1 track 1
    [DeviceC-FortyGigE1/0/2] undo shutdown
    [DeviceC-FortyGigE1/0/2] quit
    

    # Create track entry 2 and associate it with the CC function of CFD for MEP 4001 in Ethernet service instance 4.

    [DeviceC] track 2 cfd cc service-instance 4 mep 4001
    

    # Associate FortyGigE 1/0/1 with track entry 2 and bring up the port.

    [DeviceC] interface 
    [DeviceC-FortyGigE1/0/1] port erps ring 1 instance 1 track 2
    [DeviceC-FortyGigE1/0/1] undo shutdown
    [DeviceC-FortyGigE1/0/1] quit
    

    # Create ERPS ring 2.

    [DeviceC] erps ring 2
    

    # Configure ERPS ring member ports.

    [DeviceC-erps-ring2] port0 interface fortygige 1/0/3
    

    # Configure ERPS ring 2 as the subring.

    [DeviceC-erps-ring2] ring-type sub-ring
    

    # Create ERPS instance 1.

    [DeviceC-erps-ring2] instance 1
    

    # Configure the node role.

    [DeviceC-erps-ring2-inst1] node-role interconnection port0
    

    # Configure the control VLAN.

    [DeviceC-erps-ring2-inst1] control-vlan 110
    

    # Configure the protected VLANs.

    [DeviceC-erps-ring2-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceC-erps-ring2-inst1] instance enable
    [DeviceC-erps-ring2-inst1] quit
    [DeviceC-erps-ring2] quit
    

    # Create Ethernet service instance 5, in which the MA is identified by a VLAN and serves VLAN 5.

    [DeviceC] cfd service-instance 5 ma-id vlan-based md MD_A vlan 5
    

    # Configure a MEP list in Ethernet service instance 5, create outward-facing MEP 5001 in Ethernet service instance 3, and enable CCM sending on FortyGigE 1/0/3.

    [DeviceC] cfd meplist 5001 5002 service-instance 5
    [DeviceC] interface fortygige 1/0/3
    [DeviceC-FortyGigE1/0/3] cfd mep 5001 service-instance 5 outbound
    [DeviceC-FortyGigE1/0/3] cfd cc service-instance 5 mep 5001 enable
    [DeviceC-FortyGigE1/0/3] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 5001 in Ethernet service instance 3.

    [DeviceC] track 1 cfd cc service-instance 5 mep 5001
    

    # Associate FortyGigE 1/0/3 with track entry 1 and bring up the port.

    [DeviceC] interface fortygige 1/0/3
    [DeviceC-] port erps ring 2 instance 1 track 1
    [DeviceC-FortyGigE1/0/3] undo shutdown
    [DeviceC-FortyGigE1/0/3] quit
    

    # Enable ERPS.

    [DeviceC] erps enable
    
  4. Configure Device D.

    # Create VLANs 1 to 30, map these VLANs to MSTI 1, and activate the MST region configuration.

    <DeviceD> system-view
    [DeviceD] vlan 1 to 30
    [DeviceD] stp region-configuration
    [DeviceD-mst-region] instance 1 vlan 1 to 30
    [DeviceD-mst-region] active region-configuration
    [DeviceD-mst-region] quit
    

    # Set the link state change suppression interval to 0 seconds on FortyGigE 1/0/1.

    [DeviceD] interface fortygige 1/0/1
    [DeviceD-FortyGigE1/0/1] link-delay 0
    

    # Disable the spanning tree feature on the port.

    [DeviceD-FortyGigE1/0/1] undo stp enable
    

    # Configure the port as a trunk port and assign it to VLANs 1 to 30.

    [DeviceD-FortyGigE1/0/1] port link-type trunk
    [DeviceD-FortyGigE1/0/1] port trunk permit vlan 1 to 30
    [DeviceD-FortyGigE1/0/1] quit
    

    # Configure FortyGigE 1/0/2 in the same way is configured.

    [DeviceD] interface fortygige 1/0/2
    [DeviceD-FortyGigE1/0/2] link-delay 0
    [DeviceD-] undo stp enable
    [DeviceD-FortyGigE1/0/2] port link-type trunk
    [DeviceD-FortyGigE1/0/2] port trunk permit vlan 1 to 30
    [DeviceD-FortyGigE1/0/2] quit
    

    # Configure FortyGigE 1/0/3 in the same way FortyGigE 1/0/1 is configured.

    [DeviceD] interface fortygige 1/0/3
    [DeviceD-FortyGigE1/0/3] link-delay 0
    [DeviceD-FortyGigE1/0/3] undo stp enable
    [DeviceD-FortyGigE1/0/3] port link-type trunk
    [DeviceD-FortyGigE1/0/3] port trunk permit vlan 1 to 30
    [DeviceD-FortyGigE1/0/3] quit
    

    # Create ERPS ring 1.

    [DeviceD] erps ring 1
    

    # Configure ERPS ring member ports.

    [DeviceD-erps-ring1] port0 interface fortygige 1/0/1
    [DeviceD-erps-ring1] port1 interface fortygige 1/0/2
    

    # Create ERPS instance 1.

    [DeviceD-erps-ring1] instance 1
    

    # Configure the control VLAN.

    [DeviceD-erps-ring1-inst1] control-vlan 100
    

    # Configure the protected VLANs.

    [DeviceD-erps-ring1-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceD-erps-ring1-inst1] instance enable
    [DeviceD-erps-ring1-inst1] quit
    [DeviceD-erps-ring1] quit
    

    # Enable CFD, and create a level-5 MD named MD_A.

    [DeviceD] cfd enable
    [DeviceD] cfd md MD_A level 5
    

    # Create Ethernet service instance 2, in which the MA is identified by a VLAN and serves VLAN 2.

    [DeviceD] cfd service-instance 2 ma-id vlan-based md MD_A vlan 2
    

    # Configure a MEP list in Ethernet service instance 2, create outward-facing MEP 2002 in Ethernet service instance 2, and enable CCM sending on FortyGigE 1/0/2.

    [DeviceD] cfd meplist 2001 2002 service-instance 2
    [DeviceD] interface fortygige 1/0/2
    [DeviceD-FortyGigE1/0/2] cfd mep 2002 service-instance 2 outbound
    [DeviceD-FortyGigE1/0/2] cfd cc service-instance 2 mep 2002 enable
    [DeviceD-FortyGigE1/0/2] quit
    

    # Create Ethernet service instance 4, in which the MA is identified by a VLAN and serves VLAN 4.

    [DeviceD] cfd service-instance 4 ma-id vlan-based md MD_A vlan 4
    

    # Configure a MEP list in Ethernet service instance 4, create outward-facing MEP 4002 in Ethernet service instance 4, and enable CCM sending on FortyGigE 1/0/1.

    [DeviceD] cfd meplist 4001 4002 service-instance 4
    [DeviceD] interface fortygige 1/0/1
    [DeviceD-FortyGigE1/0/1] cfd mep 4002 service-instance 4 outbound
    [DeviceD-FortyGigE1/0/1] cfd cc service-instance 4 mep 4002 enable
    [DeviceD-FortyGigE1/0/1] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 2002 in Ethernet service instance 2.

    [DeviceD] track 1 cfd cc service-instance 2 mep 2002
    

    # Associate FortyGigE 1/0/2 with track entry 1 and bring up the port.

    [DeviceD] interface fortygige 1/0/2
    [DeviceD-] port erps ring 1 instance 1 track 1
    [DeviceD-FortyGigE1/0/2] undo shutdown
    [DeviceD-FortyGigE1/0/2] quit
    

    # Create track entry 2 and associate it with the CC function of CFD for MEP 4002 in Ethernet service instance 4.

    [DeviceD] track 2 cfd cc service-instance 4 mep 4002
    

    # Associate FortyGigE 1/0/1 with track entry 2 and bring up the port.

    [DeviceD] interface fortygige 1/0/1
    [DeviceD-FortyGigE1/0/1] port erps ring 1 instance 1 track 2
    [DeviceD-] undo shutdown
    [DeviceD-FortyGigE1/0/1] quit
    

    # Create ERPS ring 2.

    [DeviceD] erps ring 2
    

    # Configure ERPS ring member ports.

    [DeviceD-erps-ring2] port0 interface fortygige 1/0/3
    

    # Configure ERPS ring 2 as the subring.

    [DeviceD-erps-ring2] ring-type sub-ring
    

    # Create ERPS instance 1.

    [DeviceD-erps-ring2] instance 1
    

    # Configure the node role.

    [DeviceD-erps-ring2-inst1] node-role interconnection port0
    

    # Configure the control VLAN.

    [DeviceD-erps-ring2-inst1] control-vlan 110
    

    # Configure the protected VLANs.

    [DeviceD-erps-ring2-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceD-erps-ring2-inst1] instance enable
    [DeviceD-erps-ring2-inst1] quit
    [DeviceD-erps-ring2] quit
    

    # Create Ethernet service instance 6, in which the MA is identified by a VLAN and serves VLAN 6.

    [DeviceD] cfd service-instance 6 ma-id vlan-based md MD_A vlan 6
    

    # Configure a MEP list in Ethernet service instance 6, create outward-facing MEP 6002 in Ethernet service instance 3, and enable CCM sending on FortyGigE 1/0/3.

    [DeviceD] cfd meplist 6001 6002 service-instance 6
    [DeviceD] interface fortygige 1/0/3
    [DeviceD-FortyGigE1/0/3] cfd mep 6002 service-instance 6 outbound
    [DeviceD-] cfd cc service-instance 6 mep 6002 enable
    [DeviceD-FortyGigE1/0/3] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 6002 in Ethernet service instance 6.

    [DeviceD] track 1 cfd cc service-instance 6 mep 6002
    

    # Associate FortyGigE 1/0/3 with track entry 1 and bring up the port.

    [DeviceD] interface fortygige 1/0/3
    [DeviceD-FortyGigE1/0/3] port erps ring 2 instance 1 track 1
    [DeviceD-FortyGigE1/0/3] undo shutdown
    [DeviceD-] quit
    

    # Enable ERPS.

    [DeviceD] erps enable
    
  5. Configure Device E.

    # Create VLANs 1 to 30, map these VLANs to MSTI 1, and activate the MST region configuration.

    <DeviceE> system-view
    [DeviceE] vlan 1 to 30
    [DeviceE] stp region-configuration
    [DeviceE-mst-region] instance 1 vlan 1 to 30
    [DeviceE-mst-region] active region-configuration
    [DeviceE-mst-region] quit
    

    # Set the link state change suppression interval to 0 seconds on FortyGigE 1/0/1.

    [DeviceE] interface fortygige 1/0/1
    [DeviceE-FortyGigE1/0/1] link-delay 0
    

    # Disable the spanning tree feature on the port.

    [DeviceE-] undo stp enable
    

    # Configure the port as a trunk port and assign it to VLANs 1 to 30.

    [DeviceE-FortyGigE1/0/1] port link-type trunk
    [DeviceE-] port trunk permit vlan 1 to 30
    [DeviceE-FortyGigE1/0/1] quit
    

    # Configure FortyGigE 1/0/2 in the same way FortyGigE 1/0/1 is configured.

    [DeviceE] interface fortygige 1/0/2
    [DeviceE-FortyGigE1/0/2] link-delay 0
    [DeviceE-FortyGigE1/0/2] undo stp enable
    [DeviceE-FortyGigE1/0/2] port link-type trunk
    [DeviceE-FortyGigE1/0/2] port trunk permit vlan 1 to 30
    [DeviceE-FortyGigE1/0/2] quit
    

    # Create ERPS ring 2.

    [DeviceE] erps ring 2
    

    # Configure ERPS ring member ports.

    [DeviceE-erps-ring2] port0 interface fortygige 1/0/1
    [DeviceE-erps-ring2] port1 interface fortygige 1/0/2
    

    # Configure ERPS ring 2 as the subring.

    [DeviceE-erps-ring2] ring-type sub-ring
    

    # Create ERPS instance 1.

    [DeviceE-erps-ring2] instance 1
    

    # Configure the node role.

    [DeviceE-erps-ring2] node-role owner rpl port0
    

    # Configure the control VLAN.

    [DeviceE-erps-ring2-inst1] control-vlan 110
    

    # Configure the protected VLANs.

    [DeviceE-erps-ring2-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceE-erps-ring2-inst1] instance enable
    [DeviceE-erps-ring2-inst1] quit
    [DeviceE-erps-ring2] quit
    

    # Enable CFD, and create a level-5 MD named MD_A.

    [DeviceE] cfd enable
    [DeviceE] cfd md MD_A level 5
    

    # Create Ethernet service instance 6, in which the MA is identified by a VLAN and serves VLAN 6.

    [DeviceE] cfd service-instance 6 ma-id vlan-based md MD_A vlan 6
    

    # Configure a MEP list in Ethernet service instance 6, create outward-facing MEP 6001 in Ethernet service instance 6, and enable CCM sending on FortyGigE 1/0/2.

    [DeviceE] cfd meplist 6001 6002 service-instance 6
    [DeviceE] interface fortygige 1/0/2
    [DeviceE-FortyGigE1/0/2] cfd mep 6001 service-instance 6 outbound
    [DeviceE-FortyGigE1/0/2] cfd cc service-instance 6 mep 6001 enable
    [DeviceE-] quit
    

    # Create Ethernet service instance 7, in which the MA is identified by a VLAN and serves VLAN 7.

    [DeviceE] cfd service-instance 7 ma-id vlan-based md MD_A vlan 7
    

    # Configure a MEP list in Ethernet service instance 7, create outward-facing MEP 7001 in Ethernet service instance 7, and enable CCM sending on FortyGigE 1/0/1.

    [DeviceE] cfd meplist 7001 7002 service-instance 7
    [DeviceE] interface 
    [DeviceE-FortyGigE1/0/1] cfd mep 7001 service-instance 7 outbound
    [DeviceE-FortyGigE1/0/1] cfd cc service-instance 7 mep 7001 enable
    [DeviceE-FortyGigE1/0/1] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 6001 in Ethernet service instance 6.

    [DeviceE] track 1 cfd cc service-instance 6 mep 6001
    

    # Associate FortyGigE 1/0/2 with track entry 1 and bring up the port.

    [DeviceE] interface fortygige 1/0/2
    [DeviceE-FortyGigE1/0/2] port erps ring 2 instance 1 track 1
    [DeviceE-FortyGigE1/0/2] undo shutdown
    [DeviceE-FortyGigE1/0/2] quit
    

    # Create track entry 2 and associate it with the CC function of CFD for MEP 7001 in Ethernet service instance 7.

    [DeviceE] track 2 cfd cc service-instance 7 mep 7001
    

    # Associate FortyGigE 1/0/1 with track entry 2 and bring up the port.

    [DeviceE] interface fortygige 1/0/1
    [DeviceE-FortyGigE1/0/1] port erps ring 2 instance 1 track 2
    [DeviceE-] undo shutdown
    [DeviceE-FortyGigE1/0/1] quit
    

    # Enable ERPS.

    [DeviceE] erps enable
    
  6. Configure Device F.

    # Create VLANs 1 to 30, map these VLANs to MSTI 1, and activate the MST region configuration.

    <DeviceF> system-view
    [DeviceF] vlan 1 to 30
    [DeviceF] stp region-configuration
    [DeviceF-mst-region] instance 1 vlan 1 to 30
    [DeviceF-mst-region] active region-configuration
    [DeviceF-mst-region] quit
    

    # Set the link state change suppression interval to 0 seconds on FortyGigE 1/0/1.

    [DeviceF] interface fortygige 1/0/1
    [DeviceF-FortyGigE1/0/1] link-delay 0
    

    # Disable the spanning tree feature on the port.

    [DeviceF-FortyGigE1/0/1] undo stp enable
    [DeviceF-FortyGigE1/0/1] port link-type trunk
    

    # Configure the port as a trunk port and assign it to VLANs 1 to 30.

    [DeviceF-FortyGigE1/0/1] port trunk permit vlan 1 to 30
    [DeviceF-FortyGigE1/0/1] quit
    

    # Configure FortyGigE 1/0/2 in the same way FortyGigE 1/0/1 is configured.

    [DeviceF] interface fortygige 1/0/2
    [DeviceF-FortyGigE1/0/2] link-delay 0
    [DeviceF-FortyGigE1/0/2] undo stp enable
    [DeviceF-FortyGigE1/0/2] port link-type trunk
    [DeviceF-FortyGigE1/0/2] port trunk permit vlan 1 to 30
    [DeviceF-] quit
    

    # Create ERPS ring 2.

    [DeviceF] erps ring 2
    

    # Configure ERPS ring member ports.

    [DeviceF-erps-ring2] port0 interface fortygige 1/0/1
    [DeviceF-erps-ring2] port1 interface fortygige 1/0/2
    

    # Configure ERPS ring 2 as the subring.

    [DeviceF-erps-ring2] ring-type sub-ring
    

    # Create ERPS instance 1.

    [DeviceF-erps-ring2] instance 1
    

    # Configure the node role.

    [DeviceF-erps-ring2] node-role neighbor rpl port0
    

    # Configure the control VLAN.

    [DeviceF-erps-ring2-inst1] control-vlan 110
    

    # Configure the protected VLANs.

    [DeviceF-erps-ring2-inst1] protected-vlan reference-instance 1
    

    # Enable ERPS for instance 1.

    [DeviceF-erps-ring2-inst1] instance enable
    [DeviceF-erps-ring2-inst1] quit
    [DeviceF-erps-ring2] quit
    

    # Enable CFD, and create a level-5 MD named MD_A.

    [DeviceF] cfd enable
    [DeviceF] cfd md MD_A level 5
    

    # Create Ethernet service instance 5, in which the MA is identified by a VLAN and serves VLAN 5.

    [DeviceF] cfd service-instance 5 ma-id vlan-based md MD_A vlan 5
    

    # Configure a MEP list in Ethernet service instance 5, create outward-facing MEP 5002 in Ethernet service instance 5, and enable CCM sending on FortyGigE 1/0/2.

    [DeviceF] cfd meplist 5001 5002 service-instance 5
    [DeviceF] interface fortygige 1/0/2
    [DeviceF-] cfd mep 5002 service-instance 5 outbound
    [DeviceF-FortyGigE1/0/2] cfd cc service-instance 5 mep 5002 enable
    [DeviceF-FortyGigE1/0/2] quit
    

    # Create Ethernet service instance 7, in which the MA is identified by a VLAN and serves VLAN 7.

    [DeviceF] cfd service-instance 7 ma-id vlan-based md MD_A vlan 7
    

    # Configure a MEP list in Ethernet service instance 7, create outward-facing MEP 7002 in Ethernet service instance 7, and enable CCM sending on FortyGigE 1/0/1.

    [DeviceF] cfd meplist 7001 7002 service-instance 7
    [DeviceF] interface fortygige 1/0/1
    [DeviceF-FortyGigE1/0/1] cfd mep 7002 service-instance 7 outbound
    [DeviceF-FortyGigE1/0/1] cfd cc service-instance 7 mep 7002 enable
    [DeviceF-] quit
    

    # Create track entry 1 and associate it with the CC function of CFD for MEP 5001 in Ethernet service instance 5.

    [DeviceF] track 1 cfd cc service-instance 5 mep 5002
    

    # Associate FortyGigE 1/0/2 with track entry 1 and bring up the port.

    [DeviceF] interface fortygige 1/0/2
    [DeviceF-FortyGigE1/0/2] port erps ring 2 instance 1 track 1
    [DeviceF-FortyGigE1/0/2] undo shutdown
    [DeviceF-FortyGigE1/0/2] quit
    

    # Create track entry 2 and associate it with the CC function of CFD for MEP 7002 in Ethernet service instance 7.

    [DeviceF] track 2 cfd cc service-instance 7 mep 7002
    

    # Associate FortyGigE 1/0/1 with track entry 2 and bring up the port.

    [DeviceF] interface fortygige 1/0/1
    [DeviceF-FortyGigE1/0/1] port erps ring 2 instance 1 track 2
    [DeviceF-FortyGigE1/0/1] undo shutdown
    [DeviceF-FortyGigE1/0/1] quit
    

    # Enable ERPS.

    [DeviceF] erps enable
    

Verifying the configuration

# Display information about ERPS instance 1 for Device A.

[Device A] display erps detail ring 1
 Ring ID               : 1
 Port0                 : FortyGigE1/0/1
 Port1                 : FortyGigE1/0/2
 Subring               : Yes
 Default MAC           : No
 Instance ID           : 1
 Node role             : Owner
 Node state            : Idle
 Connect(ring/instance): -
 Control VLAN          : 100
 Protected VLAN        : Reference-instance 1
 Guard timer           : 500 ms
 Hold-off timer        : 0 ms
 WTR timer             : 5 min
 Revertive operation   : Revertive
 Enable status         : Yes, Active status : Yes
 R-APS level           : 7
 Port                  PortRole                PortStatus
 ----------------------------------------------------------------------------
 Port0                 RPL                     Block
 Port1                 Non-RPL                 Up

The output shows the following information: