This section describes how to configure the automatic adjustment of the tunnel bandwidth.
Automatic bandwidth adjustment is enabled to adjust the bandwidth of the tunnel automatically.
The system periodically collects traffic rates of outbound interfaces on the tunnel and calculates the average bandwidth of the tunnel within a specified period of time. The establishment of an LSP is requested based on the bandwidth constraint of the sampled maximum value of average bandwidth. After the LSP is established, the old LSP is torn down using the make-before-break feature, and the traffic is switched to the new LSP.
The sampling interval is configured in the MPLS view and takes effect on all MPLS TE tunnels. The rate of the outbound interface on an MPLS TE tunnel is recorded at each sampling interval. The actual average bandwidth assigned to the MPLS TE tunnel in a sampling interval can be obtained.
After automatic bandwidth adjustment is enabled, the mpls te timer auto-bandwidth command configures periodic sampling obtains the average bandwidth of the MPLS TE tunnel during a sampling interval. The system recalculates an average bandwidth based on sampling during a sampling interval and uses the bandwidth to establish an MPLS TE tunnel. Traffic switches to the new MPLS TE tunnel, and the original MPLS TE tunnel is torn down. If the MPLS TE tunnel fails to be established, traffic transmission continues along the original MPLS TE tunnel, and the bandwidth is adjusted after the next sampling interval expires.
Before configuring the bandwidth automatic adjustment, configure an RSVP-TE tunnel.
The system view is displayed.
The MPLS view is displayed.
The sampling interval is specified. The actual sampling interval takes the larger value in the mpls te timer auto-bandwidth command and the set flow-stat interval command.
Return to the system view.
The tunnel interface view of the MPLS TE tunnel is displayed.
MPLS TE tunnel statistics can be collected.
Run mpls te auto-bandwidth adjustment { [ threshold percent [ [ or ] absolute-bw absolute-bw ] ] | frequency interval | [ max-bw max-bandwidth | min-bw min-bandwidth ] * | [ overflow-limit overflow-limit-value ] | [ underflow-limit underflow-limit-value ] } *
The automatic bandwidth adjustment is enabled. The frequency and allowable bandwidth range for adjustment are configured.
The following policies can be configured to control automatic bandwidth adjustment:
frequency interval sets the interval for bandwidth adjustment. After the mpls te auto-bandwidth command is run, a device must accumulatively sample bandwidth values for at least two times within a configured interval time. If the device samples bandwidth values for less than two times within the specified interval, automatic bandwidth adjustment is not performed. The existing sampling times are counted in the next bandwidth adjustment interval.
You can use the threshold percent [ [ or ] absolute-bw absolute-bw ] parameter to determine whether or not to adjust bandwidth.
The system compares the average bandwidth within a sampling period with the actual bandwidth, and the bandwidth will be automatically adjusted if the ratio of bandwidth change to the actual bandwidth is greater than the threshold value. If the absolute threshold is set, bandwidth can be automatically adjusted only after the bandwidth change also exceeds the absolute threshold.
Therefore, if the network traffic changes frequently but frequent bandwidth adjustment is not needed, you can set a greater threshold value.
The or parameter is configured to perform a bitwise OR operation between the absolute bandwidth threshold and the threshold percentage for bandwidth adjustment. Automatic bandwidth adjustment is triggered once either the absolute bandwidth threshold or the threshold percentage is reached. If or is not configured, the bitwise AND operation is performed by default, so that automatic bandwidth adjustment can only be triggered after both the absolute bandwidth threshold and threshold percentage are reached.
Run mpls te auto-bandwidth collect-bw { [ frequency interval ] | [ max-bw max-bandwidth | min-bw min-bandwidth ] * } *
The frequency and allowable bandwidth range for collection are configured.
The configuration is committed.
After completing the configuration, run the display mpls te tunnel-interface command on the ingress of the tunnel to view the following tunnel configuration information.