Solved

xdm and sessreg

Posted on 1998-06-28
3
435 Views
Last Modified: 2010-05-18
I am trying to determin who is connected via an X Terminal
I have added lines into Xstartup and Xreset to use sessreg
to add an entry into utmp and wtmp. Last finds the entrys
by w or who do not. I need w or who to report the entrys.
my sessreg line is:
sessreg -a -l $DISPLAY -x /usr/bin/X11/lib/xdm/Xservers $USER
0
Comment
Question by:dksayers
3 Comments
 

Expert Comment

by:ury_segal
ID: 2008308
last uses /var/adm/wtmpx, and w and who looks in /var/adm/utmp.
That's on solaris. Try to tell sessreg ( I don't have it ) to update utmp.
0
 

Accepted Solution

by:
vkurland earned 150 total points
ID: 2008309
As ury_segal has said, "w" and "who" use utmp file. Usually sessreg expects utmp to be in /etc/ on SysV systems, but it could be in different place on yours. Check /var/run or /var/log for example. Try to use command line switch "-u utmp-file" to specify utmp file location on your system.

Actually it would be easier to answer if you'd tell us what kind of system you are on


0
 

Author Comment

by:dksayers
ID: 2008310
It seems the problem is to do with running the sessreg. I found
that under my Linux system sessreg needs to be run as the same
process (using exec) because sessreg would get the PPID of
the Xstartup which terminates on completion. exec'ing sessreg
gets the PPID of the Xserver itself....
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. jgh@FreeBSD.org Please see http://www.freebsd.org/doc/en_US.ISO8859-1/articles/freebsd-update-server/ for the updated article. It is avail…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question