SRX Services Gateway
Reply
Contributor
gxc11
Posts: 24
Registered: ‎01-30-2008
0

VoIP and Video QoS setup to ISP

Situation:

Have a 20 Mbps mpls connection that is handed off to SRX by ethernet on g-0/0/0, which is hard set to 100F.  Provider has a QoS policy setup on their edge router of 50_24_1, or 50% of the connection for EF traffic, 24% for AF41, 1% data.  ge-0/0/1 uplinks to a EX4200 VC, which has phones/video equipment.  Looking for the correct, simple as possible SRX QoS setup:

Setup the classifier to look for traffic you want, here ef (voip) and video (af41):

set class-of-service classifiers dscp dscp-classifier import default
set class-of-service classifiers dscp dscp-classifier forwarding-class expedited-forwarding loss-priority low code-points ef
set class-of-service classifiers dscp dscp-classifier forwarding-class assured-forwarding loss-priority low code-points af41

Apply classifier and scheduler on necessary interfaces:

set class-of-service interfaces ge-0/0/0 unit 0 classifiers dscp dscp-classifier
set class-of-service interfaces ge-0/0/0 unit 0 scheduler-map voip
set class-of-service interfaces ge-0/0/1 unit 0 classifiers dscp dscp-classifier

setup scheduler maps to queues:

set class-of-service scheduler-maps voip forwarding-class expedited-forwarding scheduler voice-scheduler
set class-of-service scheduler-maps voip forwarding-class assured-forwarding scheduler video-scheduler

setup limits:

set class-of-service schedulers voice-scheduler transmit-rate percent 50
set class-of-service schedulers voice-scheduler buffer-size percent 50
set class-of-service schedulers voice-scheduler priority strict-high
set class-of-service schedulers video-scheduler transmit-rate percent 24
set class-of-service schedulers video-scheduler buffer-size percent 50
set class-of-service schedulers video-scheduler priority low

Shape ge-0/0/0 to 20Mbps, which requires a few commands:

set class-of-service interface ge-0/0/0 unit 0 shaping-rate 20m
set interfaces ge-0/0/0 per-unit-scheduler

Would I see matches on the queues by doing 'show int ge-0/0/0 detail'

Thoughts on all this would be appreciated!

Distinguished Expert
rkim
Posts: 755
Registered: ‎11-06-2007
0

Re: VoIP and Video QoS setup to ISP

To show traffic in queues use the 'show interface queue' command instead. Some thoughts though.

 

- If configuring schedulers should be sure to include ALL forwarding classes in your configs including best-effort and network-control. Network-control is often overlooked but is important. Hence by default CoS would allocate 5% transmit-rate and buffer for network-control which is normally queue 3.

- Be careful with strict-high priority as well unless you are 100% certain that your strict-high traffic would not consume your total interface bandwidth.

- Your classification as you have configured also assumes that all your traffic has proper ToS field with DSCP markings matching the code-points you configured. If the traffic does NOT match or if the traffic is not marked at all then it will queue in best-effort. You can sniff your traffic and check the TOS field to ensure your traffic is matched accordingly.

- 50% buffer may not be ideal for voice traffic. Voice traffic tends to be small packet sizes which means you do not require much buffers (compared to normal Internet or video traffic). Too high buffer depth for voice traffic can introduce unwanted latency and jitter. I normally recommend decreasing buffer size on voice traffic queues to decrease latency and jitter. How low depends on your traffic. Usually this needs to be tuned and tweak such that you lower as low as possible without introducing unwanted tail-drops.

 

Here's another thread on the topic.

 

http://forums.juniper.net/t5/SRX-Services-Gateway/CoS-for-Traffic-Voice-Sample-Configuration/m-p/354...

 

Hope this helps.

-Richard

Contributor
gxc11
Posts: 24
Registered: ‎01-30-2008
0

Re: VoIP and Video QoS setup to ISP

Thanks for the link, that's a good read in the pdf on that other thread.

 

Mostly G.729 VoIP traffic, phones are told to mark dscp 46, will certainly verify.  I will lower and play with the buffer sizes.  I also found the ez-qos template provided with the ex switches, so I will use portions of that to setup the network control queue and put AF41 below the phone traffic.

 

Is the configuration for setting the interface bandwidth correct?  It's a 100 meg link to the SRX, but trottled on the providers side to 20Mbps, so you must have to tell the SRX to shape into 20 Mbps, not a 100?

 

Thanks!

 

Distinguished Expert
rkim
Posts: 755
Registered: ‎11-06-2007
0

Re: VoIP and Video QoS setup to ISP

Yes you should use shaping rate to let CoS know your true interface bandwidth.

 

-Richard

Copyright© 1999-2013 Juniper Networks, Inc. All rights reserved.