Spectral scan not working on 18.06?

Hello,

I am trying to get some spectral readings on my network, and I have some old WR740N that would make fine sniffers. I did this before on Chaos Calmer and it worked fine. But with the newer version the first command fails with permission denied.

root@cliente:~# echo chanscan >  /sys/kernel/debug/ieee80211/phy0/ath9k/spectral_scan_ctl
-ash: can't create /sys/kernel/debug/ieee80211/phy0/ath9k/spectral_scan_ctl: Permission denied

I tried the naive approach of changing permissions on the directory (writing permissions are off), but no game, even with right permissions I could not create the file.

I worked backwards by installing 18.06.0 (same problem) and 17.01.6, which worked.

For this test I can (and will) install 17.01.6 and run with it. But I would like to make a more permanent measurement framework, so using the latest version would be better.

I see two scenarios - one is that I am obsolete, and there is a better (right) way of getting spectral scans now - I just did not find it. Then you list readers can enlighten me and I will get my data the new way. The second is that there was a change (maybe in the kernel?) and some patching is needed to make it work again.

For those interested in doing the same, both ath9k and ath10k have built-in spectral analysers - maybe not great, but hey, it is there - I used those links to get info:

https://blog.altermundi.net/article/playing-with-ath9k-spectral-scan/

--schara

PS:

Just for completeness, the permissions on 17.0.6

root@cliente:~# ls -l /sys/kernel/debug/ieee80211/phy0/
-rw-------    1 root     root             0 Oct 24 20:05 aqm
drwxr-xr-x    2 root     root             0 Oct 24 20:05 ath9k

and on 18.0.1

root@cliente:~# ls -l /sys/kernel/debug/ieee80211/phy0/
-rw-------    1 root     root             0 Oct 24 20:05 aqm
drwxr-xr-x    2 root     root             0 Oct 24 20:05 ath9k

are the same, So it seems that the problem is somewhere else.

1 Like

Its been a long time but any solutions for this?
Getting same her eon 18.06

echo chanscan > /sys/kernel/debug/ieee80211/phy0/ath9k/spe
ctral_scan_ctl
-ash: can't create /sys/kernel/debug/ieee80211/phy0/ath9k/spectral_scan_ctl: Permission denied

Not to revive a dead thread, but I want to make sure this gets answered for other passers-by:

It looks like spectral scan being missing in 18.06 is the result of the spectral scan going under a different debug symbol -- https://lists.infradead.org/pipermail/lede-commits/2018-January/005699.html

Anyways, spectral scan is now disabled by default as a result. That's probably a bug? I don't know.

You can get it back by building your own image. You want PACKAGE_ATH_SPECTRAL. This has to be built into the kernel so you can't just install it.

You can find it in make menuconfig under Kernel modules > Wireless > kmod-ath; select 'Atheros wireless debugging' and the 'Atheros spectral scan' option will appear.

Building now so I can see it work. I've needed this for a wireless mess for a while for band monitoring.