SSH ClientAliveCountMax & ClientAliveInterval not working
Clash Royale CLAN TAG#URR8PPP
I changed the following SSH config (and rebooted the SSH, or even rebooted the server):
ClientAliveCountMax 120
ClientAliveInterval 720
LoginGraceTime 300
Problem is that the parameter "LoginGraceTime" takes effect, I change it and it works. However the other 2 are not working. The server kicks out me after few minutes (4-5 minutes, as was before). If I comment them and restart SSH does not work, it continues kicking out me.
Is there any other parameter interfering with these 2?
ssh openssh sshd
add a comment |
I changed the following SSH config (and rebooted the SSH, or even rebooted the server):
ClientAliveCountMax 120
ClientAliveInterval 720
LoginGraceTime 300
Problem is that the parameter "LoginGraceTime" takes effect, I change it and it works. However the other 2 are not working. The server kicks out me after few minutes (4-5 minutes, as was before). If I comment them and restart SSH does not work, it continues kicking out me.
Is there any other parameter interfering with these 2?
ssh openssh sshd
Is there a possibility that the server terminates inactive shell sessions using some means that is unrelated to SSH? It is unclear what you actually mean by "kicks out". It could mean that the SSH connection is terminated, but it could also mean that the shell session is terminated.
– Kusalananda
Feb 14 at 9:38
Try running thesshd
server as a regular user on a non-privileged port with debugging turned on:/usr/sbin/sshd -ddd -h ~/.ssh/id_rsa -p 2222 -o PidFile=none
, then connect to it withssh -p 2222 user_sshd_was_started_as@host
, and add the (edited) debugging output ofsshd
to your question if that's also kicking you out after 4-5 minutes (sshd will still use/etc/ssh/sshd_config
when started like that).
– mosvy
Feb 14 at 10:20
add a comment |
I changed the following SSH config (and rebooted the SSH, or even rebooted the server):
ClientAliveCountMax 120
ClientAliveInterval 720
LoginGraceTime 300
Problem is that the parameter "LoginGraceTime" takes effect, I change it and it works. However the other 2 are not working. The server kicks out me after few minutes (4-5 minutes, as was before). If I comment them and restart SSH does not work, it continues kicking out me.
Is there any other parameter interfering with these 2?
ssh openssh sshd
I changed the following SSH config (and rebooted the SSH, or even rebooted the server):
ClientAliveCountMax 120
ClientAliveInterval 720
LoginGraceTime 300
Problem is that the parameter "LoginGraceTime" takes effect, I change it and it works. However the other 2 are not working. The server kicks out me after few minutes (4-5 minutes, as was before). If I comment them and restart SSH does not work, it continues kicking out me.
Is there any other parameter interfering with these 2?
ssh openssh sshd
ssh openssh sshd
edited Feb 14 at 5:53
slm♦
251k69529685
251k69529685
asked Jan 30 at 15:41
MarcelMarcel
62
62
Is there a possibility that the server terminates inactive shell sessions using some means that is unrelated to SSH? It is unclear what you actually mean by "kicks out". It could mean that the SSH connection is terminated, but it could also mean that the shell session is terminated.
– Kusalananda
Feb 14 at 9:38
Try running thesshd
server as a regular user on a non-privileged port with debugging turned on:/usr/sbin/sshd -ddd -h ~/.ssh/id_rsa -p 2222 -o PidFile=none
, then connect to it withssh -p 2222 user_sshd_was_started_as@host
, and add the (edited) debugging output ofsshd
to your question if that's also kicking you out after 4-5 minutes (sshd will still use/etc/ssh/sshd_config
when started like that).
– mosvy
Feb 14 at 10:20
add a comment |
Is there a possibility that the server terminates inactive shell sessions using some means that is unrelated to SSH? It is unclear what you actually mean by "kicks out". It could mean that the SSH connection is terminated, but it could also mean that the shell session is terminated.
– Kusalananda
Feb 14 at 9:38
Try running thesshd
server as a regular user on a non-privileged port with debugging turned on:/usr/sbin/sshd -ddd -h ~/.ssh/id_rsa -p 2222 -o PidFile=none
, then connect to it withssh -p 2222 user_sshd_was_started_as@host
, and add the (edited) debugging output ofsshd
to your question if that's also kicking you out after 4-5 minutes (sshd will still use/etc/ssh/sshd_config
when started like that).
– mosvy
Feb 14 at 10:20
Is there a possibility that the server terminates inactive shell sessions using some means that is unrelated to SSH? It is unclear what you actually mean by "kicks out". It could mean that the SSH connection is terminated, but it could also mean that the shell session is terminated.
– Kusalananda
Feb 14 at 9:38
Is there a possibility that the server terminates inactive shell sessions using some means that is unrelated to SSH? It is unclear what you actually mean by "kicks out". It could mean that the SSH connection is terminated, but it could also mean that the shell session is terminated.
– Kusalananda
Feb 14 at 9:38
Try running the
sshd
server as a regular user on a non-privileged port with debugging turned on: /usr/sbin/sshd -ddd -h ~/.ssh/id_rsa -p 2222 -o PidFile=none
, then connect to it with ssh -p 2222 user_sshd_was_started_as@host
, and add the (edited) debugging output of sshd
to your question if that's also kicking you out after 4-5 minutes (sshd will still use /etc/ssh/sshd_config
when started like that).– mosvy
Feb 14 at 10:20
Try running the
sshd
server as a regular user on a non-privileged port with debugging turned on: /usr/sbin/sshd -ddd -h ~/.ssh/id_rsa -p 2222 -o PidFile=none
, then connect to it with ssh -p 2222 user_sshd_was_started_as@host
, and add the (edited) debugging output of sshd
to your question if that's also kicking you out after 4-5 minutes (sshd will still use /etc/ssh/sshd_config
when started like that).– mosvy
Feb 14 at 10:20
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f497724%2fssh-clientalivecountmax-clientaliveinterval-not-working%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f497724%2fssh-clientalivecountmax-clientaliveinterval-not-working%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Is there a possibility that the server terminates inactive shell sessions using some means that is unrelated to SSH? It is unclear what you actually mean by "kicks out". It could mean that the SSH connection is terminated, but it could also mean that the shell session is terminated.
– Kusalananda
Feb 14 at 9:38
Try running the
sshd
server as a regular user on a non-privileged port with debugging turned on:/usr/sbin/sshd -ddd -h ~/.ssh/id_rsa -p 2222 -o PidFile=none
, then connect to it withssh -p 2222 user_sshd_was_started_as@host
, and add the (edited) debugging output ofsshd
to your question if that's also kicking you out after 4-5 minutes (sshd will still use/etc/ssh/sshd_config
when started like that).– mosvy
Feb 14 at 10:20