Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/interplane-forge/blob/main/infra/hub/sshd-forward-keepalive.conf # interplane-forge INTERPLANE Forge Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `interplane-forge / infra / hub / sshd-forward-keepalive.conf` 17 lines ยท 1282 bytes Raw Blame History 1 # /etc/ssh/sshd_config.d/40-forward-keepalive.conf on the hub Pi. forge-iplreach (L1008 QW1, card t_`0ef9cf5d`). 2 # Installed by infra/hub/sshd-keepalive-apply.sh; removed by infra/hub/sshd-keepalive-rollback.sh. 3 # 4 # Why: the Spark keeps reverse tunnels into the hub with `ssh -R` (aien-floor-edge 4748, forged-tunnel 5 # 18480, rad-hub-tunnel 18776). When the hub stalls or the link drops, the Spark side gives up after 6 # its ServerAlive budget and reconnects, but the hub's sshd kept the dead session, and with it the 7 # forwarded port, until the kernel's TCP keepalive gave up: 7200 s + 9 x 75 s = 7875 s (2 h 11 min). 8 # Every reconnect in that window failed with "remote port forwarding failed for listen port ...". 9 # Measured 2026-11-08: aien-floor-edge restarted 1296 times between 13:52:49 and 15:59:43 (CST). 10 # 11 # With these lines sshd itself asks each client every 15 s and drops a session once 4 asks in a row 12 # have gone unanswered, which frees its forwarded ports: about 75 s after the client goes silent 13 # (the drop happens at the 5th ask; test/sshd-keepalive.sh measured 76 s). A live client answers 14 # every ask, so working sessions are unaffected. First match wins in sshd_config, so this file sorts 15 # before 50-cloud-init.conf. 16 ClientAliveInterval 15 17 ClientAliveCountMax 4