SQM Help fiber 600 Mb

Hi everyone,

I've been using SQM in my Mini-Pc (X86 Celeron J1900) for the last year working fine on my fiber connection (300 MB). Last monday my operator increassed my speed from 300 Mb. to 600 Mb.

I just changed the /etc/config/sqm file config from 300 to 600, and the rest of config just the same as before.

Now, I can't get more than 500 Mb. with SQM ON, when is OFF I get 600 Mb. or more.
I loose more than 100 Mb. !!!

Any idea?

Tested on LEDE 17.01.4 and lastest snapshot 18.XXX. Using cake and pice_of_cake.

Many Thanks!!!

1 Like

iirc i could also not get much more than 500mbps sqm throu my j1900

other than upgrading to a non-embed cpu router .. i mean its still almost double the bandwitdh than last week :slight_smile:

1 Like

Another important thing to remember is that bandwidth shaping will almost always reduce your bandwidth. People tend to sweep the changes under the rug when they're only "a couple Mbps" out of 25 Mbps, but 50 Mbps, the same fractional change at 500, Mbps "looks like a lot".

Give you're using relatively complex shaping, it wouldn't surprise me if you're reaching the limits of the J1900. My notes from several years ago when I tested them were that it had decent speed for power consumption and that it was a four-core device. While that is great for parallel compiles or multi-threaded services, kernel-level activity generally can't take advantage of that in the same way.

Do you really need 600M or ingress shaping on such a huge bandwidth?
When did you reach the max bandwidth in a real world scenario at home so that your ping raise?

No, I don't need 600 Mb.
I wanted to expose "the case" in order to know if was doing something wrong.
Now I've disabled SQM.

What does "kernel-level activity" need? Gigaherts (more than multi core)?

it needs a kernel that multi-threads things :slight_smile:
@Klingon

I have a j1900 based mobo in a mini-itx case and it shapes my gigabit fiber connection using a custom HFSC + fq_codel script

The system operates at about 750Mbps at the moment, but it was handling the full gigabit before I added squid into the equation. I'm using squid to do certain kinds of filtering and adjusting DSCP tags and also handling the fact that I run an ipv6 only LAN... and of course having those extra user-land threads eats into the available CPU.

One thing I am doing which you probably are NOT doing is I'm using 2 bonded Intel NICs into a smart switch LAG group. I suspect this lets my kernel multi-thread things better.

Short version: you should absolutely be able to route even a gigabit with shaping on a j1900 if you set things up carefully, use two bonded NICs with VLAN, and you have Intel NICs.

1 Like

Here's the basic setup for the bonded nic idea:

ISP Equipment -----> Smart Switch Port 1 into VLAN 10

J1900 Nics bond0 ------> Smart Switch Port 2 and 3

Port 1 set up as VLAN 10 port VID untagged

Port 2 and 3 set up as LAG group, tagged for VLAN 10 and 1

Other ports are PVID 1 untagged on VLAN 1 for my regular LAN (this is simplified from real situation)

J1900 uses bond0.10 as WAN interface and bond0.1 as LAN interface, instantiate SQM (or your favorite qos scripts) on bond0.10 and bond0.1 in outbound direction only

"inbound" qos is handled by the fact that bond0.1 "outbound" is the inbound traffic :slight_smile:

Now you can actually use DSCP tagging in the firewall to help shape inbound traffic since the firewall is called after the WAN packets arrive but before they're xmited on bond0.1

With all this in place, I suspect you should get your full speed.

Thanks for the advice, my NICs are Realtek :sob::sob: and I only have 2 phisical interfaces (1 WAN and 1 LAN) :sob::sob::sob:
Next time I'll buy Intel NICs + More ports.

The 2 physical interfaces is all I have as well. Instead of using one for lan and one for wan, I bond them together and use bond0.10 for wan and bond0.1 for lan. Then the packets can be scheduled round-robin on two nics, allowing you to engage two cpu cores. This requires a smart switch but should improve your situation! I use a zyxel smart switch, but I also have a TP-Link TL-Sg108E v3 and it would do the same thing for only $40 or so

2 Likes