The tnl-policy command specifies a tunnel policy for PWs applying a PW template.
The undo tnl-policy command restores the default configuration.
By default, no tunnel policy is specified for PWs applying a PW template.
Usage Scenario
If no tunnel policy is configured, the tunnel management module searches for a tunnel according to the default policy. In VPWS, an LDP LSP is used by default and load balancing is performed if there are more than one LDP LSPs for the same destination address. If it is required that the sequence in which tunnels are selected and the number of tunnels for load balancing be specified or tunnels be selected based on peer IP addresses, run the tnl-policy command to specify a tunnel policy for PWs applying the PW template.
Prerequisites
Configuration Impact
Applying a tunnel policy to a device changes the rules for forwarding services. You can manually configure the PW that each tunnel can bear by planning network resources and setting up tunnels with different QoS features. Then, network resources can be fully used.
Follow-up Procedure
Apply a configured PW template when creating an LDP or SVC VPWS connection on an interface.
Precautions
The tunnel policy applied by a PW must already be created in the system view. Otherwise, the VPWS connection cannot go Up.
If a tunnel policy is configured in a PW template and another tunnel policy is configured using the mpls l2vc or mpls static-l2vc command on the interface, the tunnel policy configured on the interface prevails.<HUAWEI> system-view [~HUAWEI] tunnel-policy policy1 [~HUAWEI-tunnel-policy-policy1] quit [~HUAWEI] mpls [*HUAWEI-mpls] quit [*HUAWEI] mpls l2vpn [*HUAWEI-l2vpn] quit [*HUAWEI] pw-template pwt [*HUAWEI-pw-template-pwt] tnl-policy policy1