This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 366981 - ConsoleKit tries to find the console using keyboard ioctls that don't always work
ConsoleKit tries to find the console using keyboard ioctls that don't always ...
Status: CLOSED DUPLICATE of bug 359361
Product: Fedora
Classification: Fedora
Component: ConsoleKit (Show other bugs)
All Linux
low Severity low
: ---
: ---
Assigned To: David Zeuthen
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2007-11-05 11:13 EST by Peter Jones
Modified: 2013-03-05 22:53 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2008-03-18 11:31:41 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:

Attachments (Terms of Use)
patch to use VT_ETSTATE and tty0 (1.32 KB, patch)
2007-11-05 11:13 EST, Peter Jones
no flags Details | Diff

  None (edit)
Description Peter Jones 2007-11-05 11:13:35 EST
Description of problem:  ConsoleKit tries to find a valid fd it can issue
VT_WAITACTIVE against by iterating across a file list and issuing 
ioctl(fd, KDGKBTYPE, &arg), then checking the return value.  Not all console
devices support this ioctl, so in some cases it never finds a valid file
descriptor to use, and from then on never marks any session active.

We probably ought to be using something like VT_GETSTATE instead of a keyboard
ioctl, but that's not sufficient to fix it.  One fix that seems to work, though
I'm not completely sure if it's the best answer, is to add /dev/tty0 to the list
of files to try before /dev/console.

I've attached a patch that seems to resolve the issue for me.
Comment 1 Peter Jones 2007-11-05 11:13:35 EST
Created attachment 248391 [details]
patch to use VT_ETSTATE and tty0
Comment 2 Lubomir Kundrak 2008-03-18 11:31:41 EDT

*** This bug has been marked as a duplicate of 359361 ***

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