Netem failure on router

Hey! Complete openWRT newbie here and I am struggling to get netem to function the way I need it to. I’m trying to adjust the entire router’s internet connection to make every device on the network experience a delay of 100ms.

So I ssh into the router and do:
tc qdisc add dev eth0 root netem delay 100ms

And it fails with ‘Error: specified qdisc kind is unknown’

Which is very strange because when I do:
tc qdisc show dev eth0

It shows me:
qdisc fq_codel 0: root refcnt 2 limit 10240p flows 1024 quantum 1518 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64

Which looks like it should take the add command from tc qdisc, right?

Btw I flashed the router with the base image. Did not flash to the upgrade build.

Any ideas on what could be wrong here???

You need to specify the netem qdisc and related parameters in the add command.

Have you already installed the kmod-netem package?

1 Like

Oh. Isn't that what the add command I have in the exmaple doing? Am I misunderstanding something?

tc qdisc add dev eth0 root
then
netem (the tool I want to use)
delay 100ms (the option from the help menu along with a value in ms)

AND WOW!
After I downloaded the package you mentioned... the command I have for hitting eth0 and adding that delay with netem worked! Now it's showing my changes! Strange that I can only have one rule at a time.. but I can work with that.

root@OpenWrt:~# tc qdisc add dev eth0 root netem delay 345ms
root@OpenWrt:~# tc qdisc show
qdisc noqueue 0: dev lo root refcnt 2
qdisc netem 8002: dev eth0 root refcnt 2 limit 1000 delay 345ms

THANK YOU SO MUCH!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.