From: Peer Dietzmann <dietzmann@brecht-schule.hamburg>
To: development@lists.ipfire.org
Cc: Peer Dietzmann <dietzmann@brecht-schule.hamburg>
Subject: sshd kill all sessions on deamon stop
Date: Sun, 24 Aug 2025 08:25:22 +0200 [thread overview]
Message-ID: <6d9b9a50-4479-422f-a370-540a59fa6959@brecht-schule.hamburg> (raw)
Hi All,
I discovered, that while rebooting an IPFire instance via SSH my
terminal keeps stuck after the broadcast message because IPFire isn't
closing all active connection correctly. As it is annoying especially
when using SSH in SSH connections because all connections have to be
reopened manually, I thought of adding just one line to the init-script
that closes all running sessions.
Best regards,
Peer
diff --git a/src/initscripts/system/sshd b/src/initscripts/system/sshd
index e5a9931af..e69904c61 100644
--- a/src/initscripts/system/sshd
+++ b/src/initscripts/system/sshd
@@ -50,6 +50,7 @@ case "$1" in
stop)
boot_mesg "Stopping SSH Server..."
killproc -p "/var/run/sshd.pid" /usr/sbin/sshd || true
+ killall sshd-session
;;
reload)
next reply other threads:[~2025-08-24 6:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-24 6:25 Peer Dietzmann [this message]
2025-08-24 12:55 ` Michael Tremer
2025-08-24 17:59 ` Peer Dietzmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6d9b9a50-4479-422f-a370-540a59fa6959@brecht-schule.hamburg \
--to=dietzmann@brecht-schule.hamburg \
--cc=development@lists.ipfire.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox