Enabling QoS on Route10

Hi All,

I noticed that “QoS Tagging and VLAN tagging on WAN support” was a listed feature on the Route10 datasheet, but I don’t see an option in the cloud controller interface for QoS

Is there a way to enable this in the cloud controller that in missing, or is this restricted to the CLI

Would love some instructions on enabling QoS to best support VOIP or data sensitive applications like Teams

Jeff did a great YouTube video on enabling CAKE. Might that be of help?

3 Likes

CAKE should definitely help out with QoS, although I will note that on the Route10 it defaults to the besteffort setting which I believe doesn’t take into account any DSCP markings on traffic coming through the router. That can be tweaked a bit from the CLI if needed. I’ll see about posting an example of how I have it set at a couple of sites just in case anyone is interested :slight_smile:

I would love to see examples if you are willing to share!

Sure! I’m certainly not expert but I’ve been meaning to post a little about it anyway :smiley:

So when CAKE is enabled on the WAN, the settings look something like this by default on the Route10

qdisc cake 8005: dev eth3 root refcnt 5 bandwidth 35Mbit besteffort triple-isolate nonat nowash no-ack-filter split-gso rtt 100ms raw overhead 0 

Which reflect the settings here:

~ # cat /etc/config/sqm

config queue 'eth3'
        option enabled '1'
        option interface 'eth3'
        option download '0'
        option upload '35000'
        option qdisc 'cake'
        option script 'piece_of_cake.qos'
        option qdisc_advanced '0'
        option qdisc_really_really_advanced '0'
        option ingress_ecn 'ECN'
        option egress_ecn 'ECN'
        option itarget 'auto'
        option etarget 'auto'
        option linklayer 'none'

To my knowledge, those settings are totally fine to just get some fairness going between network traffic without being a big hit to performance. But we can definitely add some options to potentially further priortize traffic. Here’s an example of some adjustments to the SQM config file.

~ # cat /etc/config/sqm
config queue 'eth3'
        option enabled '1'
        option interface 'eth3'
        option download '300000'
        option upload '300000'
        option qdisc 'cake'
        option script 'layer_cake.qos'
        option qdisc_advanced '0'
        option qdisc_really_really_advanced '0'
        option ingress_ecn 'ECN'
        option egress_ecn 'ECN'
        option itarget 'auto'
        option etarget 'auto'
        option linklayer 'none'
        option iqdsic_opts 'ingress nat memlimit 32M'
        option eqdsic_opts 'diffserv4 nat memlimit 32M'

So here I’ve changed the script to layer_cake.qos to try and take advantage of the diffserv option, which impliments some unfairness to make sure voice and video traffic has a higher priority in the queue. I believe the default of diffserv3 only accounts for voice, if we reference the man page for CAKE a little bit

PRIORITY QUEUE PARAMETERS         top
       CAKE can divide traffic into "tins" based on the Diffserv field.
       Each tin has its own independent set of flow-isolation queues, and
       is serviced based on a WRR algorithm.  To avoid perverse Diffserv
       marking incentives, tin weights have a "priority sharing" value
       when bandwidth used by that tin is below a threshold, and a lower
       "bandwidth sharing" value when above.  Bandwidth is compared
       against the threshold using the same algorithm as the deficit-mode
       shaper.

       Detailed customisation of tin parameters is not provided.  The
       following presets perform all necessary tuning, relative to the
       current shaper bandwidth and RTT settings.

       besteffort
              Disables priority queuing by placing all traffic in one
              tin.

       precedence
              Enables legacy interpretation of TOS "Precedence" field.
              Use of this preset on the modern Internet is firmly
              discouraged.

       diffserv4
              Provides a general-purpose Diffserv implementation with
              four tins:

              • Bulk (CS1, LE in kernel v5.9+), 6.25% threshold,
              generally low priority.
              • Best Effort (general), 100% threshold.
              • Video (AF4x, AF3x, CS3, AF2x, CS2, TOS4, TOS1), 50%
              threshold.
              • Voice (CS7, CS6, EF, VA, CS5, CS4), 25% threshold.

       diffserv3 (default)
              Provides a simple, general-purpose Diffserv implementation
              with three tins:

              • Bulk (CS1, LE in kernel v5.9+), 6.25% threshold,
              generally low priority.
              • Best Effort (general), 100% threshold.
              • Voice (CS7, CS6, EF, VA, TOS4), 25% threshold, reduced
              Codel interval.

I also selected the ingress option for incoming traffic as I believe there’s a possible gain to be had there, as well as allowing the router to know that it can look in NAT for information

       ingress
              Indicates that CAKE is running in ingress mode (i.e.
              running on the downlink of a connection). This changes the
              shaper to also count dropped packets as data transferred,
              as these will have already traversed the link before CAKE
              can choose what to do with them.

              In addition, the AQM will be tuned to always keep at least
              two packets queued per flow. The reason for this is that
              retransmits are more expensive in ingress mode, since
              dropped packets have to traverse the link again; thus,
              keeping a minimum number of packets queued will improve
              throughput in cases where the number of active flows are so
              large that they saturate the link even at their minimum
              window size.
nat
              Instructs Cake to perform a NAT lookup before applying
              flow-isolation rules, to determine the true addresses and
              port numbers of the packet, to improve fairness between
              hosts "inside" the NAT.  This has no practical effect in
              "flowblind" or "flows" modes, or if NAT is performed on a
              different host.

The memlimit option is a little arbitrary, as it’s just to allow the router to set a bigger amount of RAM aside rather than having to calculate how much it needs since CAKE was designed with the assumption it would run on memory constrained devices. Not something like the Route10 with 1GB of RAM.

Anyway, I usually keep those settings applied by using a post-cfg.sh file and not so gracefully copying a file with the custom settings from /cfg to /etc/config/sqm then restarting SQM with /etc/init.d/sqm restart.

For example:

cp /cfg/sqm.bak /etc/config/sqm
/etc/init.d/sqm restart
1 Like