fix route-health: bulk route flush + wider health window
flush_gw_routes() deleted routes one-by-one in a loop (ip route del x127k),
which hung the oneshot service for 20+ minutes under netlink contention and
froze ALL gateway health monitoring. Replace with a single kernel-level
"ip route flush table T via GW" -- the same idiom route-update.sh already uses
for stale-gateway cleanup -- guarded by timeout 60.
Also widen the ping and vpn_status InfluxDB query windows from 1m to 3m. The
queries use last(), so a wider window does not delay reaction to a real outage;
it only stops an empty result (=> false "dead") when telegraf momentarily
starves under load. Together both changes break the flush->load->stale->flush
feedback loop.
Verified on igw: cycle time ~18s (was 20+ min), table 202 v6 routes via the
ikev2.vdska peer restored to 127259.
Co-Authored-By:
Claude <noreply@anthropic.com>
Showing
Please
register
or
sign in
to comment