Validating NSS fq_codel's correctness

@KONG,

I've "installed" the NSS SQM scripts from your repo on my R7800:

I've also "installed" the selectable NSS.qos setup script option from your repo:

I've enabled SQM this way on a stable 21.02 build from @ACwifidude's repo (OpenWrt 21.02-SNAPSHOT r16328+19-f441be3921).

When I look at the log I see some errors, I'd like to resolve them to get SQM with NSS running based on your latest findings but realize I might be walking on thin ice here. Maybe you can tell from the messages what I've done wrong?

Wed Nov 24 11:35:05 2021 user.notice SQM: Starting SQM script: nss.qos on eth1, in: 490000 Kbps, out: 490000 Kbps
Wed Nov 24 11:35:06 2021 daemon.err modprobe: failed to find a module named act_ipt
Wed Nov 24 11:35:06 2021 daemon.err modprobe: failed to find a module named sch_fq_codel
Wed Nov 24 11:35:06 2021 kern.err kernel: [102179.705566] debugfs: File 'virt_if' in directory 'stats' already present!
Wed Nov 24 11:35:06 2021 kern.info kernel: [102179.705885] Created a NSS virtual interface for dev [nssifb]
Wed Nov 24 11:35:06 2021 kern.info kernel: [102179.711564] NSS IFB data callback registered
Wed Nov 24 11:35:06 2021 kern.info kernel: [102179.717390] NSS IFB transmit callback registered
Wed Nov 24 11:35:06 2021 kern.info kernel: [102179.722088] NSS IFB module loaded.
Wed Nov 24 11:35:06 2021 daemon.err modprobe: failed to find a module named act_ipt
Wed Nov 24 11:35:06 2021 daemon.err modprobe: failed to find a module named sch_fq_codel
Wed Nov 24 11:35:07 2021 user.notice SQM: ERROR: cmd_wrapper: tc: FAILURE (2): /sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 0 u32 match ip protocol 1 0xff flowid 1:13
Wed Nov 24 11:35:07 2021 user.notice SQM: ERROR: cmd_wrapper: tc: LAST ERROR: RTNETLINK answers: Not supported We have an error talking to the kernel
Wed Nov 24 11:35:07 2021 user.notice SQM: ERROR: cmd_wrapper: tc: FAILURE (2): /sbin/tc filter add dev eth0 parent 1:0 protocol ipv6 prio 1 u32 match ip protocol 1 0xff flowid 1:13
Wed Nov 24 11:35:07 2021 user.notice SQM: ERROR: cmd_wrapper: tc: LAST ERROR: RTNETLINK answers: Not supported We have an error talking to the kernel
Wed Nov 24 11:35:07 2021 user.notice SQM: WARNING: sqm_start_default: nss.qos lacks an egress() function
Wed Nov 24 11:35:07 2021 kern.warn kernel: [102180.383768] nss_qdisc_init[1993]:NSS qdisc 25ef04a5 (type 1) used along with non-nss qdiscs, or the interface is currently down
Wed Nov 24 11:35:07 2021 kern.info kernel: [102180.393108] 61a7cae9: Found net device [eth0]
Wed Nov 24 11:35:07 2021 kern.info kernel: [102180.403845] 61a7cae9: Net device [eth0] has NSS intf_num [1]
Wed Nov 24 11:35:07 2021 kern.info kernel: [102180.409845] Nexthop successfully set for [eth0] to [nssifb]
Wed Nov 24 11:35:07 2021 user.notice SQM: nss.qos was started on eth0 successfully

I reckon that SQM isn't working (properly) on eth1. It's probably because some kernel modules to be loaded can't be found. That very likely results in the message that the cmd_wrapper is unable to talk to the kernel.

I'm also a bit puzzled that SQM is also started on eth0 since I explicitly set eth1:

root@OpenWrt:/etc/config# cat sqm

config queue 'eth1'
        option interface 'eth1'
        option linklayer 'none'
        option verbosity '5'
        option qdisc 'fq_codel'
        option script 'nss.qos'
        option download '490000'
        option upload '490000'
        option debug_logging '1'
        option enabled '1'

Any clues what I did wrong?

--EDIT--
I've found this:

And indeed, that package is not installed on this build. Since it's a community build, I can't install it anymore. I was able to install those missing packages, the modules are loaded (checked with lsmod. There is one module missing however:

daemon.err modprobe: failed to find a module named sch_fq_codel

I can't find it in the modules directory, these are the ones loaded:

# lsmod | grep sch_
sch_cake               40960  0 
sch_codel              20480  0 
sch_dsmark             20480  0 
sch_fq                 20480  0 
sch_gred               24576  0 
sch_hfsc               28672  0 
sch_htb                28672  0 
sch_ingress            16384  0 
sch_multiq             16384  0 
sch_pie                20480  0 
sch_prio               20480  0 
sch_red                20480  0 
sch_sfq                24576  0 
sch_tbf                20480  0 
sch_teql               16384  0 

Since I see a sch_codel and a sch_fq, could it be a (re)naming issue of module names or is there actually another module sch_fq_codel?