Commit Graph

102 Commits

Author SHA1 Message Date
Tim Wilkinson 4ff44c2b21
Run the wireguard watchdog script every 5 minutes (#1102)
This fixes up wireguard connections to dynamically changing IP addresses
2024-02-23 23:02:45 -08:00
Tim Wilkinson f3d49eab64
Hide long time idle neighbors (#1082)
* Dont show neighbor we can't resolve or route to

* Hide neighbor which have been non-routable for over an hour
2024-01-23 00:13:01 -08:00
Tim Wilkinson e83af37894
Label wireguard tunnels in LQM (#1068) 2024-01-17 14:02:20 -08:00
Tim Wilkinson fb0f9a4b56
Update cursors on each lqm iteration. (#1067)
If we dont, and other apps change values in the config files, old
cursors dont see the new values.
2024-01-17 11:43:52 -08:00
Tim Wilkinson bb83a8d1c9
More wireguard fixes (#1059)
* More wireguard fixes

* Fix monitoring bug when finding tunnel address
2024-01-10 00:02:54 -08:00
Tim Wilkinson f1567d662f
Wireguard2 - bug fixes (#1057)
* Fix _add for wireguard

* Fix LQM for wireguard
2024-01-07 21:44:21 -08:00
Tim Wilkinson e5bd9bc066
Simply the watchdog by fixing various timeouts. (#1038)
Unfortunately there doesnt appear to be much flexibility in the various
hardware watchdogs on radios, so setting the watchdog > 60 seconds mostly
doesnt work. So rework the settings to allow for this and that our watchdog
tests must be frequent and quick.
2023-12-20 00:25:12 -08:00
Tim Wilkinson 0899ae7d02
Make watchdog easier to configure and less aggressive (#1034) 2023-12-19 12:07:47 -08:00
Tim Wilkinson cd4b99197a
Watchdog support, initial version. (#1030)
* Watchdog support, initial version.
The watchdog monitors three things:
1. A set of important system daemons.
2. A set of pingable ip addresses.
3. A time the node should reboot everyday.
2023-12-18 23:07:52 -08:00
Tim Wilkinson b2fb79d6de
Typo (#1019) 2023-12-13 23:56:38 -08:00
Tim Wilkinson ceb7e973bf
Fix xlink monitoring by lqm (#1018) 2023-12-13 23:34:08 -08:00
Tim Wilkinson b702c1cfe7
Reduce packet retries on congested nodes (#1015)
* Experimental retry management

* Limit retries
2023-12-13 15:52:44 -08:00
Tim Wilkinson 6d15dfb869
Extra bad olsr protection (#992)
* Better protection for missing olsrd files
2023-12-06 12:24:43 -08:00
Tim Wilkinson 1694e3a6c7
Simplify how we measure link performance (#975)
* Simplify the way we measure link ping times

* Dont ping non-routables
2023-12-06 12:11:11 -08:00
Tim Wilkinson bf3aa67f78
Wireguard tunnel support (#968)
* Wireguard tunnel support

* Fix wireguard firewall rules

* Add Wireguard tunnels to LQM

* Filter vlans on main bridge

* If you paste a tunnel config into any field, it will auto-populate all fields correctly

* Fix bad password keyword

* Fix bad feeds change

* Fix bad merge
2023-12-06 11:39:23 -08:00
Tim Wilkinson 475f371bb8
Initial OpenWRT 23.05.0 merge (#963)
* Initial OpenWRT 23.05.0 merge

* Fix get_rfchannels for new iwinfo format

* Fix initial wlan name

* Move patches to 5.15 from 5.10

* Fix flash write problem on Ubiquiti devices

* Use new ssl patch

* Reduce binary sizes

* Have to have hostapd installed now, even on tiny builds

* Simplify device support

* Revert Mikrotik NAND sysupgrade system.
OpenWRT doesnt really support Mikrotik NAND devices after 2019 and the
new support appeared broken. So reverted to the 2022 mechanism which does
work and avoid upgrade problems.

* Fixes for tiny builds

* More tiny shrinking

* Fix newly added firewall rules

* Update permanent packages

* Update permanent packages

* Support for Nanobeam 2AC (2.4GHz) device. 20MHz channels only.

* Update support

* Add GL.iNet B1300

* Add to radios.json

* Update supported devices

* Dont force the LAN DHCP to run

* Revert CURL SSL test

* Fix radio count when there are no radios

* Switch the lan ports on the gl-b1300

* Add support for GL.iNET Beryl MT1300

* Fix visual lat/lon setting bug

* Make the setup "Save Changes" button also save the location data

* Fix location/map system with geo location fallback

* Recolor

* Fix default bandwidth selection

* Support multi-band radios

* Generic mechanism to set compat version to 1.1

* Switch ethernet ports

* 20 MHz channels only

* Update docs

* Add ham channels to Mediatek chips (20MHz only)

* Automatically update the permpkg list when we upgrade

* Fix 10MHz mode for Ubiquiti AC devices

* Fix tiny builds

* Bump the watch timeout for restarting olsrd
olsrd is reliable these days, and very occasionally this
was restarting it unnecessarily
2023-12-06 10:12:11 -08:00
Tim Wilkinson 63788ec9b1
Move cron.boot earlier (#955) 2023-10-07 10:52:54 -07:00
Steve 2d9914cb35
change pollrate default to one hour (#954) 2023-10-05 13:38:05 -07:00
Tim Wilkinson 880a4f195a
Improve the way we HUP dnsmasq (#953) 2023-09-29 20:09:53 -07:00
Tim Wilkinson 57e0d045e9
Supernode fixes (#944)
* Subdomain check too slow for realtime
 so now do it in the namecheck service instead.
* Dont commit to VPN address until we set the DNS name
 helps supernode setup
2023-09-21 20:13:38 -07:00
Tim Wilkinson 9b4d873778
Lqm neighbor improvements (#933)
* Improve detection of valid neighbors via the arp cache.
Was incorrectly excluding some.

* Fixes
2023-09-17 23:12:33 -07:00
Tim Wilkinson 1708c4926c
Remember and reinstall packages are firmware upgrade (#930) 2023-09-15 21:16:27 -07:00
Tim Wilkinson 000b40b362
Xlink broadcast (#926)
* Support empty peer (so broadcast on vlan)

* Detect and monitor peerless (broadcast) xlinks
2023-09-04 22:37:59 -07:00
Tim Wilkinson 056b60bb4d
Use wifi assoc list when looking for unresponsive nodes. (#881)
The arp cache keeps wifi entries long past them being associated with
the node, so now use wifi assoc list to find nodes, and the arp cache
to get their IPs.
2023-06-24 23:37:48 -07:00
Tim Wilkinson 270d7fd5f1
Typo (#876) 2023-06-21 13:57:21 -07:00
Tim Wilkinson 7650b627e8
Minor wifi monitor improvements for better metrics reporting (#875) 2023-06-20 20:51:18 -07:00
Tim Wilkinson 8c4d9edd99
Merge all the station monitoring and mitigation into a single service. (#874)
This is an attempt to unify all the station monitoring and make it work
better as one. We're trying to square a circle here somewhat, with taking
steps to kick nodes when problems are detected, but not kick them too quickly
or often in case we're mis-identifing issues.
We've seen these issue manifest themselves which nodes messing VoIP services
as well as resets causing nodes to get into unrecoverable states when there
was no real problems in the first place.
This will probably need to evolve before the next release, but would be good
to get some milage on the new code.
2023-06-20 01:27:23 -07:00
Tim Wilkinson 52c7286a4c
Remove another coverage test which causes problems. (#871)
Coverage is handled by modifying firmware state, and the driver stores
the values the first time it is set. When we reset this state might be lost
so it will be reloaded from the firmware. We set the coverage back to 0
so the reloaded value will be the default again.
We also remove a check which can fail incorrectly.
2023-06-12 23:29:38 -07:00
Tim Wilkinson 8f6e943237
Avoid fatal error if mac disappears across a radio reset (#868) 2023-06-08 21:27:37 -07:00
Tim Wilkinson b64aa0c988
Monitor bug fixes (#867) 2023-06-07 22:42:42 -07:00
Tim Wilkinson a61dfcdafe
Alternate ath9k and ath10k radio reset for deaf nodes (#857)
* A scan, especially if we have to do both active and passive, essentially mutes
the radio to AREDN traffic for 10-20 seconds, which isn't good. If the radio is completely
deaf then it doesn't matter, but particularly on the 9K radios we do this when
things are looking a bit dodgy, though not deaf. 
* Provide hook to reset ath9k from userspace.  This hook is attributed to:
Linus Lüssing <ll@simonwunderlich.de>
* User /sys reset hooks rather than iw scan
2023-06-01 17:06:39 -07:00
Tim Wilkinson 4e621baf0b
Support switching mesh radio on multi-radio devices (#847) 2023-05-25 21:27:59 -07:00
Tim Wilkinson e5a0b43480 Fix occasional nil error 2023-04-11 00:38:35 -07:00
Tim Wilkinson 922949abc0
Eliminate false network rejoins using LQM information (#781)
* Use LQM information to filter out neighbors we dont care about.
These can cause false rejoin events and degrade the network.
* Only use active station monitor with LQM info.
2023-04-10 10:21:30 -07:00
Tim Wilkinson 211006b47c
Resolve unresponsive node problems with Mikrotik AC devices. (#776)
* Resolve unresponsive node problems with Mikrotik AC devices.
Mikrotik AC devices get into a state where they wont communicate with
non-AC devices .. sometimes. Leaving and rejoinging the network resets
everything. We monitor for this situation and rejoin the network when detected
to resolve the issue.
* Make reporting less chatty
2023-04-02 01:29:46 -07:00
Tim Wilkinson 59ed665f3d
General station monitor logging service. (#767)
* General station monitor service.
It turns out this station bug is not limited to the ath10k driver, so
make this monitor service wifi generic.
(I've now seen this at both ends of the Mikrotik AC <-> Rocket pair)
* New logs
* Just monitor for now
2023-03-30 11:36:31 -07:00
Tim Wilkinson 933e411a10 Force badly associated stations to reassociate.
There appears to be a bug in the ath10k firmware for Mikrotik devices (maybe others)
where a station will associate but only broadcast traffic will be passed - unicast traffic
will fail. This code detects this situation and forces the device to reassociate which
fixes the problem.
2023-03-28 18:41:28 -07:00
Tim Wilkinson 05d247d15f
Fix rule checking for existing drop rules. (#719) 2023-02-17 21:07:39 -08:00
Tim Wilkinson 32e02de328
Fix fccid beacon (#717) 2023-02-17 21:06:04 -08:00
Tim Wilkinson 61fa802f80
Fix monitors not detecting non-mesh mode (#716) 2023-02-17 21:02:21 -08:00
Tim Wilkinson 9ae6e13ee0 Force dnsmasq to update itself if no network changes for > 60secs
On small networks there are not a lot of OLSR name changes. While
dnsmasq watches for changes and updates itself, it will sometimes miss
them. On busy networks this doesnt matter as the next change will catch
it up. But on smaller network (esp. test networks) a missed change can
stop name resolution working for some time. So now, if no changes are
detected for > 60 seconds, we force dnsmasq to reload its tables.
2023-02-15 20:21:17 -08:00
Tim Wilkinson dd00c7b1c3 Fix the bandwidth reporting for ath10k devices 2023-02-15 20:14:53 -08:00
Tim Wilkinson 214a93367a
Fix AC coverage calculation in driver. (#710)
For some reason, there was code in the driver to block the setting of
the coverage when a previous setting wasn't a particular value.
It's unclear what this was trying to achieve or prevent, but it stopped AC
devices operating efficiently (by a factor of 10x or more).
2023-02-12 15:50:49 -06:00
Tim Wilkinson 6834271946
Reworked ARP cache (#707) 2023-02-11 13:45:04 -06:00
Tim Wilkinson 571dbf6251
Disable RTS by default in ath10k devices 02/11/2023 (#706) 2023-02-11 13:44:10 -06:00
Tim Wilkinson c70a23f7a8
Improve LQM distance management 02/11/2023 (#705) 2023-02-11 13:43:36 -06:00
Tim Wilkinson 062ffb3521
Normalize the case of the macs and node names (#700) 2023-02-11 13:42:03 -06:00
Tim Wilkinson 863d098554 Filter even earlier 2023-02-03 09:39:28 -10:00
Tim Wilkinson eefcc888dc Filter out non-routable ARP entries which confuse LQM 2023-02-03 09:39:28 -10:00
Tim Wilkinson 33684d22d2
Gather statistics about RF links (#684) 2023-01-29 21:21:58 -06:00