Routing
Highlighted
Routing

CoS question

[ Edited ]
‎05-12-2020 06:55 PM

Hi all,

I need some help here as I am not familiar with Juniper CoS, and I am not sure if CoS function of Juniper MX router can do the job. What I want to do is, prioritise and allocate bandwidth to different classes of outgoing traffic to an ISP. 

 

My ISP link have a basic 200Mbps subscription and can burst to 400Mbps but with extra cost. 

 

I want to classify all my outgoing traffic to an ISP to 4 different classes, best-effort, assured-forwarding, expedited-forwarding and network-control.

 

Best-effort and assured-forwarding have low and medium priority respectively, and they can allocate up to 200Mbps if the link usage is not over 200Mbps. , to avoid extra cost.

 

Only expedited-forwarding and network-control can burst to 400Mbps.

 

Is that possible to do so on Juniper MX platform? Many thanks to your help and advise in advance.

 

Ragards,

SH

 

 

10 REPLIES 10
Highlighted
Routing

Re: CoS question

‎05-12-2020 07:39 PM

Hi steveho@m800.com

 

Greetings, Yes you can, in case you have an iOS background, CoS is the equivalent of QoS, with CoS you can classify your traffic into forwarding classes then map them to a physical queue, then you can prioritize and set the bandwidth percentage to each forwarding class as desired with a scheduler, you can manage out of profile traffic as you want with a shaper ( outbound traffic) or a policier ( inbound traffic)  you can add and change the traffic markings with rewrite rules, etc.  I will share this guide so you can have some insights as of how you can go about this task and the actual commands you need :   

 

 

https://www.juniper.net/documentation/en_US/junos/information-products/pathway-pages/cos/config-guid...

 

If this solves your problem, please mark this post as "Accepted Solution" so we can help others too \:)/

Regards,

Lil Dexx
JNCIE-ENT#863, 3X JNCIP-[SP-ENT-DC], 4X JNCIA [cloud-DevOps-Junos-Design], Champions Ingenius, SSYB

Highlighted
Routing

Re: CoS question

‎05-12-2020 08:49 PM

Hi Lil,

Thanks for your reply. After studying the docs, I still have some questions.

 

Is that possible for two queues to share a sum of 200Mbps, which other queue can burst up to 400Mbps?

Like, when class best-effort is using 80 Mbps, then class assured-forwarding can use up to 120Mbps. When class best-effort is using 150 Mbps, then class assured-forwarding can use up to 50Mbps. And the other classes can use up to 400Mbps.

 

Thanks,

SH

Highlighted
Routing

Re: CoS question

[ Edited ]
‎05-12-2020 08:50 PM

Hi SH,

 

You can classify outgoing traffic to an ISP to 4 different classes using CoS.

 

You can refer to https://www.juniper.net/documentation/en_US/junos-space-apps/network-director3.2/topics/concept/cos-... for a brief description about CoS, how to create CoS groups, What aspects one can control using CoS.

 

Hope this helps 🙂

 

Please mark this "Accepted Solution" if this addresses your concern.

Kudos would be much appreciated too 🙂

Highlighted
Routing

Re: CoS question

‎05-12-2020 10:38 PM

Hi Steve,

 

You can refer below Juniper links to under stand more on schedelers and classify traffic.

 

https://www.juniper.net/documentation/en_US/junos/topics/example/cos-ex-series-configuring.html

 

https://www.juniper.net/documentation/en_US/junos/topics/example/cos-scheduler-security-configuring....

 

If this solves your problem, please mark this post as "Accepted Solution" so we can help others too

 

Kudos are appreciated too 

 

 

Regards,

Nadeem

 

Highlighted
Routing

Re: CoS question

‎05-12-2020 11:04 PM

Hi SH,

 

Assuming I am getting your second query correctly, let me answer this for you.

 

Yes, it is possible to share bandwidth between 2 queues. You will have to configure schedulers, attach that to the two queues, and then apply shapers. Assuming traffic is classified and going to BE, AF queue at egress. you need to have schedulers say S1 attached to both queues BE, AF.

 

Although the above is achievable, in case traffic exceeds 200 Mbps, there cannot be a way in which you can divert the excess traffic to another queue. Both Queues will meet their guaranteed rates first, then will move to the excess region. So, it depends upon per queue queued traffic. In my understanding, there is no feature that can pick up the dropped packets and forward it to another queue.

 

You can always define priority to the scheduling as per your needs. Please refer the below-

https://www.juniper.net/documentation/en_US/junos/topics/task/configuration/cos-queue-scheduling-pri...

 

Hope this helps 🙂

 

Please mark this "Accepted Solution" if this addresses your concern.

Kudos would be much appreciated too :)

 

Highlighted
Routing

Re: CoS question

‎05-12-2020 11:35 PM

Dear bmanvita,

 

Thanks for your reply. You help me a lot here.

 

So if I have scheduler say S1 attached to both queues BE and AF, is that means BE and AF have the same priority so that I cannot make AF a higher priority class than BE?

 

Regards,

SH

Highlighted
Routing

Re: CoS question

‎05-12-2020 11:47 PM

Hi SH,

 

I am glad that I was of some help to you!

 

No, you can always set priorities for the classes as per your needs. The below document gives you details about the scheduler priority. 

https://www.juniper.net/documentation/en_US/junos/topics/concept/schedulers-priority-overview-cos-co...

 

So, as per your need, you can make AF take a better priority than the other.

 

Hope this helps 🙂

 

Please mark this "Accepted Solution" if this helps you solve your query.

Kudos would be much appreciated too 🙂

 

Highlighted
Routing

Re: CoS question

‎05-13-2020 12:00 AM

Dear bmanvita, 

 

Thank you again for replying. Correct me if I were wrong. As per my understand, both prioirty and shaping rate are set under schedulers, like:

 

set class-of-service schedulers s1 priority low

set class-of-service schedulers s1 transmit-rate 100m

set class-of-service schedulers s1 shaping-rate 200m

 

And if I have two forwarding classes attached to the smae scheduler, then they are having the same priority.

 

set class-of-service scheduler-maps map1 forwarding-class best-effort scheduler s1

set class-of-service scheduler-maps map1 forwarding-class assured-forwarding scheduler s1

 

Or is there any other way to configure which I have missed?

 

Regards,

SH

Highlighted
Routing

Re: CoS question

‎05-13-2020 12:11 AM

Hi SH,

 

This basic config looks good to me. 

 

Additionally, in order to configure priorities, the below document will help

https://www.juniper.net/documentation/en_US/junos/topics/task/configuration/cos-configuring-schedule...

 

Hope this helps:) 
 
Please mark "Accepted Solution" so that it can help others.
Kudos would be much appreciated too 🙂
 
Highlighted
Routing

Re: CoS question

‎05-15-2020 07:06 AM

Hi SH,

 

I hope all your doubts on this one have been clarified.

 

Feel free to let us know, should you need any further details on this one.

 

If you find a solution above that helped you, please mark it "Accepted" so that it can help others too.

Feedback