(Optional) Configuring a PW Template

A PW template is a collection of common PW attributes. Configuring PWs using a PW template helps save configuration workload.

Context

Before configuring PWs with similar attributes, you can define a PW template that contains the common attributes of these PWs. Then, you can configure these PWs based on the PW template to simplify the configuration process. For example, if multiple VPWS connections with the same MTU, peer address, control word setting, and tunnel policy need to be configured between two PEs, you can define these common attributes in a PW template and use the PW template to configure these PWs on different PE interfaces.

Perform the following steps on the PEs at both ends of a PW to be established.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run mpls l2vpn

    MPLS L2VPN is enabled.

  3. Run quit

    Return to the system view.

  4. Run pw-template pwname

    A PW template is created, and the PW template view is displayed.

    If some PW attributes configured using the mpls l2vc command are different from those specified in the PW template, the PW attributes configured using the mpls l2vc command take precedence.

  5. Configure PW attributes. The following steps are optional and can be selected as required.

    • Run the peer-address ip-address command to specify an IP address for the remote PE on the PW.
    • Run the control-word command to enable the control word function.
    • Run the mtu mtu-value command to configure the MTU in the PW template.
    • Run the flow-label { both | send | receive } [ static ] command to enable flow label-based load balancing.

  6. Run commit

    The configuration is committed.

Follow-up Procedure

After the PW attributes in a PW template are modified, run the reset pw pw-template pw-template-name command for the modifications to take effect. Running this command will cause PWs referencing this PW template to reset. If multiple PWs are referencing this template, system operation is affected.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >