Repository navigation
Send the client keepalive every 5 seconds - #80
Merged
Merged
Conversation
The C3X's login records show the app's shell sessions ending exactly 10 seconds after they start, which is its sshd's ClientAliveInterval: the session ends when the server's first keepalive probe is due. A client keepalive every 5 seconds means the server always sees traffic and never sends that probe. Six missed replies (30 seconds) still end a dead session. Claude-Session: https://claude.ai/code/session_01CiTeuL5wrBa86ELAzASv4B
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Evidence
The C3X's
lastrecords show most of the app's shell sessions today lasting exactly 10 seconds (e.g. 22:45:10–22:45:21, 22:26:27–22:26:37, 22:25:25–22:25:35, 18:36:12–18:36:22). Its sshd hasClientAliveInterval 10, so the session ends when the server's first keepalive probe is due. The resize and read/draw changes didn't help, because the trigger is the 10 seconds of client silence that follows.Change
The client keepalive interval goes from 15 s to 5 s (count 3 → 6, so a dead link is still noticed after 30 s). The server always sees traffic within its 10-second window and never sends its own probe.
Not verified
This avoids the trigger; it doesn't explain why the server's probe ends the shell session. Test: on the C3X, connect and leave the terminal idle for a minute. Gradle cannot run offline here, so CI is the build check.
Generated by Claude Code