auto-apply MTU once on first WG handshake (probe + rewrite + restart)
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
1 parent
7406096b79
commit
b1085fd23c
3 files changed
+71
-1
No files matched your search
@@ -85,6 +85,13 @@ age=$(handshake_age)
|
||||
lost=$(in_tunnel_ping)
|
||||
streak=$(read_streak)
|
||||
|
||||
# One-shot MTU probe on the first-ever successful handshake. The apply
|
||||
# helper short-circuits on its own marker; we only skip the fork here to
|
||||
# avoid spawning a subshell every tick once the marker exists.
|
||||
if [[ "$age" -ge 0 && ! -e /var/lib/wirecon/mtu-probed.flag ]]; then
|
||||
( /usr/local/bin/wirecon-mtu-apply.sh >>/var/log/wirecon-mtu.log 2>&1 ) &
|
||||
fi
|
||||
|
||||
reason=""
|
||||
if [[ "$age" -lt 0 ]]; then
|
||||
reason="no handshake ever"
|
||||
|
||||
Reference in new issue
Block a user