Before you begin
Ensure that peer devices are also configured for Priority Flow Control on the same class of service (CoS).
Follow these steps to configure buffer-internal thresholds.
Procedure
|
1. |
Enter the line card profile configuration.
Example:
Router(config)#hw-module profile priority-flow-control mode buffer-internal
This example selects buffer-internal mode for PFC on the line card.
|
|
2. |
Configure thresholds per traffic class.
Example:
Router(config-pfc-profile)#traffic-class 3
Router(config-pfc-profile-tc)#pause-threshold 307200
Router(config-pfc-profile-tc)#headroom 345600
Router(config-pfc-profile-tc)#ecn-threshold 153600
Each value in this example is described here.
-
traffic-class 3 : Selects traffic class 3 out of 0–7. This TC is tied to a Layer 2 CoS (802.1p) or an internal mapping, so your QoS policy should map the desired CoS or DSCP to traffic class 3 if you want this class to be lossless.
-
pause-threshold 307200 : When instantaneous buffer occupancy for TC 3 reaches 307,200 bytes, the device starts sending PFC pause frames for priority 3. This prevents loss by pausing upstream senders before the queue overflows.
-
headroom 345600 : This is the reserved buffer for traffic class 3 to absorb traffic after a pause is asserted. It's the guaranteed space the queue can grow into while the pause takes effect.
-
ecn-threshold 153600 : Explicit Congestion Notification (ECN) marking begins once occupancy exceeds 153,600 bytes. This value should be lower than the pause threshold so congestion is signaled (via ECN) before resorting to PFC pauses.
|
|
3. |
(Optional) Configure ECN maximum threshold and probability percentage (Pmax).
Example:
Router(config-pfc-profile-tc)#ecn-max-threshold 403200
Router(config-pfc-profile-tc)#probability-percentage 5
Router(config-pfc-profile-tc)#exit
Router(config-pfc-profile)#exit
Router(config)#commit
Here's what each value indicates in this example.
-
ecn-max-threshold 403200 : Upper bound of the ECN marking ramp. Between ecn-threshold and ecn-max-threshold , marking probability increases linearly. At or above this level, the marking probability reaches the configured maximum percentage (Pmax).
-
probability-percentage 5 : Indicates 5% as the maximum ECN marking probability (Pmax) at the ecn-max-threshold value. In effect, this means that there will be 0% marking at 153,600 bytes, linearly increasing to 5% at 403,200 bytes and above.
|
|
4. |
View the configured thresholds and runtime counters for the specific line card.
Example:
Router#show controllers npu priority-flow-control location 0/0/CPU0
TC Pause-threshold Headroom ECN-threshold ECN-max Pmax TxPause
3 307200 345600 153600 403200 5% 24
Each value in this example is described here.
-
TC : Traffic Class (3)
-
Pause-threshold : 307,200 bytes (pause onset).
-
Headroom : 345,600 bytes (reserved buffer after pause).
-
ECN-threshold : 153,600 bytes (start of ECN marking).
-
ECN-max : 403,200 bytes (top of ECN ramp).
-
Pmax : 5% (maximum ECN marking probability).
-
TxPause : 24 (number of PFC pause frames transmitted for this TC).
|