< Home

color

Function

The color command sets parameters of a WRED drop file, including the upper drop threshold, lower drop threshold, and maximum drop probability.

The undo color command restores the default settings of a WRED drop profile.

By default, the upper drop threshold, lower drop threshold, and maximum drop probability of a WRED drop profile are all 100.

Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S support this command.

Format

color { green | non-tcp | red | yellow } low-limit low-limit-percentage high-limit high-limit-percentage discard-percentage discard-percentage

undo color { green | non-tcp | red | yellow }

Only the S5720-EI, S6720-EI, and S6720S-EI support the non-tcp parameter.

Parameters

Parameter

Description

Value

green

Sets WRED parameters for green packets.

-

non-tcp

Sets WRED parameters for non-TCP packets.

-

red

Sets WRED parameters for red packets.

-

yellow

Sets WRED parameters for yellow packets.

-

low-limit low-limit-percentage

Specifies the lower drop threshold. When the percentage of the packet count in a queue to the queue length reaches this value, the switch starts to discard packets.

The value is an integer that ranges from 0 to 100, in percentage. The default value is 100.

high-limit high-limit-percentage

Specifies the upper drop threshold. When the percentage of the packet count in a queue to the queue length reaches this value, the switch discards all subsequent packets.

The value is an integer that ranges from low-limit-percentage to 100, in percentage. The default value is 100.

discard-percentage discard-percentage

Specifies the maximum drop probability.

The value is an integer that ranges from 1 to 100, in percentage. The default value is 100.

Views

Drop profile view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

When packets enter a switch, the switch colors packets based on the mappings defined in a DiffServ domain. The system processes the packets of different colors based on the WRED configuration:
  • When the queue length reaches the lower drop threshold, the switch discards some packets.
  • When the queue length reaches the upper drop threshold, the switch discards all subsequent packets in the queue.

When congestion occurs, the switch first discards packets with the highest drop probability.

Precautions

If multiple interfaces are congested and packets cannot be forwarded at the line rate on some interfaces on the S5730-HI, S5731-H, S5731-S, S5731S-H, and S5731S-S, you can run the display qos queue statistics command to check queues in which packets are discarded on the congested interfaces and run the color command to decrease the upper drop threshold, lower drop threshold, and maximum drop probability. This ensures that packets can be properly forwarded at the line rate on all interfaces.

If you run the color command multiple times in the same drop profile view, only the latest configuration takes effect.

Example

# Configure WRED drop profile wred1 in which the lower drop threshold, upper drop threshold, and maximum drop probability of green packets are set to 80, 100, and 10 for green packets, to 60, 80, and 20 for yellow packets, and to 40, 60, and 40 for red packets.

<HUAWEI> system-view
[HUAWEI] drop-profile wred1
[HUAWEI-drop-wred1] color green low-limit 80 high-limit 100 discard-percentage 10
[HUAWEI-drop-wred1] color yellow low-limit 60 high-limit 80 discard-percentage 20
[HUAWEI-drop-wred1] color red low-limit 40 high-limit 60 discard-percentage 40
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >