Bug 12791

Summary: tc options don't work as expected
Product: Busybox Reporter: tom
Component: NetworkingAssignee: unassigned
Status: NEW ---    
Severity: normal CC: busybox-cvs
Priority: P5    
Version: 1.31.x   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Host: Target:
Build:

Description tom 2020-04-21 20:16:44 UTC
I am running the https://busybox.net/downloads/binaries/1.31.0-defconfig-multiarch-musl/busybox-armv8l on an Android device (Android 7.1.1 and kernel 3.18), and I can't get much of `tc` to work.  `tc qdisc show` works as expected, but if I run `/system/bin/busybox-armv8l tc qdisc show dev eth0` I get the error:

`tc: invalid argument '_=/system/bin/busybox-armv8l' to 'command'`

I have also tried creating a link to the binary as shown on https://busybox.net/downloads/BusyBox.html under usage.  The result was the same.

Attempting to add some delay via Netem with `/system/bin/busybox-armv8l tc qdisc add dev eth0 root netem delay 3ms` results in `tc: invalid argument 'netem' to 'command'`. Similarly, an attempt to use a token buffer filter like `tc qdisc add dev eth0 root tbf rate 256kbit buffer 1600 limit 3000` resulted in `tc: invalid argument 'tbf' to 'command'`.  Trying to delete a qdisc like `tc qdisc del dev eth0 root` results in `tc: command line is not complete, try "help"`.  These are all standard tc commands.

As the help shows, usage is tc OBJECT CMD [dev STRING]... in the "delete" example above, the OBJECT is qdisc, the CMD is del, and the dev string is dev eth0 root.

I think maybe I'm missing something fundamental, but not sure what it could be.  Thanks!!