QoS Configuration for VoIP on Cisco Networks
VoIP traffic is delay and jitter sensitive. QoS marks, queues, and prioritizes voice packets end-to-end.
QoS Design Model (3-tier)
TEXT
Access Layer: Mark traffic (DSCP EF for voice, AF41 for video)
Distribution: Queue and schedule
Core: Honor markings, minimal queuingDSCP Markings
| Traffic | DSCP | Queue |
|---|---|---|
| VoIP RTP | EF (46) | Priority |
| VoIP Signaling | CS3 (24) | Expedited |
| Video Conferencing | AF41 (34) | Bandwidth |
| Business Data | AF21 (18) | Normal |
| Best Effort | BE (0) | Default |
Classification and Marking (Access Switch)
TEXT
! Match VoIP phones by DSCP (phones mark themselves)
class-map match-any VOICE
match dscp ef
match dscp cs3
class-map match-any VIDEO
match dscp af41
policy-map EDGE-MARKING
class VOICE
set dscp ef
class VIDEO
set dscp af41
class class-default
set dscp default
interface GigabitEthernet1/0/1
service-policy input EDGE-MARKINGQueuing Policy (Router WAN interface)
TEXT
policy-map WAN-QOS
class VOICE
priority percent 20 ! LLQ — strict priority
class VIDEO
bandwidth percent 20
class SIGNALING
bandwidth percent 5
class class-default
fair-queue
bandwidth percent 55
interface Serial0/0/0
bandwidth 10000
service-policy output WAN-QOSMikroTik QoS for VoIP
BASH
# Mark VoIP RTP packets
/ip firewall mangle add chain=forward src-port=10000-20000 protocol=udp action=mark-packet new-packet-mark=voip
# Queue tree priority
/queue tree add name=voip parent=global packet-mark=voip priority=1 max-limit=2M
/queue tree add name=data parent=global priority=8 max-limit=8MVerification
TEXT
show policy-map interface Serial0/0/0
show queue Serial0/0/0
ping 192.168.10.50 repeat 1000 size 160Target VoIP metrics: Latency <150ms, Jitter <30ms, Packet loss <1%.
