The qos queue max-buffer command sets the maximum number of bytes in all packets to be cached in a queue.
The undo qos queue max-buffer command restores the default maximum number of bytes in all packets to be cached in a queue.
The qos queue green max-buffer command sets the maximum number of bytes in green packets to be cached in a queue.
The undo qos queue green max-buffer command restores the default maximum number of bytes in green packets to be cached in a queue.
By default, the maximum buffer size of all packets in a queue is 24 and the maximum buffer size of green packets in a queue is 12, in cells. The size of a cell is 128 bytes.
Only the S2720-EI, S5720I-SI, S5720-LI, S5720S-LI, S5720S-SI, S5720-SI, S5730S-EI, S5730-SI, S6720-LI, S6720S-LI, S6720S-SI, and S6720-SI support this command.
qos queue queue-index max-buffer cell-number [ green max-buffer cell-number ]
undo qos queue queue-index max-buffer [ cell-number green max-buffer cell-number | green max-buffer ]
qos queue queue-index green max-buffer cell-number
undo qos queue queue-index green max-buffer
Parameter |
Description |
Value |
---|---|---|
queue queue-index |
Specifies the index of a queue. |
The value is an integer that ranges from 0 to 7. |
max-buffer cell-number |
Specifies the maximum number of bytes in all packets to be cached in a queue. |
The value is an integer, in cells. The value range is as follows:
The size of a cell is 128 bytes. |
green max-buffer cell-number |
Specifies the maximum number of bytes in green packets to be cached in a queue. |
The value is an integer, in cells. The value range is as follows:
The size of a cell is 128 bytes. |
non-green max-buffer cell-number |
Specifies the maximum number of bytes in non-green packets to be cached in a queue. |
The value is an integer that ranges from 1920 to 3100, in cells. The size of a cell is 128 bytes. |
Usage Scenario
When congestion occurs, the switch uses the tail drop method. When the queue length reaches the upper limit, excess packets (buffered at the queue tail) are discarded until congestion is removed. You can run the qos queue max-buffer command to set the maximum number of bytes in all packets or green packets to be cached in a queue so that the queue has sufficient buffer, preventing packet loss.
Prerequisites
A tail drop profile has been created using the qos tail-drop-profile (system view) command.
Precautions
You can also use the qos queue max-length command to set the maximum number of packets to be cached in a queue. If the maximum number of bytes or packets is reached, the device considers that congestion occurs and will discard subsequent packets.