Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

removing user from console

If none of the specific sub-forums seem right for your thread, ask here.
Post Reply
Message
Author
nieca
Posts: 2
Joined: 2006-07-16 09:18

removing user from console

#1 Post by nieca »

hi there from Poland!

Code: Select all

$ who
krystian pts/0        Jul 16 11:07 (ffp58.internetdsl.tpnet.pl)
krystian pts/0        Jul 13 15:32
now to remove this inactive 2-nd user "krystian" ?

I have tried many ways with skill, slay but without effect?

only to restart my server will help?

cheers!

GN

Grifter
Posts: 1554
Joined: 2006-05-04 07:53
Location: Svea Rike

#2 Post by Grifter »

one way is to type who (or just w) and look at what pts or pty he's connecting from, and kill the first (parent) process with that pts/pty, slay is easier, it should work beautifully, see if there are some options to slay equalling kill -9, i think there should be
Eagles may soar, but weasels don't get sucked into jet engines...

nieca
Posts: 2
Joined: 2006-07-16 09:18

#3 Post by nieca »

as You can see there is no connecting place...

in a matter of fact there is the same user (in fact me - owner of the server)
killing pts0 gives nothing, killing user (skill -KILL -9 -u krystian without effect)

I don't wanna restart my server to correct this problem...

User avatar
Red
Posts: 69
Joined: 2006-04-20 12:36

#4 Post by Red »

Hi,
try with ps aux | grep krystian and kill his PID

Grifter
Posts: 1554
Joined: 2006-05-04 07:53
Location: Svea Rike

#5 Post by Grifter »

you don't kill pts/0 you kill the first process (ie bash or sshd or something) that's listed as being connected to pts/0, or whichever pts or pty the user is using
Eagles may soar, but weasels don't get sucked into jet engines...

User avatar
Red
Posts: 69
Joined: 2006-04-20 12:36

#6 Post by Red »

i want to remove user spasen

[root@aku spasen]# ps aux | grep sshd
root 3580 0.0 0.3 5568 1692 ? Ss 15:29 0:00 /usr/sbin/sshd
root 4857 0.0 0.5 7512 2632 ? Ss 16:50 0:00 sshd: spasen [priv]
spasen 4893 0.1 0.5 7512 2712 ? S 16:51 0:00 sshd: spasen@pts/2
root 4996 0.0 0.1 3668 664 pts/2 S+ 16:53 0:00 grep sshd
[root@aku spasen]#kill 4893

User avatar
Red
Posts: 69
Joined: 2006-04-20 12:36

#7 Post by Red »

Code: Select all

debian:~# who
red      :0           2006-07-26 01:07
red      pts/0        2006-07-26 02:08 (:0.0)
red      pts/1        2006-07-26 02:10 (:0.0)
red      pts/3        2006-07-26 02:20 (:0.0)
ninja    pts/4        2006-07-26 02:23 (pppoe-92.techno-link.com)
debian:~# ps aux | grep sshd
root      4842  0.0  0.2   4932  1072 ?        Ss   02:23   0:00 /usr/sbin/sshd
root      4844  0.0  0.4   7704  2316 ?        Ss   02:23   0:00 sshd: ninja [priv]
ninja     4846  0.0  0.3   7704  1568 ?        S    02:23   0:00 sshd: ninja@pts/4
root      4879  0.0  0.1   2148   620 pts/0    S+   02:25   0:00 grep sshd
debian:~# kill 4846
debian:~# who
red      :0           2006-07-26 01:07
red      pts/0        2006-07-26 02:08 (:0.0)
red      pts/1        2006-07-26 02:10 (:0.0)
red      pts/3        2006-07-26 02:20 (:0.0)
debian:~#
:twisted:

Post Reply