Linux-Noob Forums

Full Version: terminating user in logging my machine
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
how do i kick the user that logging on my machine?

Firstly, find out information about that user: who should list currently-logged in users.

 

Secondly, find out what processes that user is running. ps -fu TheUserNameHere ought to do it, but you can use other commands too (just w on its own can show you some info too).

 

Thirdly, when you have the process IDs (PID column in the output from "ps") you can send them a kill signal: kill PIDhere. Note that you'll have to do this as a priviledged user (root, possibly) since ordinary users do not have rights to kill off any processes other than the ones they own.

 

Lastly, you may want to take steps from preventing that user logging in, in future if needed. If you want to head down that route, I'll post more.