Back to Dashboard
Module 42
Queuing Mechanisms (Deep Dive)
β Previous Module
Next Module β
# π CCNA 200-301 - Video 42: Queuing Mechanisms (Deep Dive) ## Deep Study Notes --- ## π Learning Objectives By the end of this video, you should understand: - Why queuing is necessary - Different queuing mechanisms (FIFO, PQ, CQ, WFQ, CBWFQ, LLQ) - How each queuing mechanism works - When to use each queuing type - Configuration and verification of queuing - Queuing best practices --- ## π§ Core Concepts ### 1. Why Queuing? **Definition:** Queuing is the process of temporarily storing packets in buffers when the output interface is busy, then transmitting them in an organized order based on configured policies. **Analogy:** Think of queuing like different checkout lanes at a supermarket: - **FIFO:** One line, first-come-first-served - **Priority Queuing:** Express lane for customers with few items (priority traffic) - **Custom Queuing:** Dedicated lanes for different types of customers (each gets guaranteed service) - **WFQ:** Fair distribution, no one waits too long ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β WHY QUEUING IS NEEDED β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Without Queuing: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Incoming Traffic: Voice, Video, Data, Backup β β β β β β β β β βΌ β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β No Queue β β β β β β Packets dropped when interface busy β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β β β βΌ β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β Interface β β β β β β (Transmitting at line rate) β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β β Result: All traffic treated equally, important packets dropped β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β With Queuing: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Incoming Traffic: Voice, Video, Data, Backup β β β β β β β β β βΌ β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β Queuing System β β β β β β β β β β β β High Priority: Voice β Voice β Voice β β β β β β Medium Priority: Video β Video β β β β β β Low Priority: Data β Data β Backup β β β β β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β β β βΌ β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β Interface β β β β β β (Transmitting at line rate) β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β β Result: Priority traffic transmitted first, fair allocation β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` --- ### 2. Queuing Mechanisms Overview | Mechanism | Type | Description | Pros | Cons | |-----------|------|-------------|------|------| | **FIFO** | First-In-First-Out | Single queue, no prioritization | Simple, low overhead | No QoS | | **PQ** | Priority Queuing | Multiple queues, strict priority | Low latency for priority traffic | Starvation possible | | **CQ** | Custom Queuing | Multiple queues, round-robin | Guaranteed bandwidth | Complex configuration | | **WFQ** | Weighted Fair Queuing | Flow-based, automatic | Fair, no configuration | Limited control | | **CBWFQ** | Class-Based WFQ | Class-based, guaranteed bandwidth | Granular control | Moderate complexity | | **LLQ** | Low-Latency Queuing | Priority + CBWFQ | Voice + data | Priority queue limits | ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β QUEUING MECHANISMS COMPARISON β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β FIFO (First-In-First-Out): β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β [Packet1] β [Packet2] β [Packet3] β [Packet4] β Transmit β β β β β β β β β’ Single queue β β β β β’ No prioritization β β β β β’ Default on high-speed interfaces (2 Mbps+) β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β PQ (Priority Queuing): β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β High β [Voice] [Voice] β Transmit first β β β β Medium β [Video] β Transmit when high empty β β β β Normal β [Data] β Transmit when high/medium empty β β β β Low β [Backup] β Transmit when all others empty β β β β β β β β β’ 4 priority levels (High, Medium, Normal, Low) β β β β β’ Strict priority β β β β β’ Risk: Low priority queues may starve β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β CQ (Custom Queuing): β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Queue 1: [Voice] β [Voice] β (up to 1500 bytes) β β β β Queue 2: [Video] β [Video] β (up to 1500 bytes) β β β β Queue 3: [Data] β [Data] β (up to 1500 bytes) β β β β Queue 4: [Backup] β (up to 1500 bytes) β β β β β β β β β’ Round-robin service β β β β β’ Each queue gets configured byte count β β β β β’ Guaranteed bandwidth per queue β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β WFQ (Weighted Fair Queuing): β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Flow 1: βDataβDataβ (weight based on IP precedence) β β β β Flow 2: βVoiceβVoiceβ (higher weight β more bandwidth) β β β β Flow 3: βVideoβVideoβ β β β β β β β β β’ Automatic flow classification β β β β β’ Fair sharing of bandwidth β β β β β’ Default on low-speed interfaces (2 Mbps or less) β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` --- ### 3. FIFO (First-In-First-Out) **Description:** Simplest queuing method where packets are transmitted in the order they arrive. ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β FIFO OPERATION β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Incoming Order: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β A β B β C β D β E β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β βΌ β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β FIFO Queue β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β [A] [B] [C] [D] [E] β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β βΌ β β Transmitted Order: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β A β B β C β D β E β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Characteristics: β β β’ Default on high-speed interfaces (2 Mbps or greater) β β β’ Single queue β β β’ No prioritization β β β’ Simple but no QoS guarantees β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` **FIFO Configuration:** ```cisco ! FIFO is default on high-speed interfaces interface GigabitEthernet0/0 no fair-queue ! Disable WFQ, enable FIFO ``` --- ### 4. PQ (Priority Queuing) **Description:** Four priority queues (High, Medium, Normal, Low). Higher priority queues are always serviced first. ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β PQ OPERATION β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Classification: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β High: Voice traffic (RTP) β β β β Medium: Video traffic β β β β Normal: Data traffic (HTTP, HTTPS) β β β β Low: Backup traffic β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Queues: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β High β Voice β Voice β Voice β β Always serviced first β β β β Medium β Video β Video β β β Serviced when high empty β β β β Normal β Data β Data β Data β β Serviced when high/medium emptyβ β β β Low β Backupβ Backupβ β β Serviced only when others emptyβ β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Characteristics: β β β’ Strict priority (high always serviced first) β β β’ Risk: Low priority queues may starve β β β’ 4 queues (High, Medium, Normal, Low) β β β’ Legacy mechanism (replaced by LLQ) β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` **PQ Configuration:** ```cisco ! Define priority list priority-list 1 protocol ip high tcp 22 ! SSH high priority priority-list 1 protocol ip medium tcp 80 ! HTTP medium priority priority-list 1 protocol ip normal tcp 21 ! FTP normal priority priority-list 1 default low ! Apply to interface interface Serial0/0/0 priority-group 1 ``` --- ### 5. CQ (Custom Queuing) **Description:** Multiple queues (up to 16) serviced in round-robin fashion, each with configurable byte count. ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β CQ OPERATION β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Queues with Byte Counts: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Queue 1: [Voice] [Voice] [Voice] (1500 bytes) β β β β Queue 2: [Video] [Video] [Video] (1500 bytes) β β β β Queue 3: [Data] [Data] [Data] (1500 bytes) β β β β Queue 4: [Backup] (500 bytes) β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Round-Robin Service: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Cycle 1: Queue 1 (1500 bytes) β Queue 2 (1500 bytes) β β β β β Queue 3 (1500 bytes) β Queue 4 (500 bytes) β β β β β β β β Cycle 2: Queue 1 (1500 bytes) β Queue 2 (1500 bytes) β β β β β Queue 3 (1500 bytes) β Queue 4 (500 bytes) β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Bandwidth Allocation: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Each queue gets guaranteed bandwidth based on byte count β β β β β’ Bandwidth % = Queue Byte Count / Total Byte Count Γ 100 β β β β β’ Example: Total = 5000 bytes, Queue 1 = 1500 β 30% bandwidth β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` **CQ Configuration:** ```cisco ! Define custom queue list queue-list 1 protocol ip 1 tcp 22 ! SSH to queue 1 queue-list 1 protocol ip 2 tcp 80 ! HTTP to queue 2 queue-list 1 protocol ip 3 tcp 21 ! FTP to queue 3 queue-list 1 default 4 ! Default to queue 4 queue-list 1 queue 1 byte-count 1500 ! Queue 1 gets 1500 bytes per cycle queue-list 1 queue 2 byte-count 1500 ! Queue 2 gets 1500 bytes per cycle queue-list 1 queue 3 byte-count 1500 ! Queue 3 gets 1500 bytes per cycle queue-list 1 queue 4 byte-count 500 ! Queue 4 gets 500 bytes per cycle ! Apply to interface interface Serial0/0/0 custom-queue-list 1 ``` --- ### 6. WFQ (Weighted Fair Queuing) **Description:** Automatically classifies traffic into flows based on source/destination IP, port, protocol. Each flow gets fair share of bandwidth, with weights based on IP precedence. ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β WFQ OPERATION β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Flow Classification: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β Flow 1: Source IP A, Dest IP B, Port 80 β β β β Flow 2: Source IP A, Dest IP C, Port 80 β β β β Flow 3: Source IP B, Dest IP D, Port 22 β β β β Flow 4: Source IP C, Dest IP E, Port 443 β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Weight Calculation: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Weight = 4096 / (IP Precedence + 1) β β β β β’ Lower weight = more bandwidth β β β β β β β β IP Precedence 0 (Best Effort): Weight = 4096 β β β β IP Precedence 5 (Voice): Weight = 4096 / 6 = 682 β β β β β β β β Higher precedence = lower weight = more bandwidth β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Service: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Fair sharing among active flows β β β β β’ Low-volume flows get priority β β β β β’ Prevents one flow from dominating bandwidth β β β β β’ Default on low-speed interfaces (2 Mbps or less) β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` **WFQ Configuration:** ```cisco ! Enable WFQ on interface interface Serial0/0/0 fair-queue fair-queue queue-limit 64 ! Default queue limit fair-queue congestive-discard-threshold 64 ! WFQ is default on low-speed interfaces ``` --- ### 7. CBWFQ (Class-Based Weighted Fair Queuing) **Description:** Extends WFQ by allowing user-defined classes with guaranteed bandwidth. ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β CBWFQ OPERATION β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Class Definitions: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Class Voice: 30% bandwidth (strict) β β β β Class Video: 25% bandwidth (guaranteed) β β β β Class Data: 20% bandwidth (guaranteed) β β β β Default: 25% bandwidth (remaining) β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Queue Structure: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Voice Queue β Video Queue β Data Queue β Default Queue β β β β (30%) β (25%) β (20%) β (25%) β β β β [Voice][Voice] β [Video][Video]β [Data][Data] β [BE][BE] β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Service: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Each class gets guaranteed bandwidth β β β β β’ Unused bandwidth shared among classes β β β β β’ No priority queue (use LLQ for voice) β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` **CBWFQ Configuration:** ```cisco ! Class maps class-map VOICE match ip dscp ef class-map VIDEO match ip dscp af41 class-map DATA match ip dscp af31 ! Policy map policy-map CBWFQ-POLICY class VOICE bandwidth percent 30 class VIDEO bandwidth percent 25 class DATA bandwidth percent 20 class class-default bandwidth percent 10 fair-queue ! Apply to interface interface Serial0/0/0 service-policy output CBWFQ-POLICY ``` --- ### 8. LLQ (Low-Latency Queuing) **Description:** Combines strict priority queue (for voice/video) with CBWFQ (for other traffic). This is the recommended queuing mechanism for voice and video deployments. ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β LLQ OPERATION β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β Queue Structure: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β Priority Queue (LLQ) β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β Voice: Always serviced first (strict priority) β β β β β β Max 33% of bandwidth (prevents starvation) β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β β CBWFQ Queues β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β Video: 25% guaranteed bandwidth β β β β β β Data: 20% guaranteed bandwidth β β β β β β Default: Remaining bandwidth β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Service Order: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β β β 1. Service Priority Queue (Voice) until empty β β β β 2. Service CBWFQ queues in round-robin β β β β 3. Any unused priority bandwidth shared with CBWFQ β β β β β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β Advantages: β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Low latency for voice/video β β β β β’ Guaranteed bandwidth for other classes β β β β β’ Prevents voice starvation β β β β β’ Recommended for converged networks β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` **LLQ Configuration:** ```cisco ! Class maps class-map VOICE match ip dscp ef class-map VIDEO match ip dscp af41 class-map DATA match ip dscp af31 ! Policy map with LLQ policy-map LLQ-POLICY class VOICE priority percent 30 ! Strict priority queue class VIDEO bandwidth percent 25 ! Guaranteed bandwidth class DATA bandwidth percent 20 ! Guaranteed bandwidth class class-default bandwidth percent 10 fair-queue ! Apply to interface interface Serial0/0/0 service-policy output LLQ-POLICY ``` --- ### 9. Queuing Mechanism Selection Guide ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β QUEUING SELECTION GUIDE β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β QUESTION 1: Is there congestion? β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β NO β Use FIFO (no queuing needed) β β β β YES β Continue β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β βΌ β β QUESTION 2: Do you need to differentiate traffic? β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β NO β Use WFQ (fair sharing without classification) β β β β YES β Continue β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β β βΌ β β QUESTION 3: Do you have voice/video traffic? β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β YES β Use LLQ (priority queue + CBWFQ) β β β β NO β Use CBWFQ (guaranteed bandwidth per class) β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` --- ### 10. Queuing Verification Commands | Command | Purpose | |---------|---------| | `show policy-map interface [int]` | Display queuing statistics | | `show queueing interface [int]` | Display queue statistics | | `show interfaces [int]` | Display interface drops | | `show running-config | section policy-map` | Display policy map config | | `debug policy-map` | Debug QoS policy | **Example Outputs:** ```cisco Router# show policy-map interface serial 0/0/0 Serial0/0/0 Service-policy output: LLQ-POLICY Class-map: VOICE (match-all) 1234 packets, 123456 bytes 5 minute offered rate 1000 bps, drop rate 0 bps Match: dscp ef (46) Strict Priority Output Queue: Conversation 264 Bandwidth 30 (%) Bandwidth 300 (kbps) Burst 7500 (Bytes) (pkts matched/bytes matched) 1234/123456 (total drops/bytes drops) 0/0 Class-map: VIDEO (match-all) 5678 packets, 567890 bytes 5 minute offered rate 2000 bps, drop rate 0 bps Match: dscp af41 (34) Queueing Output Queue: Conversation 265 Bandwidth 25 (%) Bandwidth 250 (kbps) Max Threshold 64 (packets) (pkts matched/bytes matched) 5678/567890 (depth/total drops/no-buffer drops) 0/0/0 Class-map: class-default (match-any) 9012 packets, 901234 bytes 5 minute offered rate 5000 bps, drop rate 0 bps Match: any Queueing Output Queue: Conversation 266 Bandwidth 10 (%) Bandwidth 100 (kbps) Max Threshold 64 (packets) (pkts matched/bytes matched) 9012/901234 (depth/total drops/no-buffer drops) 0/0/0 ``` --- ### 11. Queuing Best Practices ``` βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β QUEUING BEST PRACTICES β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€ β β β 1. USE LLQ FOR VOICE AND VIDEO β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Voice requires strict priority (low latency) β β β β β’ Limit priority queue to 33% of bandwidth β β β β β’ Use CBWFQ for other classes β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β 2. ALLOCATE BANDWIDTH BASED ON BUSINESS NEEDS β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Voice: 30% (priority) β β β β β’ Video: 25% (guaranteed) β β β β β’ Mission-critical data: 20% (guaranteed) β β β β β’ Best effort: remaining β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β 3. AVOID OVER-SUBSCRIPTION β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Total guaranteed bandwidth should not exceed link capacity β β β β β’ Leave bandwidth for best-effort traffic β β β β β’ Example: 33% + 25% + 20% = 78% (leave 22% for BE) β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β 4. MONITOR DROPS β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ Check drop counters regularly β β β β β’ Adjust bandwidth allocations if drops occur β β β β β’ Investigate priority queue drops (possible misconfiguration) β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β 5. APPLY QUEUING ON CONGESTED INTERFACES β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β β’ WAN interfaces (slower links) β β β β β’ Uplinks to distribution β β β β β’ Interfaces facing internet β β β β β’ No need for queuing on under-utilized links β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β β β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ``` --- ## π§ Complete Configuration Examples ### Lab 1: FIFO Configuration ```cisco ! Enable FIFO on high-speed interface interface GigabitEthernet0/0 no fair-queue ! Disable WFQ ! FIFO is default when no other queuing configured ``` --- ### Lab 2: PQ Configuration ```cisco ! Priority list configuration priority-list 1 protocol ip high tcp 22 ! SSH high priority priority-list 1 protocol ip high udp 53 ! DNS high priority priority-list 1 protocol ip medium tcp 80 ! HTTP medium priority priority-list 1 protocol ip medium tcp 443 ! HTTPS medium priority priority-list 1 protocol ip normal tcp 21 ! FTP normal priority priority-list 1 default low interface Serial0/0/0 priority-group 1 ``` --- ### Lab 3: CQ Configuration ```cisco ! Custom queue list queue-list 1 protocol ip 1 tcp 22 ! SSH queue 1 queue-list 1 protocol ip 1 udp 53 ! DNS queue 1 queue-list 1 protocol ip 2 tcp 80 ! HTTP queue 2 queue-list 1 protocol ip 2 tcp 443 ! HTTPS queue 2 queue-list 1 protocol ip 3 tcp 21 ! FTP queue 3 queue-list 1 default 4 ! Default queue 4 queue-list 1 queue 1 byte-count 1500 ! 1500 bytes per cycle queue-list 1 queue 2 byte-count 1500 queue-list 1 queue 3 byte-count 1500 queue-list 1 queue 4 byte-count 500 interface Serial0/0/0 custom-queue-list 1 ``` --- ### Lab 4: CBWFQ Configuration ```cisco ! Class maps class-map match-any CRITICAL match ip dscp af31 af32 af33 class-map match-any BUSINESS match ip dscp af21 af22 af23 class-map match-any SCAVENGER match ip dscp cs1 ! Policy map policy-map CBWFQ-WAN class CRITICAL bandwidth percent 30 class BUSINESS bandwidth percent 25 class SCAVENGER bandwidth percent 5 class class-default bandwidth percent 20 fair-queue interface Serial0/0/0 service-policy output CBWFQ-WAN ``` --- ### Lab 5: LLQ Configuration (Recommended) ```cisco ! Class maps class-map VOICE match ip dscp ef class-map VIDEO match ip dscp af41 class-map CRITICAL match ip dscp af31 class-map BUSINESS match ip dscp af21 ! Policy map with LLQ policy-map LLQ-WAN class VOICE priority percent 30 class VIDEO bandwidth percent 25 class CRITICAL bandwidth percent 20 class BUSINESS bandwidth percent 10 class class-default fair-queue interface Serial0/0/0 service-policy output LLQ-WAN ``` --- ## β Exam Tips (For CCNA 200-301) | Topic | What Cisco Tests | |-------|------------------| | **FIFO** | Default on high-speed interfaces, no prioritization | | **PQ** | 4 queues, strict priority, starvation possible | | **CQ** | Round-robin, guaranteed bandwidth per queue | | **WFQ** | Automatic flow classification, fair sharing | | **CBWFQ** | User-defined classes, guaranteed bandwidth | | **LLQ** | Priority queue + CBWFQ, best for voice/video | | **Priority Queue Limit** | Should not exceed 33% of bandwidth | ### Common Exam Scenarios: **Scenario 1:** "Which queuing mechanism is recommended for a network with voice, video, and data traffic?" - **Answer:** LLQ (Low-Latency Queuing) **Scenario 2:** "What is the risk of using PQ (Priority Queuing) for voice traffic?" - **Answer:** Low priority queues may starve (never get service) **Scenario 3:** "Which queuing mechanism is the default on low-speed interfaces (2 Mbps or less)?" - **Answer:** WFQ (Weighted Fair Queuing) ### Mnemonics: **Queuing Mechanisms:** **"F.P.C.W.C.L." - FIFO, PQ, CQ, WFQ, CBWFQ, LLQ** **LLQ Components:** **"P + G" - Priority + Guaranteed** - **P**riority queue: Voice/video (low latency) - **G**uaranteed bandwidth: Other classes **Priority Queue Limit:** **"33 is the key"** - Priority queue should not exceed 33% of bandwidth --- ## π Summary (1-Minute Revision) ``` QUEUING MECHANISMS: FIFO (First-In-First-Out): βββ Single queue, no prioritization βββ Default on high-speed interfaces βββ Use: No congestion or simple networks PQ (Priority Queuing): βββ 4 queues (High, Medium, Normal, Low) βββ Strict priority (high always first) βββ Risk: Starvation of low priority queues βββ Legacy (replaced by LLQ) CQ (Custom Queuing): βββ Up to 16 queues, round-robin βββ Configurable byte count per queue βββ Guaranteed bandwidth per queue βββ Legacy (replaced by CBWFQ) WFQ (Weighted Fair Queuing): βββ Automatic flow classification βββ Fair sharing among flows βββ Default on low-speed interfaces (β€2 Mbps) βββ Weight based on IP precedence CBWFQ (Class-Based WFQ): βββ User-defined classes βββ Guaranteed bandwidth per class βββ Fair sharing within classes βββ No priority queue LLQ (Low-Latency Queuing): βββ Priority queue + CBWFQ βββ Strict priority for voice/video βββ Limit priority queue to 33% βββ Recommended for converged networks VERIFICATION: βββ show policy-map interface βββ show queueing interface βββ show interfaces ``` --- ## π§ͺ Practice Questions **1. Which queuing mechanism is the default on high-speed interfaces (2 Mbps or greater)?** - A) FIFO - B) WFQ - C) CBWFQ - D) LLQ <details> <summary>Answer</summary> <b>A) FIFO</b> - FIFO is the default queuing mechanism on high-speed interfaces. </details> **2. Which queuing mechanism provides a strict priority queue for low-latency traffic?** - A) FIFO - B) PQ - C) WFQ - D) LLQ <details> <summary>Answer</summary> <b>D) LLQ</b> - Low-Latency Queuing provides a strict priority queue for voice/video. </details> **3. What is the risk of using Priority Queuing (PQ)?** - A) High latency for priority traffic - B) Low priority queues may starve - C) Complex configuration - D) No QoS guarantees <details> <summary>Answer</summary> <b>B) Low priority queues may starve</b> - Strict priority can cause starvation of lower queues. </details> **4. Which queuing mechanism automatically classifies traffic into flows?** - A) FIFO - B) PQ - C) WFQ - D) CQ <details> <summary>Answer</summary> <b>C) WFQ</b> - Weighted Fair Queuing automatically classifies traffic into flows. </details> **5. What is the recommended maximum percentage for a priority queue in LLQ?** - A) 10% - B) 25% - C) 33% - D) 50% <details> <summary>Answer</summary> <b>C) 33%</b> - Priority queue should not exceed 33% to prevent starvation of other traffic. </details> **6. Which queuing mechanism uses round-robin with configurable byte counts?** - A) FIFO - B) PQ - C) CQ - D) WFQ <details> <summary>Answer</summary> <b>C) CQ</b> - Custom Queuing uses round-robin with configurable byte counts. </details> **7. Which queuing mechanism is the default on low-speed interfaces (2 Mbps or less)?** - A) FIFO - B) WFQ - C) CBWFQ - D) LLQ <details> <summary>Answer</summary> <b>B) WFQ</b> - WFQ is the default queuing mechanism on low-speed interfaces. </details> **8. Which queuing mechanism allows user-defined classes with guaranteed bandwidth?** - A) FIFO - B) PQ - C) WFQ - D) CBWFQ <details> <summary>Answer</summary> <b>D) CBWFQ</b> - Class-Based Weighted Fair Queuing allows user-defined classes. </details> **9. What does LLQ combine?** - A) FIFO + PQ - B) PQ + CQ - C) Priority queue + CBWFQ - D) WFQ + CBWFQ <details> <summary>Answer</summary> <b>C) Priority queue + CBWFQ</b> - LLQ combines a strict priority queue with CBWFQ. </details> **10. Which command displays queuing statistics on an interface?** - A) `show queue` - B) `show policy-map interface` - C) `show queuing` - D) `show interface stats` <details> <summary>Answer</summary> <b>B) `show policy-map interface`</b> - Displays queuing and QoS statistics. </details> **11. Which queuing mechanism has 4 priority levels (High, Medium, Normal, Low)?** - A) FIFO - B) PQ - C) CQ - D) WFQ <details> <summary>Answer</summary> <b>B) PQ</b> - Priority Queuing uses 4 priority levels. </details> **12. Which queuing mechanism is recommended for voice and video traffic?** - A) FIFO - B) PQ - C) CBWFQ - D) LLQ <details> <summary>Answer</summary> <b>D) LLQ</b> - Low-Latency Queuing is recommended for voice and video. </details> --- ## π Next Steps After completing Video 42, you should be ready for: - **Video 43:** Congestion Avoidance (RED, WRED) - **Video 44:** Traffic Policing and Shaping **Lab Practice:** 1. Configure FIFO on a high-speed interface 2. Configure LLQ with priority queue for voice 3. Configure CBWFQ for data classes 4. Verify with `show policy-map interface` 5. Test different traffic types 6. Monitor drop counters --- **Ready for Video 43?** Share the link or say "next" and I'll continue with Congestion Avoidance (RED, WRED). I'll continue with **Video 43: Congestion Avoidance (RED, WRED)** based on the standard CCNA 200-301 curriculum. ---