Bug 98170

Summary: apmscript does not detect running X servers for locking
Product: [Retired] Red Hat Linux Reporter: Ronny Bremer <rbremer>
Component: apmdAssignee: Bill Nottingham <notting>
Status: CLOSED WONTFIX QA Contact: Jay Turner <jturner>
Severity: medium Docs Contact:
Priority: medium    
Version: 9CC: rvokal, srevivo
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-02-02 22:54:08 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Ronny Bremer 2003-06-27 12:21:25 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225

Description of problem:
in line 151 of the apmscript you try to get a list of logged in users to X
sessions, and you grep for lines NOT containing "-".
If I do a "w" on my laptop, I am logged into X but my line does show "-" as the
remote computer, so it will not be detected by the apmscript, hence X is not
going to be locked.

I assume, that you expect ":0" as the remote computer in the "w" output, but it
aint there.

Any ideas?

Ronny

Version-Release number of selected component (if applicable):
apmd-3.0.2-19

How reproducible:
Always

Steps to Reproduce:
1. login to an X session
2. type "w" in a terminal
3. read the output, the user logged into X does show up like this:
     14:11:30  up  2:58,  3 users,  load average: 0.13, 0.27, 0.18
USER     TTY      FROM              LOGIN@   IDLE   JCPU   PCPU  WHAT
root     tty2     -                 1:34pm 17:28   0.13s  0.13s  -bash
rbremer  pts/0    -                 1:54pm 17:10   0.00s  0.28s  kdeinit: kwrite
rbremer  pts/2    -                 1:55pm  0.00s  0.18s  0.04s  /bin/bash

in my case "rbremer pts/0 -"


Actual Results:  X does not get locked as expected

Expected Results:  I expected the apmscript to fire off an dcop event, which
works when conducted manually, but not in the script.

Additional info:

running kdm as the greeter application and logging into a KDE session

Comment 1 Bill Nottingham 2005-02-02 22:54:08 UTC
Closing out bugs on older unsupported releases. Apologies for any lack
of response. Please reopen if it persists on current releases such as
Fedora Core 3.