Subject: [alpine-devel] heads up: new behaviour of sshd stop

From: Natanael Copa <[email-masked]>
Date: Tue, 16 Mar 2010 09:35:31 +0100

Hi,

Just a heads-up for you who uses ssh on remote boxes.
Do not run '/etc/init.d/sshd stop' when connected remotely. You will
from now on be disconnected when doing so.

Before:
 * /etc/init.d/sshd stop does not kill the running ssh sessions and
does not disconnect you if you are logged on remotely.
 * doing reboot remotely ends with a timeout since the network is
shutdown before the ssh session gets killed by the final killall.
 * /etc/init.d/sshd restart would not disconnect you

Now:
 * /etc/init.d/sshd stop will kill your running ssh sessions and you
will get disconnected
 * doing reboot remotely shoudl give you a clean disconnect
 * /etc/init.d/sshd restart will not disconnect you

So basicly, this is just a heads up to be careful when you are logged
on remotely via ssh: Do *not* run '/etc/init.d/sshd stop' You will get
disconnected. Running '/etc/init.d/sshd restart' should be safe
though.

-- 
Natanael Copa

---
Unsubscribe:  [email-masked]
Help:         [email-masked]
---

---

From: Harry Lachanas <[email-masked]>
Date: Tue, 16 Mar 2010 10:50:09 +0200

Not  convenient !!!

Does this apply to DropBear too ???

Regards,
Harry

---

---

From: Natanael Copa <[email-masked]>
Date: Tue, 16 Mar 2010 14:05:11 +0100

> Not  convenient !!!

/etc/init.d/sshd restart will not disconnect you

Just don't run '/etc/init.d/sshd stop' alone and you'll be safe.

> Does this apply to DropBear too ???

No, I dont know how dropbear does it, but it will be unchanged.

-- 
Natanael Copa

---

---

From: Timo Teräs <[email-masked]>
Date: Tue, 16 Mar 2010 15:32:17 +0200

Hi,

> Just don't run '/etc/init.d/sshd stop' alone and you'll be safe.

Right. Isn't the standard behaviour that before executing umount and
otherstuff, some other initscript runs killall5 to kill any remaining
user processes.

Yes, alpine killprocs does that. You just need to run it before
umounting disks.

Please revert ssh init.d change.

- Timo

---

---

From: Natanael Copa <[email-masked]>
Date: Tue, 16 Mar 2010 15:15:35 +0100

> Yes, alpine killprocs does that. You just need to run it before

and before shutting down the network so current sessions are closed cleanly.

how do you do that with openrc?

> Please revert ssh init.d change.

done

-- 
Natanael Copa

---

---

From: Timo Teräs <[email-masked]>
Date: Tue, 16 Mar 2010 16:21:07 +0200

> and before shutting down the network so current sessions are closed cleanly.

Huh? "ifconfig ethX down" will kill all your ssh connections for you.
I think killprocs is ok to be run just only before unmounting disks.

- Timo

---