Bufferbloat problem

I currently have a 2 MBit/S DSL internet connection through PPOA/E.
My total upload speed is 512 KBit/S.
I can't get better speeds in my country, but as a gamer 1 MBits should be enough for online gaming as most games uses half Mbit or less.

What I actually need is a DSL modem/Router with 2.4 GHz wifi that can manage traffic properly so my ping does not change while gaming if someone else is using Youtube or internet browser without limiting my bandwidth. I want to be able to download stuff while gaming without having any issues. I have been told that OpenWRT firmware us the only one that can do such a thing without limiting bandwidth so I want your recommendation to pick the right device. Something affordable 50$ price range and can do these things. I already own ASUS DSL-N14U which has QOS in it, but that does not seem to help at all (even if there was 10 kbits being used by other device on the network I will encounter bufferbloat no matter what kind of agressive rules I set). my ASUS modem is a good device in my opinion because it has 60 MB of RAM and the CPU is being used by less than 20% almost all the time. it also has many features as download master, shared printer, cloud, 3G/4G modem support, IPTV, VPN, but sadly it is not supported by OpenWRT so I need such a device with these features but works perfectly with OpenWRT without any unsupported feature

new you should look at gl-inet devices, some are in your price range at least in US.

otherwise look on used market and see if you can find something with support. your speeds are very slow so CPU speed is not an issue but get plenty of RAM and flash, no 4/32 MB devices.

edgerouter x is a nice device, fast enough to handle 500Mbps or more, cheapish, and you can use your existing device as Access Point

1 Like

It has to be DSL modem, has a wifi and RJ45 outpots and I would say the price point 50$ is not a high priority thing. I can spend more if it really deserve the extra price. Finding the best one for my low speeds with best management is what does matter most

Can you just put your ASUS into a bridge mode?

Yeah. I will include details about my setup
I am using ASUS DSL-N14U to connect my DSL WAN into it then I am using a 60 meters long RJ45 cable to connect it to a far 10/100 switch then another wifi device connected to that switch to give a wifi network in 2 places (my home and my work place) I have noticed that all rules specified by the main device that has WAN hooked up to it will apply on all connected devices. I used the SMC switch because of the long RJ45 cable and it simply the setup won't work without it. The ASUS DSL-N14U can do almost everything. It has WDS, works as AP, as repeater or hyprid mode which is both at the same time. It supports dual wan through ethernet and through DSL. But why I would need the bridge functioon? I actually want a device capable of being my modem and my router at the same time. I don't want to hook up more devices tho xD

That really is not possible, with a 2/0.5 link you are going to notice other's activity on the link, you can remedy this interference to some degree, but it will stay noticeable, as at 512 Kbps a single full MTU packet takes around:
((ceil(1548/48) * 53) * 8) / (512000/1000) = 27.3 milliseconds (called serialization delay)
That is if the modem just started transferring a packet the next packet will need to wait for 27 ms
before it can be transmitted, this can not be remedied by any amount of clever QoS in your router. (In theory ATM based QoS could help as individual ATM cells only have a serialization delay of (53*8) / (512000/1000) = 0.828125 ms, but I doubt that your ISP is going to allow that to happen).
And on the downlink you have:
((ceil(1548/48) * 53) * 8) / (2000000/1000) = 6.996 milliseconds serialization delay.

With such a link you will need to manage your expectations and accept interference between flows/packets.

That said, sqm configured appropriately should help ameliorate your issue to some degree, but will not completely fix it. Have al look at https://github.com/moeller0/ATM_overhead_detector for how to measure the per packet overhead on your link and at https://openwrt.org/docs/guide-user/network/traffic-shaping/sqm and https://openwrt.org/docs/guide-user/network/traffic-shaping/sqm-details's " Making cake sing and dance, on a tight rope without a safety net (aka advanced features)" section for how to get the most out of SQM.
But again, it can not perform miracles and a slow link is going to stay a slow link...

At your speed, I would guess a second hand BT HomeHub5A (can be gotten from ebay, already flashed to OpenWrt, as that requires some soldering) might be able to do all the things you require, assuming its ADSL AnnexA will work for your part of the world...

2 Likes

this is a great point. 27ms is a big delay for real-time gaming purposes. For example the time between two VOIP packets is usually 20ms so this is about the same interval as a packet drop.

Also at 60Hz refresh rate the duration of an on screen frame is 1/60 ~ 17ms so you have a 2 frame delay. 4 frame if you have a 120Hz monitor

1 Like

Can you pls explain this calculations as I don't have knowledge about these things. All I know is that I can set MTU and TCP MSS Option manually (1492 is the default value for MTU and 1452 for TCP)
My ping to google DNS is 65 ms and can reach almost 100 ms max in online games.
can you please use more detaild info because I understood nothing from the rest of what wrote and why I should care about upload much so lets say I got the right stuff and have an SQM active and packets overhead measured properly and somebody used his browser how much that will effect my experience and how could my ISP help me to improve that. why not allowing what you call low serilization. What do you think is the best settings to manage my network and I am ok if that will cost 30% of my bandwidth

It is worse dude I am on 144 Hz monitor and that seems to be strange to me. Do you think that experience is worse with higher refresh rates on this bad service?

The more frames your monitor displays per second, the more frames it will display in a fixed amount of time that it takes to send a packet... basically higher image frame rates can allow you to have faster human response times, but the computer can't communicate that information any faster to the server because your packet is sitting in a queue waiting for some other packet to be sent... so basically you'll just find things frustrating because you'll see and know what should have happened, but the server won't know about what did happen because it won't get the information in time.

The issue is this... suppose there is nothing to be sent except one full size packet 1500 bytes sent by some upload process on your network... So this packet is sent to the modem. It physically takes 27.3 milliseconds to modulate the packet onto the telephone wire as an electrical signal...

Now immediately after that 1500 byte packet is sent to the modem, you click your mouse to fire in your game... Now the router sees this small, maybe 200byte packet to be sent, but it knows that your modem is going to take 27ms... so it waits 27ms and then sends this packet, which takes another 3.6 ms to be put onto the wire...

So, if there is a packet being sent just before your click... things could take up to 27.3+3.6 ~ 31 ms to get sent out onto the internet... and if there isn't a packet being sent by the modem it could take just 3.6ms to go out onto the internet...

In other words, you should expect your transmission time to vary between 3.6 and 31 ms depending on traffic at the minimum...

now if you don't have any prioritization for your game packets, then perhaps 2 or 3 packets could be in a queue... so you might experience variability of between 3.6 and say 3.6+3*27.3 ~ 85.5ms

So information about your actions would leave your network between round-off 3 and 90 ms after you take the action.

Now, if you have 144Hz display that's 144 images / second, and 90ms = .09 seconds/packet... multiply those together and you get about 13 images/packet... so information leaves your network somewhere between say 1 and 13 images behind when it occurred...

When the lag is consistent, then the server has an easier time compensating for it... but when the lag varies by this much... it will feel "random" as to the connection between what you do, and what the server decides actually happened...

The very best you can get is to never have any queue for your game packets... in which case you will experience delays between 0 and .027 * 144 ~ 4 displayed image frames.... that won't be quite so random, but it'll still be noticeable

Compare the results if you have 100Mbps upload... one 1500 byte packet takes 1500*8/1e8/.001 = 0.12 ms to send... so if you have no queue involved your 200 byte game packet will leave your network between 0.000012 * 144 = .017 images later... which is basically zero... So with 100Mbps upload you experience basically no variability in your transit time caused by your own network (you will still experience issues caused by global/ISP conditions).

A gamer with a gigabit fiber connection and a decent QoS would experience ZERO variability in timing even if their whole household were torrenting and streaming all at once, whereas a person such as yourself experiences a minimum of 4 displayed frames if there's any traffic at all and maybe a full second delay with serious uncontrolled bufferbloat.

2 Likes

It is incorrect to calculate online gaming like this. Lots is involved: rig CPU, architecture, video card. Network takes what it takes depending on algorythms/programming when certain game is created. It depens on billinon things (even input devices). Hz has nothing to do with network latency here

Sure, these are the minimum levels of delay you can achieve. The issue is serialization of the packet onto the wire. You can not send a 1500 byte packet over a 512kbps upload DSL in less than approximately 30ms calculated by @moeller0... Of course, delays can go upwards from there to infinity (your packet could be dropped and never received at all by the server).

1 Like

I never knew that upload speed effect online experience. I have seen many players with above than 100 ms and they are doing quite well, but I find it frustrating. I don't miss my targets in p2p FPS games but on dedicated servers I can't control my charecter properly and I can't perform some god movements at all so I feel like I am controlling my charecter with input delay and time sensitive data to do my actions properly is droped causing none smooth experience. So do you think in order to fix that I need faster upload speeds lets say if I was alone on the whole network and no one else is using it because I may get that but I can't change my bad ping 70-100 ms to internet.

You can`t determine the size of data required to send over certain time for a certain game as I said. I guess most online games and services suggest their requirements for connection. If you meet their minimum you can then fiddle with qos, etc. Just to improve it


If on idle connection load you get bad ping - blame your provider. Test only on ethernet cable to your rig

This isn't exactly true. You can't know exactly what the packet size will be, but you don't need to because the orders of magnitude are well understood. all packets are smaller than 1500bytes because that's the typical MTU... so you can easily calculate the variability in time it takes to send a packet, which is what was calculated here. With 512 kbps upload speed you can NOT get the variability less than about +- 30ms which is a LOT, perhaps 6 to 10 times the minimal detectable delays (musicians playing in the same room can detect MIDI delays of a few milliseconds)

@IslamGhunym yes upload speed matters. If you could move from 512kbps to 5Mbps you would have a 10x reduced minimum variability... down to about 3ms which is now becoming undetectable.

delays will always occur, but when they vary a lot, the compensation mechanisms in server code can not effectively deal with them.

1 Like

Gaming is not video streaming. You have to understand that

Of course.. it is much more time sensitive than just streaming.

So gaming network has nothing to do with just video displaying on your monitor. Nor FPS, nor Mhz. Lot is involved.
If your latency is bad on idle, you can not fix it with qos

I am a gamer and overclocker dude and I know every peace of PC hardware and how it performs on certain purposes from consumer market to server market since intel pentium 1 200 MHz that I still have it untill today and I know exactly how configure my games properly for stable frame timings and low input lag as I know exactly what kind of monitor I have from technical view, but I know nothing about networking at all. I can explain what I am experiencing as unstable frame time experience not smooth experience on perfectly configured frame rates

OK. Disconnect all other devices including phones/etc. Stop all your network hungry services and ping 8.8.8.8. Post results