Repository navigation
WiFi Insight 2.0.0
Entware is no longer needed, routers with two radios on one band (or four radios) are supported, and the history database is checked before every use. With these changes the history moves to a wifiinsight folder on the USB drive when you update (a rename on the same drive: nothing is copied), hence the new major version.
- Entware isn't needed any more. WiFi Insight uses the firmware's own
sqlite3(every Merlin from 386.1 has one with what it needs: 3.25.3, or 3.42.0 from 3004.388.6), and Entware's only where the firmware has none. The history goes in awifiinsightfolder on the USB drive itself (/tmp/mnt/<drive>/wifiinsight, the drive Entware is on if you have it), as Skynet keeps its data; with several drives and no Entware, the installer asks which. An existing install moves its history there from Entware's/opt/var/lib/wifiinsightwhen you update: a rename on the same drive, so it's the same file and nothing is copied, with sampling and scans held off meanwhile; a link is left at the old path. The history is never kept in RAM: if the drive isn't mounted, nothing is written until it is.wifiinsight.sh migratedoes the move on its own, and history kept by an earlieruninstall --keep-datais picked up by the next install and moved the same way. - Routers with two radios on one band, or four radios. The GT-AX11000, GT-AX11000 Pro and ZenWiFi Pro XT12 (two 5 GHz radios), the GT-AXE16000 (two 5 GHz, a 6 GHz and a 2.4 GHz radio) and the GT-BE98 Pro (a 5 GHz, two 6 GHz and a 2.4 GHz radio) used to be refused by the check: their two radios on one band would have written over each other, and on the four-radio routers the 2.4 GHz radio wasn't read at all. Now each radio is kept apart, with its own button, history, scans and results, named as on the router's own Wireless pages: 5 GHz-1 and 5 GHz-2, or 6 GHz-1 and 6 GHz-2. Routers with one radio per band keep their history as it was. The layouts come from the Asuswrt-Merlin source; they haven't run on these routers yet, so a report from one is welcome.
- The history database can't be turned against the router. It lives on the USB drive, which a guest Samba or anonymous FTP share, or anyone with the drive in hand, may be able to write to. A database someone put there with an extra table, trigger or view could have made sqlite3 write files as root (a CHECK constraint calling
writefile()does, even on sqlite 3.42.0). Now every sqlite3 run checks first that the database holds only what WiFi Insight creates, and stops if it doesn't; the syslog andstatussay so, andrepairwon't touch it. The page also treats its numbers as numbers, so nothing from the database can add markup to it, and WiFi Insight never writes through a link left in its folder. - One-channel scans are spread out, as a fallback only. On routers that refuse full 5 GHz scans, 1.3.0 scanned the band one channel at a time in a burst of up to two and a half minutes at every scheduled scan. A full scan is still always tried first, and the first refusal still gets that burst. After that, each scheduled scan starts a sweep spread over about a third of the scan interval instead (10 minutes with 30-minute scans: 2 channels a minute on a 19-channel band, at most 3), then rests until the next one. It skips a minute while your own Wi-Fi traffic is high, but not for longer than the scan interval, and never runs in quiet hours. Each channel is one short trip off your channel rather than many in a row. Scheduled scans retry a full scan every 6 hours, and the spreading stops as soon as one works or the router moves to another channel. Routers whose full scans work never do any of this. Scan now still scans the whole band at once. A new cron job,
wifiinsight_trickle, runs it. - When your router refuses 5 GHz scans on a DFS channel, the page says what avoids it. Some routers refuse full 5 GHz scans while on a DFS channel; many don't (an RT-AX86U in Europe scans them fine). Only when your router's scans were refused, or had to go one channel at a time, while it's on a DFS channel, the Spectrum, Site Survey and Channel Statistics now add that a channel outside 52–144 avoids it (in Wireless → General, un-tick "Enable 160 MHz" and "Auto select channel including DFS channels"), and what that costs. Thanks to SashaSolitaire for finding it!
- Radar lines are read in a moment. When a new radar detection appeared in the syslog, WiFi Insight read every radar line in it again, starting about a dozen small programs per line: on a router with many detections that kept it busy for a minute or two, at low priority. Now it's one pass (1800 lines: 1 second instead of 2 minutes), with the same times and radios as before.
- 320 MHz on 6 GHz is read correctly. On Wi-Fi 7 routers (RT-BE96U, RT-BE92U, GT-BE19000AI, GT-BE98 Pro), a 6 GHz radio at 320 MHz showed as 160 MHz, drawn around the wrong channel.
- Hidden networks from your own devices count as yours. An AiMesh node's hidden backhaul or a Wi-Fi 7 router's extra links have no name, so they counted as neighbours and as interference. A hidden network whose address matches one of your named networks' in all but the first byte and the last 4 bits, which only the same device shares, now counts as yours.
- A warning when the history drive has no journal. On ext2, FAT, exFAT, NTFS, or ext4 made without a journal (amtm offers that), a power cut while the drive is writing can damage the database, as happened on a GT-AX6000.
check,status,debugand the Settings tab now name the drive's filesystem and say so, and the damaged-database warning mentions it. ext3/ext4 with a journal are fine. - An old copy hands over to the installed script. The install command downloads the script to
/tmp/wifiinsight.sh, and that copy stayed there until a reboot: running it later (sh /tmp/wifiinsight.sh scan, say) ran the old version's code, which made a 1.3.0 router look like 1.2.0. Nowinstallremoves that copy when it's done, and a copy whose version differs from the installed one says so and runs the installed script instead (except forinstall,update,uninstall,checkandversion). - Scan now also refreshes the channel tile, which could show the old channel for up to a minute after a channel change.
- If you go back to an earlier version, its cron jobs don't include
wifiinsight_trickle: a reboot removes it, or runcru d wifiinsight_trickle.
Install or update
Over SSH on the router:
curl -fsL --retry 3 "https://raw.githubusercontent.com/IfSugar/wifiinsight/2.0.0/wifiinsight.sh" -o /tmp/wifiinsight.sh && sh /tmp/wifiinsight.sh installAlready installed? Run /jffs/addons/wifiinsight/wifiinsight.sh update. Your settings and history are kept.
Full diff: 1.3.0...2.0.0