Bug 25048 - messed up utmp entry
messed up utmp entry
Product: Red Hat Linux
Classification: Retired
Component: kdebase (Show other bugs)
i386 Linux
high Severity medium
: ---
: ---
Assigned To: Bernhard Rosenkraenzer
Aaron Brown
Florence RC-1
: Security
Depends On:
  Show dependency treegraph
Reported: 2001-01-26 17:09 EST by Tim Waugh
Modified: 2007-03-26 23:39 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-02-04 07:06:47 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Tim Waugh 2001-01-26 17:09:27 EST
Here's a fun one to try.

Create a new user.  Log in as that user via kdm.  Log out.  'finger'.

Here's what I get, for two users I made up:

Login   Name    Tty    Idle
fred          *pts/0    25d
jim           *pts/0    25d

Does anyone else get this?
Comment 1 Tim Waugh 2001-01-29 13:53:29 EST
Actually, it doesn't seem to happen from kdm, only with startx.
Comment 2 Glen Foster 2001-01-29 19:01:50 EST
This defect is considered MUST-FIX for Florence Release-Candidate #1
Comment 3 Tim Waugh 2001-01-30 06:43:48 EST
Okay, the smoking gun is here, in kdebase/konsole/src/kwrited.C:57:

  //FIXME: make sure we properly remove the utmp stamp on session end or kill

Comment 4 Tim Waugh 2001-01-30 06:58:49 EST
kwrited is getting killed by SIGHUP as soon as I log out.

Comment 5 Tim Waugh 2001-01-30 12:51:13 EST
*** Bug 25232 has been marked as a duplicate of this bug. ***
Comment 6 Tim Waugh 2001-01-30 13:23:38 EST
I can't figure this out.  After logging in, kwrited has a child, cat.  kwrited
is in the same process group and session as all the other kdeinit:* processes,
and cat is in its own process group, and its own session.  Only cat has a
controlling terminal.  Yet they _both_ get a SIGHUP, when I can only see one
being sent.  Am I looking in the wrong place?

Also, althought TEPty::TEPty does:

  connect(this, SIGNAL(processExited(KProcess *)),
          this, SLOT(donePty()));

donePty never gets called. :-(
Comment 7 Tim Waugh 2001-02-02 13:52:24 EST
I've reported this in the KDE bug database.
Comment 8 Tim Waugh 2001-02-04 07:06:43 EST
Stephan Kulow's patch does not fix the problem.  For reference, this is KDE bug
Comment 9 Bernhard Rosenkraenzer 2001-02-04 14:03:12 EST
Fixed in 2.0.20010204-1
Comment 10 Tim Waugh 2001-02-04 14:07:29 EST
Bero, are you sure?  The patch you sent me didn't work entirely.
Comment 11 Bernhard Rosenkraenzer 2001-02-04 14:11:15 EST
I've built a new one that works for me so far.
Seems some **** thought we don't need to chownpty() if we have a /dev/ptmx
device for some reason, commenting out that line fixes it (for me).

Besides the patch I've sent you earlier fixes the utmp issue which is the worse
part (and reasoning for the RC-1-MUSTFIX state ;) ) of the problem.

If the other problem remains for you, please open a new bug rather than
reopening this one.
Comment 12 Tim Waugh 2001-02-04 14:15:14 EST
I thought the worse part was the device permissions one (#25232).  I'll reopen
it, since it seems to be a separate (kdm) thing.

Note You need to log in before you can comment on or make changes to this bug.