Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
logout other users from system
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2408
Location: Edmonton, AB

PostPosted: Sun Feb 24, 2013 7:23 am    Post subject: logout other users from system Reply with quote

How to force logout other users from the system?

When I login over ssh and "w" gives me:
Code:
w
 00:12:57 up 14 min,  6 users,  load average: 0.99, 0.87, 0.59
USER     TTY        LOGIN@   IDLE   JCPU   PCPU WHAT
joseph   :0.0      00:10   ?xdm?  47.77s  0.01s /bin/sh /etc/X11/Sessions/Xfce4
joseph   pts/0     00:10    2:40   0.00s  0.00s bash
joseph   pts/1     00:10    2:40   0.00s  0.00s bash
joseph   pts/2     00:10    2:40   0.00s  0.00s bash
joseph   pts/3     00:05    0.00s  0.02s  0.00s sshd: joseph [priv]
joseph   :0.0      00:10   ?xdm?  47.77s  0.01s /bin/sh /etc/X11/Sessions/Xfce4

if I type: pkill -KILL -u joseph
I will logout myself as well.

When I kill "xdm" (graphical interface) via ssh "w" gives me:
Code:
 w
 00:19:54 up 21 min,  3 users,  load average: 0.69, 0.78, 0.65
USER     TTY        LOGIN@   IDLE   JCPU   PCPU WHAT
joseph   pts/3     00:05    0.00s  0.02s  0.00s sshd: joseph [priv]

it does not list all users, why?
In addition, I don't have a console display either just blank screen.
_________________
#Joseph
Back to top
View user's profile Send private message
Hu
Watchman
Watchman


Joined: 06 Mar 2007
Posts: 9168

PostPosted: Sun Feb 24, 2013 5:43 pm    Post subject: Reply with quote

Kill only the processes associated with the specific login you want to kill. If everything is under the same user ID, then you need to kill the processes by PID.

Killing XDM is probably not a good idea. Instead, you should kill the window manager and its children.
Back to top
View user's profile Send private message
PaulBredbury
Watchman
Watchman


Joined: 14 Jul 2005
Posts: 7310

PostPosted: Sun Feb 24, 2013 7:51 pm    Post subject: Re: logout other users from system Reply with quote

Joseph_sys wrote:
I don't have a console display either just blank screen.

Try pkill -TERM for xdm, to kill it less harshly, and perhaps it will give you a console display before it breathes its last breath ;)

That is, if you *are* wanting to kill xdm.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum