[Tfug] How to detect graphical logins?
Jeff Breadner
jeff at breadner.net
Wed Jun 4 15:16:21 MST 2008
Hi everyone
Does anyone know of a program/script fragment that one can use to
detect how many users (and which users) are logged in to graphical
sessions on a Linux box (RHEL3 ideally)? Tools like "who -a", "w" and
"users" all show console / shell sessions, for detecting VNC sessions
I've had to resort to "ps auxw | grep xconsole | grep -v grep | awk
'{print $1}'", which I'm not too happy with.
I don't mind having to install a new utility if there's a good one out
there that will report what I'm after. Does anyone know of such a
thing? Bonus points if it also works with Solaris 7.
thanks
JB
More information about the tfug
mailing list