wtmp entry bug? ghost entry line...



hi,

i just wanted to know if this is a bug or just an other feauture since
the other display managers (xdm, kdm) handles it correcly in my opinion
(but that doesn't mean that it's also correct). anyway...

if i login to X with gdm, gdm creates an entry like the following to
/var/log/wtmp (which is a must have on linux systems and for the other
it depends). the line has been taken from last:

m96      :0             Mon Mar 25 01:41    gone - no logout

ps: i get the pid of the process with a small self written utility which
is in that case 650.

it prints 'gone - no logout' because the pid of the process that had
written the entry does no longer exist. so last (procps package) thinks
this is a ghost entry.

like i told the other display managers handles it correctly in that way
that the pid of the process that writes to wtmp still exists so that
last prints something like:

m96      :0             Fri Mar 22 16:12   still logged in

the pstree entry looks like if i log in from gdm:

|-gdm(643)---gdm(644)-+-XFree86(645)
        |                     `-gnome-session(652)---ssh-agent(682)


so you can see that the process 650 that writes the wtmp entry has been
spawned between XFree86 and gnome-session. and no longer exist.

the other managers writes the entry from the (second) spawned display
manager. that would be in this case 644 so that can you verify that the
user is still logged in and the entry in wtmp is not just a ghost...


i'm sorry that this message gone a little bit to long but i hope you can
understand what i mean.

i know that this is just a peanut for almost every user but i need the
this to 100% verify if the user is logged in to the system or not. i
need this verification in connection with user home dir mounting.

thanks a lot in advance for any help,
best regards,
m96.







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