traffic-policy
Use traffic-policy to nest a policy in a traffic behavior.
Use undo traffic-policy to remove child policies from a traffic behavior.
Syntax
traffic-policy policy-name
undo traffic-policy
Default
No policy is nested in a traffic behavior.
Views
Traffic behavior view
Predefined user roles
network-admin
Parameters
policy-name: Specifies a policy by its name, a string of 1 to 31 characters. If the policy does not exist, it is automatically created.
Usage guidelines
After you nest a child policy in a behavior of a parent policy, the system performs the following operations:
Performs the associated behavior defined in the parent policy for a class of traffic.
Uses the child policy to further classify the class of traffic and performs the behaviors defined in the child policy.
When you nest QoS policies, follow these guidelines:
A parent policy can nest up to two layers of child policies. This child policy cannot be the parent policy itself.
You can nest only one child policy at one layer of a behavior.
To configure CBQ in the child policy successfully, configure GTS in the parent policy. Make sure the configured GTS bandwidth is greater than CBQ bandwidth configured in the child policy.
If GTS bandwidth is set in percentage in the parent policy, you must set CBQ bandwidth in percentage in the child policy. If GTS bandwidth is set as an absolute value in the parent policy, you can set CBQ bandwidth in either format in the child policy.
A child policy cannot contain GTS actions.
Policy nesting is available for IPv4 and IPv6 packets.
To delete the child policy after you apply the parent policy to an interface, first remove the child policy from the parent policy.
Examples
# Nest child policy child in traffic behavior database of the parent policy.
<Sysname> system-view [Sysname] traffic behavior database [Sysname-behavior-database] traffic-policy child
Related commands
traffic behavior
traffic classifier