Inaktive Benutzerlogins killen

FreeBSD, Gentoo, openSUSE, CentOS, Ubuntu, Debian
joggl@monacocity
Posts: 13
Joined: 2005-08-30 14:12
Location: Monaco City
 

Inaktive Benutzerlogins killen

Post by joggl@monacocity »

Hatte ein Problem mit Putty.
nach ein paar minuten nichts tun bekam ich immer nen timeout.
hab ich jetz per keepalive behoben!

wenn ich jetzt mal users eingebe sehe ich root 5 x angemeldet!
Das sind wohl noch reste von den alten sessions.

Wie kann ich die loswerden ohne die kiste neu zu starten?

gruß
flo
Posts: 2223
Joined: 2002-07-28 13:02
Location: Berlin
 

Re: Inaktive Benutzerlogins killen

Post by flo »

Code: Select all

# ps axu | grep pts
root     14043  0.6  1.3   6372  2064 ?        Ss   12:53   0:00 sshd: root@pts/0
root     14047  0.5  1.1   4612  1820 pts/0    Ss   12:53   0:00 -bash
root     14113  0.0  0.5   4252   944 pts/0    R+   12:53   0:00 ps axu
root     14114  0.0  0.4   3304   744 pts/0    S+   12:53   0:00 grep pts
pts sind die ssh-Konsolen - hier kannst Du dann den sshd killen (pid 14043), ohne den Daemonen an sich auszuradieren.

flo.
joggl@monacocity
Posts: 13
Joined: 2005-08-30 14:12
Location: Monaco City
 

Re: Inaktive Benutzerlogins killen

Post by joggl@monacocity »

flo wrote: pts sind die ssh-Konsolen - hier kannst Du dann den sshd killen (pid 14043), ohne den Daemonen an sich auszuradieren.
flo.
ssh - Konsolen Prozesse sind schon alle weg!
wenn ich aber users eingebe seh ich noch 5 x root -> und genau die will ich loswerden
joggl@monacocity
Posts: 13
Joined: 2005-08-30 14:12
Location: Monaco City
 

Re: Inaktive Benutzerlogins killen

Post by joggl@monacocity »

Code: Select all

ps axu | grep pts
root     30811  0.0  0.8  7808 2168 ?        Ss   11:20   0:00 sshd: root@pts/0 
root     30815  0.0  0.6  2664 1648 pts/0    Ss   11:20   0:00 -bash
root      5810  0.0  0.2  2164  692 pts/0    R+   12:57   0:00 ps axu
root      5811  0.0  0.2  1640  552 pts/0    R+   12:57   0:00 grep pts

Code: Select all

users
root root root root root
captaincrunch
Userprojekt
Userprojekt
Posts: 7066
Joined: 2002-10-09 14:30
Location: Dorsten
 

Re: Inaktive Benutzerlogins killen

Post by captaincrunch »

Du solltest auch besser w oder who benutzen.
DebianHowTo
echo "[q]sa[ln0=aln256%Pln256/snlbx]sb729901041524823122snlbxq"|dc
joggl@monacocity
Posts: 13
Joined: 2005-08-30 14:12
Location: Monaco City
 

Re: Inaktive Benutzerlogins killen

Post by joggl@monacocity »

CaptainCrunch wrote:Du solltest auch besser w oder who benutzen.

Code: Select all

who
root     pts/0        Sep  1 11:20 (pxxxxxxx.dip0.t-ipconnect.de)
root     pts/1        Sep  1 08:40 (pxxxxxxx.dip0.t-ipconnect.de)
root     pts/2        Sep  1 09:34 (pxxxxxxx.dip0.t-ipconnect.de)
root     pts/3        Sep  1 10:00 (pxxxxxxx.dip0.t-ipconnect.de)
root     pts/4        Sep  1 10:20 (support1.rootcrew-zw.de)
captaincrunch
Userprojekt
Userprojekt
Posts: 7066
Joined: 2002-10-09 14:30
Location: Dorsten
 

Re: Inaktive Benutzerlogins killen

Post by captaincrunch »

root pts/4 Sep 1 10:20 (support1.rootcrew-zw.de)
Bist du das etwa?
DebianHowTo
echo "[q]sa[ln0=aln256%Pln256/snlbx]sb729901041524823122snlbxq"|dc
joggl@monacocity
Posts: 13
Joined: 2005-08-30 14:12
Location: Monaco City
 

Re: Inaktive Benutzerlogins killen

Post by joggl@monacocity »

CaptainCrunch wrote:
root pts/4 Sep 1 10:20 (support1.rootcrew-zw.de)
Bist du das etwa?
dann wäre ich ja vom 1und1 support! das wäre schon zum lachen :-D

nein das war der support! ich bin das nicht
lord_pinhead
Posts: 774
Joined: 2004-04-26 15:57
 

Re: Inaktive Benutzerlogins killen

Post by lord_pinhead »

Sind die SSH Shells bei ps -axf mit aufgelistet? Eigentlich müsste das Timeout die Sessions automatisch beenden, was hast du an der SSH abgeändert?
joggl@monacocity
Posts: 13
Joined: 2005-08-30 14:12
Location: Monaco City
 

Re: Inaktive Benutzerlogins killen

Post by joggl@monacocity »

Lord_Pinhead wrote:Sind die SSH Shells bei ps -axf mit aufgelistet? Eigentlich müsste das Timeout die Sessions automatisch beenden, was hast du an der SSH abgeändert?
An der SSH hab ich gar nichts geändert.
ich denk diese remote sessions sind ja auch weg!
nur die user sind noch angemeldet.
User avatar
Joe User
Project Manager
Project Manager
Posts: 11186
Joined: 2003-02-27 01:00
Location: Hamburg
 

Re: Inaktive Benutzerlogins killen

Post by Joe User »

PayPal.Me/JoeUserFreeBSD Remote Installation
Wings for LifeWings for Life World Run

„If there’s more than one possible outcome of a job or task, and one
of those outcomes will result in disaster or an undesirable consequence,
then somebody will do it that way.“ -- Edward Aloysius Murphy Jr.