QOS kills bandwidth

General questions.
jlgtx
Posts: 31
Joined: August 19th, 2016, 4:23 am

QOS kills bandwidth

Post by jlgtx » March 1st, 2018, 6:44 pm

We're running IPFire 219/118. Been running without issue for quite awhile, on a 200x30Mb cable modem connection. Today we upgraded the service to 500x50Mb, and I couldn't get more than 250Mb download speeds. Yes, I updated the QoS configuration with the new up/down bandwidth (I used 510000 / 50000) and used the "Preset" button to generate a standard QoS template. With QoS enabled, we're limited to 250Mb cumulative down, 30Mb up. Turn off QoS, and we get 530Mbit down, 50Mbit up.

Any ideas on how to troubleshoot this? At this point I'm just leaving QoS disabled, but I'd prefer to have it running.

abailey10
Posts: 5
Joined: February 7th, 2018, 3:12 pm

Re: QOS kills bandwidth

Post by abailey10 » March 2nd, 2018, 1:34 am

Qos breaks up bandwidth so that no 1 user can achieve the 500mb which would leave everyone else with none. 250 for single user isn't bad, you would have to change policy to get better per single user. You would need to check while 1 user is hitting 250mb if another user can also hit that at same time, hence the policy you have chosen is working correctly. Most networks wouldn't allow that speed unless there are only 2 users. 500mb total but 10 users would be 50mb each user. Need more info know what you want. How many are on your network?

dnl
Posts: 375
Joined: June 28th, 2013, 11:03 am

Re: QOS kills bandwidth

Post by dnl » March 2nd, 2018, 9:20 am

abailey10 wrote:
March 2nd, 2018, 1:34 am
Qos breaks up bandwidth so that no 1 user can achieve the 500mb which would leave everyone else with none.
Hello,
What gave you the impression that QoS can share bandwidth between users like that?

I ask as it is my understanding that it only sets a priority and maximum bandwidth for each protocol or IP based on what you configure.

jlgtx,
I too would want QoS in your situation, even if the link isn't regularly saturated, just for the benefit of having fq_CoDel enabled. (See the wiki page)

I do not use the default configuration - the thing about QoS is that it really needs effort to tweak in order for it to work well for you.
Is it possible that the default configuration has set a low maximum bandwidth on each class?
Is the CPU of your IPFire box fully utilised when you test bandwidth?

I can't promise to have a lot of time, but can you please post the contents of your QoS settings files so people can check them?

At least the following files (potentially more if you've customised settings)
  • /var/ipfire/qos/settings
  • /var/ipfire/qos/classes
  • /var/ipfire/qos/portconfig
  • /var/ipfire/qos/tosconfig
IPFire 2.x (Latest Update) on x86_64 Intel Bay Trail CPU, 4GiB RAM, RED + GREEN + BLUE + ORANGE

jlgtx
Posts: 31
Joined: August 19th, 2016, 4:23 am

Re: QOS kills bandwidth

Post by jlgtx » March 2nd, 2018, 9:02 pm

The way QoS works, if a single host is using the link, that host can get almost the max bandwidth...max minus reserved, which isn't anywhere near 50% of the bandwidth. I've already verified that, with two different hosts running a simultaneous speedtest, the maximum total throughput is 250Mb. One host typically gets 150-200Mb, the other gets 50-100Mb. Turn off QoS, and the total goes up to >500Mb as it should be.

CPU & memory aren't even breathing hard on the IPFire host.

What's interesting is that the upload speed does just what I'd expect--it's right at 50Mb with QoS off, and drops into the mid-40Mb range with QoS on. It's just the download speed that isn't right.
Last edited by jlgtx on March 2nd, 2018, 9:15 pm, edited 1 time in total.

jlgtx
Posts: 31
Joined: August 19th, 2016, 4:23 am

Re: QOS kills bandwidth

Post by jlgtx » March 2nd, 2018, 9:06 pm

These are the default settings that were created when I entered 510000 / 50000 for the down/up bandwidth, and clicked the "Preset" button. I haven't changed them.

/var/ipfire/qos/settings

Code: Select all

CBURST=
RED_DEV_SEL=
SPD=
RED_DEV=red0
DIP=
TOS=
DOCLASS=
IMQ_DEV=imq0
DEFCLASS_INC=210
PRIO=
DOLEVEL7=
QIP=
EDIT=no
PPROT=
SCLASS=
DEFCLASS_OUT=110
QPORT=
DEF_INC_SPD=459000
BURST=
ENABLED=off
OUT_SPD=50000
MAXBWDTH=
ACK=101
IMQ_DEV_SEL=
DOSCLASS=
CLASS=
L7PROT=
CLASSPRFX=
VALID=yes
INC_SPD=510000
DEF_OUT_SPD=45000
MINBWDTH=
DPORT=
DEVICE=
DEV=
DOPORT=
/var/ipfire/qos/classes

Code: Select all

imq0;200;1;51000;510000;;;8;VoIP;
imq0;203;4;25500;510000;;;0;VPN;
imq0;204;5;25500;510000;;;8;Webtraffic;
imq0;210;6;1;510000;;;0;Default;
imq0;220;7;1;510000;;;1;P2P;
red0;101;1;25000;50000;;;8;ACKs;
red0;102;2;16666;50000;;;8;VoIP;
red0;104;5;5000;50000;;;8;Webtraffic;
red0;110;6;1;50000;;;0;Default;
red0;120;7;1;50000;;;1;P2P;
red0;103;4;25000;50000;;;2;VPN;
/var/ipfire/qos/portconfig

Code: Select all

101;red0;icmp;;;;;
102;red0;tcp;;;;53;
102;red0;udp;;;;53;
103;red0;esp;;;;;
103;red0;tcp;;1194;;;
103;red0;udp;;1194;;;
103;red0;tcp;;;;1194;
103;red0;udp;;;;1194;
103;red0;udp;;4500;;4500;
103;red0;udp;;500;;500;
104;red0;tcp;;;;80;
200;imq0;icmp;;;;;
203;imq0;esp;;;;;
203;imq0;tcp;;;;1194;
203;imq0;udp;;;;1194;
203;imq0;tcp;;1194;;;
203;imq0;udp;;1194;;;
203;imq0;udp;;4500;;4500;
203;imq0;udp;;500;;500;
204;imq0;tcp;;80;;;
/var/ipfire/qos/tosconfig

(empty)

/var/ipfire/qos/subclasses

(empty)

/var/ipfire/qos/level7config

Code: Select all

102;red0;dns;;;
102;red0;rtp;;;
102;red0;skypetoskype;;;
103;red0;ssh;;;
103;red0;rdp;;;
104;red0;http;;;
104;red0;ssl;;;
104;red0;pop3;;;
120;red0;applejuice;;;
120;red0;bittorrent;;;
200;imq0;rtp;;;
200;imq0;skypetoskype;;;
203;imq0;ssh;;;
203;imq0;rdp;;;
204;imq0;http;;;
204;imq0;pop3;;;
204;imq0;ssl;;;
220;imq0;applejuice;;;
220;imq0;bittorrent;;;

jlgtx
Posts: 31
Joined: August 19th, 2016, 4:23 am

Re: QOS kills bandwidth

Post by jlgtx » March 2nd, 2018, 9:27 pm

So, I went ahead and deleted everything except the "Default" classes, ensured the max bandwidth was correct for each one, and...same thing. Enable QoS, upload is fine (low 40Mb), download maxes out at 250Mb. Disable QoS, upload is 50Mb, download is 530Mb.

dnl
Posts: 375
Joined: June 28th, 2013, 11:03 am

Re: QOS kills bandwidth

Post by dnl » March 3rd, 2018, 5:31 am

jlgtx wrote:
March 2nd, 2018, 9:27 pm
So, I went ahead and deleted everything except the "Default" classes, ensured the max bandwidth was correct for each one, and...same thing. Enable QoS, upload is fine (low 40Mb), download maxes out at 250Mb. Disable QoS, upload is 50Mb, download is 530Mb.
Sorry I'm not sure. I think you've done the right thing to try to isolate the problem.

It's not the right setting for actual use, but why not try deleting all your QoS rules, then re-creating them with your bandwith values set twice as big as they actually are? I suspect that you will probably still have the bandwidth problem when QoS is enabled.

If you do still have the problem, then hopefully a core developer will take notice of this thread. I know they're very keen to ensure IPFire performs well (including testing on gigabit connections).
IPFire 2.x (Latest Update) on x86_64 Intel Bay Trail CPU, 4GiB RAM, RED + GREEN + BLUE + ORANGE

abailey10
Posts: 5
Joined: February 7th, 2018, 3:12 pm

Re: QOS kills bandwidth

Post by abailey10 » March 6th, 2018, 5:44 pm

Cubic instead of fq codel, fq codel has so many queue's . Cubic is just 1. I know it works with cubic as it did with Untangle fire wall.

User avatar
Deepcuts
Posts: 461
Joined: March 1st, 2016, 3:18 pm
Location: Romania

Re: QOS kills bandwidth

Post by Deepcuts » March 6th, 2018, 9:44 pm

dnl wrote:
March 3rd, 2018, 5:31 am
I know they're very keen to ensure IPFire performs well (including testing on gigabit connections).

A bit off topic.
How can you tell they are keen to ensure IPFire performs well on gigabit connections?
I reported slow squid with the default kernel for some time now on gigabit connection. Nothing has been done.
Also, with default kernel, very slow M.2 nvme speeds. Nothing has been done.
I really like IPFire and wish it gathers more momentum, but I really don't see what you are seeing :(
Image
Image

jlgtx
Posts: 31
Joined: August 19th, 2016, 4:23 am

Re: QOS kills bandwidth

Post by jlgtx » March 14th, 2018, 8:24 pm

I recreated the QoS settings using the actual upload bandwidth, and twice the actual download bandwidth (so my settings are 1020000 / 50000), and the "preset" button. I haven't done extensive testing, but this seems to work...I'm now getting sane speedtest results. 350x43Mb with QoS enabled, vs. 445x40Mb with it disabled (it's the middle of the business day, so the net is busy).

I don't know the "magic number" where QoS starts requiring double the actual download bandwidth in order to work properly, but it's somewhere between 200-500Mb. When we had 200Mb here, QoS worked fine with actual bandwidth.


jlgtx
Posts: 31
Joined: August 19th, 2016, 4:23 am

Re: QOS kills bandwidth

Post by jlgtx » March 16th, 2018, 12:53 am

Well, at least it's a known bug. Here are some speedtest results, to demonstrate what I'm seeing.

Our actual bandwidth is supposed to be 500x50Mb.

With QoS disabled, I get this:
QoSoff.png
With QoS enabled and set to 500x50Mb:
QoSactual.png
With QoS enabled and set to 1000x50Mb:
QoSdouble.png
This doesn't occur with bandwidth <250Mb, which is the odd thing.

BeBiMa
Posts: 2842
Joined: July 30th, 2011, 12:55 pm
Location: Mannheim

Re: QOS kills bandwidth

Post by BeBiMa » March 16th, 2018, 1:48 am

FYI: I just tested QOS with my "low" bandwidth of 32/1 Mb/s.
Same effect. I can get full speed with setting of DL speed to 63568. ( Update: This is true for 44000 also )
Image
Unitymedia Cable Internet ( 32MBit )

User avatar
H&M
Posts: 471
Joined: May 29th, 2014, 9:38 pm
Location: Europe

Re: QOS kills bandwidth

Post by H&M » March 20th, 2018, 8:25 pm

jlgtx wrote:
March 16th, 2018, 12:53 am
Well, at least it's a known bug. Here are some speedtest results, to demonstrate what I'm seeing.

Our actual bandwidth is supposed to be 500x50Mb.

With QoS disabled, I get this:
When you say QoS Disabled - did you checked that is actually disabled?
If yes (actually disabled) can you please tell me how you did it?

Reason for asking: viewtopic.php?f=27&t=12302 - even with QoS disabled from WUI/GUI, it still works! (it seems a bug)

Thank you,
H&M

Hellfire
Posts: 697
Joined: November 8th, 2015, 8:54 am

Re: QOS kills bandwidth

Post by Hellfire » March 21st, 2018, 11:43 am

Months ago I've noticed the same and reported here in the forums.

My QoS is disabled and has been enabled just one single time for testing purposes. After changing the provider and getting an upgrade of my bandwidth I noticed I do not even scrap the new up and download speeds.

After a while I found the cause of this: during playing around with my QoS settings, I once limited the down- and upload speed within one or more of the QoS-classes (don't actually remember which one and don't have access to the firewall right now). After my tests, I completely disabled the service but I did not touch those values and QoS anymore since then.

Now, while searching for the cause of the download limitation, I remembered about QoS again and modified the class values to the current up- and download limits and guess what? I got the expected speeds!

Please notice: QoS is still disabled! Simply by adjusting the appropriate values did the job! The former thread, here on the forums did not solve this riddle either, obviously the issues still exists. Don't know if this is expected behavior or not!

My former posting from July 2017: viewtopic.php?f=27&t=12302&p=108847&hilit=qos#p108847 jsut noticed that this thread awoke again, too ;)

Michael
Image

Post Reply