< Home

(Optional) Creating a PW Template and Setting Attributes for the PW Template

Context

A PW template defines common attributes for PWs, so it can be shared by different PWs. You can run the pw-template command to define some common attributes in a PW template to simplify PW configuration. After creating a PW on an interface, you can apply a PW template to the interface.

On the device, you can bind a PW template to a PW or reset the PW.

You can set the attributes for a PW through commands or a PW template. The attributes include the peer, tunnel policy, and control word. Importing the PW template can simplify the configuration of PWs with similar attributes.

  • Some PW attributes such as the MTU, PW type, and encapsulation type are obtained from the interface connecting the PE to the CE.

  • If you specify a PW attribute through a command, the same PW attribute specified in the PW template does not take effect on the PW to which this PW template is applied.

Perform the following operations on the PEs.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run pw-template pw-template-name

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

  3. Run peer-address ip-address

    A remote IP address is assigned to a PW template.

  4. Run control-word

    The control word function is enabled.

    By default, the control word function is disabled.

    For dynamic single-segment PWs, dynamic multi-segment PWs, and static single-segment PWs, VCCV in control word mode must be enabled on the UPEs. For static and mixed multi-segment PWs, VCCV in control word mode must be enabled on both the UPEs and SPEs.

  5. Run mtu mtu-value

    The MTU in the PW template is specified.

    By default, the MTU in a PW template is 1500.

  6. Run tnl-policy policy-name

    A tunnel policy is configured for the PW template.

    Configure a tunnel policy before you can apply this policy. If no tunnel policy is configured, an LSP tunnel is used and load balancing is not implemented. For details on how to configure a tunnel policy, see step 1 in Configuring and Applying a Tunnel Policy.

After modifying the attributes of a PW template, run the reset pw pw-template command in the user view to make the modification take effect. This will cause PW disconnection and reconnection. If multiple PWs use this template simultaneously, system operation is affected.

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