CCNP ONT Notes

4 Apr 2008

Chapter 4: Congestion Management and Queuing

The default queuing method on an interface faster than 2.048 Mbps is First In, First Out (FIFO). Interfaces operating at 2.048 Mbps or slower perform Weighted Fair Queuing (WFQ).

Each physical interface has hardware and software queuing mechanisms; software queues are only used when the hardware queue is congested.

Tail-drop occurs when all queues are full and a packet is dropped.

Hardware queue sizes can be configured with tx-ring-limit and verified with show controllers <interface>.

Simple Queuing

First-In-First-Out (FIFO)

Packets are transmitted in the order they are received with no preference (no QoS).

FIFO is the default mechanism for interfaces >2.048Mbps.

Priority Queuing (PQ)

PQ provides four queues: high, medium, normal, and low.

All packets in a higher priority queue will be processed before any packets in a lower priority queue.

Lower priority queues can be starved if higher priority queues consume all available bandwidth.

PQ is implemented by defining and applying priority lists:

Router(config)# priority-list 1 {interface | protocol} ...
 {high | medium | normal | low}

Round Robin (RR)

All queues are equal priority; one packet is taken from each queue per cycle.

Round robin does not provide for traffic prioritization, and queues with larger packets will consume more bandwidth than queues with smaller packets.

Weighted Round Robin (WRR)

WRR is a modification to RR which allows for disproportionate allowance of bandwidth to queues.

Custom Queuing (CQ) is an example of WRR; it specifies a certain number of bytes to be processed from each queue.

Weighted Fair Queuing

WFQ is the default mechanism on and only supported on interfaces less than or equal to 2.048 Mbps.

WFQ queues are created per flow and are not configurable.

Each flow is assigned to a dynamic FIFO queue by source/destination IP address, protocol number, ToS value, or source/destination port number.

The maximum number of dynamic queues is configurable between 16 - 4096 (256 by default).

Packets are dropped from aggressive flows more frequently than from less aggressive flows.

The hold queue is the sum of all memory available to the WFQ system; all packets are aggressively dropped while the hold queue is full.

Each queue has a Congestive Discard Threshold (CDT) which allows for early dropping of packets before the queue is completely full.

WFQ can be disabled on an interface with no fair-queue (queuing is switched to FIFO).

Queue information can be viewed with show interface or show queue <interface>.

Class-Based Weighted Fair Queuing (CBWFQ)

CBWFQ is similar to WFQ but with user-defined queue classes instead of dynamically created flow-based queues.

CBWFQ supports a maximum of 64 queues.

Each queue is allotted a certain amount or percentage of the available bandwidth.

The default queue named class-default is always present and will match all traffic not matched by other queues.

Bandwidth can be allocated in Kbps, percentage, or remaining percentage. All classes within a policy map must use the same unit of measure (Kbps or percentage).

The default maximum reserved bandwidth is 75%; this can be modified with max-reserved-bandwidth (applied to the interface).

Fair queuing (instead of FIFO) can be enabled for the default class with fair-queue followed by the maximum number of dynamic queues.

The queue size for each class can be adjusted with queue-limit.

Configuration example:

policy-map Foo
 class Critical_Apps
  bandwidth percent 20
  queue-limit 50
 class Normal_Apps
  bandwidth remaining recent 50
 class class-default
  fair-queue 32

Low Latency Queuing (LLQ)

LLQ implements a strict-priority queue which is favored over all other queues.

LLQ is typically used for delay-sensitive traffic like VOIP.

The priority queue is policed to a certain bandwidth to prevent starvation of other queues.

Priority queues are created under a class with priority <bandwidth> or priority percent <percentage>.

Configuration example:

policy-map Foo
 class VOIP
  priority 128
 class Important_Stuff
  bandwidth 512
  queue-limit 100
 class class-default
  fair-queue 32

show policy-map [interface] can be used to inspect policy maps.

Leave a comment

(optional, will not be published)
(optional)

Comment Tips

  • You can use Markdown syntax for decoration. (Cheat sheet)
  • Links: [Google](http://google.com) or <http://google.com>
  • Use backticks around commands: `ip address 127.0.0.1`
  • Use indentations (tabs) for preformatted text (code blocks)