[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: remote user, putty ssh




I must be brain dead today.
Thanks for your help Florian.

Florian Kulzer <florian@molphys.leidenuniv.nl> wrote:
On Sun, Jan 07, 2007 at 18:23:39 +1100, Tom D wrote:
> Hi people,
> How do you log a user off that is logged into a server via putty / ssh
> when its connection has become disrupted for example a users internet
> connection has been dropped from their isp and their account is still
> logged into the remote computer even though they are offline. When
> I'm logged in I dont know howto log the other account off, how do I do
> this?

Most likely you will be automatically logged out after a certain time of
inactivity.

If you want to be sure you can ssh to the machine and run

ps -u $(whoami)

This will list all your processes. You should see an entry with "sshd"
in the command (CMD) field for every active ssh connection. You can kill
stale sshd processes with "kill PID" with PID being the process ID (the
first column in the ps listing).

echo $PPID

will give you the PID of the sshd process for your current connection.
If you kill that one you will terminate your session.

Another handy command to list all logged-in users is "w". (It is really
just one letter.)

--
Regards,
Florian


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


Send instant messages to your online friends http://au.messenger.yahoo.com


Reply to: