View previous topic :: View next topic |
Author |
Message |
Chris W l33t
Joined: 25 Jun 2002 Posts: 972 Location: Brisbane, Australia
|
Posted: Mon Jul 13, 2009 5:27 am Post subject: ConsoleKit: Is it needed/useful? |
|
|
I've been playing around building a new MythTv box and noticed errors regarding ConsolelKit in the Xorg.0.log file. The consolekit package is installed (pulled in as a dep for xinit with hal USE flag) but it has a daemon that is not running and nothing else on the system is built with USE=consolekit. Things seem to work anyway.
So, questions are:
What is consolekit good for?
Should the daemon be started in boot or default level, or not at all? _________________ Cheers,
Chris W
"Common sense: The collection of prejudices acquired by age 18." -- Einstein |
|
Back to top |
|
|
Chris W l33t
Joined: 25 Jun 2002 Posts: 972 Location: Brisbane, Australia
|
Posted: Wed Jul 15, 2009 2:35 am Post subject: |
|
|
Seems to be more of a mystery than I thought _________________ Cheers,
Chris W
"Common sense: The collection of prejudices acquired by age 18." -- Einstein |
|
Back to top |
|
|
alatar n00b
Joined: 12 Feb 2009 Posts: 61
|
Posted: Wed Jul 15, 2009 3:05 am Post subject: |
|
|
AFAIK it is used to log some users activity or deal with privileges. If you look at the list of the processes, the number of consolekits would be equal to the number of tty's. That is all that I know about it |
|
Back to top |
|
|
dreadlorde Apprentice
Joined: 16 Dec 2008 Posts: 243 Location: /adm/timezone/US_Michigan
|
Posted: Wed Jul 15, 2009 4:53 am Post subject: |
|
|
alatar wrote: | AFAIK it is used to log some users activity or deal with privileges. If you look at the list of the processes, the number of consolekits would be equal to the number of tty's. That is all that I know about it |
I have two tty's, one consolekit, and about ~30 threads of it.
_________________ Ludwig von Mises Institute Quote: | I am not to be a shepherd, I am not to be a grave-digger. No longer will I speak to the people; for the last time I have spoken to the dead. |
|
|
Back to top |
|
|
pigeon768 l33t
Joined: 02 Jan 2006 Posts: 683
|
Posted: Thu Jul 16, 2009 2:13 pm Post subject: |
|
|
I'm not sure. I know hal & dbus have been all fucked up on all my computers for the last few weeks - I tried uninstalling them, removing all related files, including everything in /etc, /var/lib, /var/run, /var/cache, anything I could find, reinstalling them, twice. Eventually, on a wild-ass-guess, (/var/log/messages showed complaints regarding console-kit-daemon, which I hadn't explicitly installed, USE flags were turned off, and wasn't added to the default runlevel, but was still running in the background for some inexplicable reason) I enabled the policykit and consolekit USE flags, 'emerge -uND @world' and everything started working again - hotplugging USB devices, battery control on my laptop, etc. |
|
Back to top |
|
|
energyman76b Advocate
Joined: 26 Mar 2003 Posts: 2048 Location: Germany
|
Posted: Sun Jul 19, 2009 2:08 am Post subject: |
|
|
yeah, some time ago I suddenly had problems with 3d not working, failing permissions and stuff - consolekit added to default and everything worked again. Not too happy about it, but it does not hurt either... _________________ Study finds stunning lack of racial, gender, and economic diversity among middle-class white males
I identify as a dirty penismensch. |
|
Back to top |
|
|
Yamakuzure Advocate
Joined: 21 Jun 2006 Posts: 2284 Location: Adendorf, Germany
|
Posted: Mon Jul 20, 2009 10:26 am Post subject: |
|
|
... something everybody needs, but nobody knows what it does... "ConsoleKit by Microsoft", install today or suffer the consequences? I think that's really odd ... and somewhat suspicious! (Yay! Feed the conspiracy theorists! *harhar*)
Edith wants to add: ConsoleKit Documentation wrote: | About
ConsoleKit is a framework for keeping track of the various users, sessions, and seats present on a system. It provides a mechanism for software to react to changes of any of these items or of any of the metadata associated with them. |
_________________ Important German:- "Aha" - German reaction to pretend that you are really interested while giving no f*ck.
- "Tja" - German reaction to the apocalypse, nuclear war, an alien invasion or no bread in the house.
|
|
Back to top |
|
|
d2_racing Bodhisattva
Joined: 25 Apr 2005 Posts: 13047 Location: Ste-Foy,Canada
|
Posted: Mon Jul 20, 2009 11:51 am Post subject: |
|
|
For what I know, consolekit use flag is necessary for a pam package inside kde 4.x at least. |
|
Back to top |
|
|
alatar n00b
Joined: 12 Feb 2009 Posts: 61
|
Posted: Tue Jul 21, 2009 1:08 am Post subject: |
|
|
Well, I do not have KDE installed, but as I remember ConsoleKit was running even without X. So possibly it is the dependensy of pam. |
|
Back to top |
|
|
DaggyStyle Watchman
Joined: 22 Mar 2006 Posts: 5909
|
Posted: Tue Jul 21, 2009 7:46 am Post subject: |
|
|
so enabling global support in it is a good thing? it will be a good thing? _________________ Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein |
|
Back to top |
|
|
d2_racing Bodhisattva
Joined: 25 Apr 2005 Posts: 13047 Location: Ste-Foy,Canada
|
Posted: Tue Jul 21, 2009 11:56 am Post subject: |
|
|
I think so, because I'm trying to install KDE 4.2.4 and it's asking to have consolekit as a Use Flags for pam and 2-3 other packages. |
|
Back to top |
|
|
DaggyStyle Watchman
Joined: 22 Mar 2006 Posts: 5909
|
Posted: Tue Jul 21, 2009 1:29 pm Post subject: |
|
|
ok, will add and try. _________________ Only two things are infinite, the universe and human stupidity and I'm not sure about the former - Albert Einstein |
|
Back to top |
|
|
Zarhan l33t
Joined: 27 Feb 2004 Posts: 996
|
Posted: Wed Sep 30, 2009 11:54 am Post subject: What is consolekit? |
|
|
I have recently noticed USE-flag "consolekit" creep into my emerge -uvDaN world. Also,when I upgraded one of my comps to KDE 4, consolekit was pulled in. What does that thing do and why do I need it? Why should I enable it at startup?
http://www.freedesktop.org/software/ConsoleKit/ tells it's a framework for tracking users, but that tells me pretty much squat. What does it actually DO? |
|
Back to top |
|
|
depontius Advocate
Joined: 05 May 2004 Posts: 3509
|
Posted: Wed Sep 30, 2009 1:12 pm Post subject: |
|
|
I'll take a stab at this...
The console brings with it some extra resources, like the cdrom, sound, keyboard, display card, etc. Someone getting in through ssh needs none of these things, and shouldn't be allowed to access them. But whoever is sitting at the console does. There have been numerous stabs at giving the console user the extra authority to use these devices - RedHat used to have some sort of console-tools that was a pam add-on, HAL policies another, and ConsoleKit is the latest'n'greatest.
That's my impression. If someone sees this, and I'm wrong, please correct me. _________________ .sigs waste space and bandwidth |
|
Back to top |
|
|
Mike Hunt Watchman
Joined: 19 Jul 2009 Posts: 5287
|
Posted: Wed Sep 30, 2009 1:55 pm Post subject: |
|
|
I read that it is recommended for KDE4, and Gnome has consolekit support built in. I also read that it solves many weird problems. Hal, KDM and gnome-volume-manager use consolekit.
Announcing ConsoleKit wrote: | The way it works, currently, is that after the login manager (KDM,
GDM, etc) authenticates a new user it tells ConsoleKit to open a new
session. CK then generates a globally unique secret cookie and
returns that to the login manager. The login manager stores that
cookie in the environment of the new login process as
XDG_SESSION_COOKIE (GDM 2.17.2 or greater already does this). So,
membership in this session is defined as knowledge of this cookie.
This aspect can be considered a replacement for utmp and things like
pam_console. |
It needed to be patched to work properly in KDE4 look here |
|
Back to top |
|
|
i92guboj Bodhisattva
Joined: 30 Nov 2004 Posts: 10315 Location: Córdoba (Spain)
|
|
Back to top |
|
|
Mike Hunt Watchman
Joined: 19 Jul 2009 Posts: 5287
|
Posted: Wed Sep 30, 2009 7:36 pm Post subject: |
|
|
yes, that makes it much easier to get a clearer picture - bookmarking it - for next time someone asks. Thanks |
|
Back to top |
|
|
desultory Bodhisattva
Joined: 04 Nov 2005 Posts: 9410
|
Posted: Sat Oct 03, 2009 1:24 am Post subject: |
|
|
Merged the preceding five posts. |
|
Back to top |
|
|
Decibels Veteran
Joined: 16 Aug 2002 Posts: 1623 Location: U.S.A.
|
Posted: Tue Oct 06, 2009 12:45 am Post subject: |
|
|
I just ran into a problem with consolekit wanting to install pam if you used emerge -uDN and not if you used -u. Had -pam in make.conf and even putting consolekit -pam in package.use didn't help. I normally don't use the -uDN, but was notified of the problem from some family members. After some checking I realized that could use the above to get around it. But further investigation revealed that I have never used consolekit. I have had pam removed for quite a few years and didn't want it installed. So if it rears it's ugly head again will see if can just unmerge consolekit.
Later: Since never used consolekit after all these years, added -consolekit to my make.conf and that has solved the problem. _________________ Support bacteria – they’re the only culture some people have.”
– Steven Wright
Last edited by Decibels on Tue Oct 13, 2009 3:03 am; edited 1 time in total |
|
Back to top |
|
|
chris.c.hogan Apprentice
Joined: 02 Oct 2005 Posts: 189
|
Posted: Thu Oct 08, 2009 10:07 am Post subject: |
|
|
I just ran into Console Kit while putting together a new system for a netbook. It showed up as a USE flag for KDM and defaulted to on using the default/linux/x86/2008.0/desktop profile. I was given the following warning:
Quote: |
* You have compiled 'kdm' with consolekit support. If you want to use kdm,
* make sure consolekit daemon is running and started at login time
*
* rc-update add consolekit default && /etc/init.d/consolekit start |
Just what I want on a netbook, yet another service stealing resources. Though, I suppose, if I were really worried about resources, I wouldn't be trying KDE out on it...
I read a little about consolekit when it came out. It is a replacement for pam_console. Redhat, SuSE, and I'm sure others, used to use pam_console to set device permissions exclusively to the user. Their approach differed from mine. I prefer to use groups to control access to devices. pam_console never really made sense to me, and I disabled it anywhere I could. In the past, Gentoo seemed to agree with my method of device access control, with the video, audio, cdrom, plugdev, and other hardware access groups. I really hope this is not changing.
The netbook will be primarily a single-user system. I've even debated not installing KDM and letting mingetty/inittab/.bash_profile/startx handle log-in. It is the setup I used for Myth. Console Kit is a complete waste on this system. I think I'll see how far I can can get with disabling it in the make.conf file. I'll report any success/failures here.
Edit:
Consolekit is not enabled by the profile. kde-base/kdm-4.3.1-r2 and x11-apps/xinit-1.0.8-r8 turn it on. I've forced it off via make.conf and removed it via emerge -C. I don't see anything pulling it in when I do emerge -pve world. This is a build environment. I'll report if I have any problems building, or running once I transfer the system to the netbook...
Last edited by chris.c.hogan on Thu Oct 08, 2009 10:52 am; edited 1 time in total |
|
Back to top |
|
|
energyman76b Advocate
Joined: 26 Mar 2003 Posts: 2048 Location: Germany
|
Posted: Thu Oct 08, 2009 10:11 am Post subject: |
|
|
so, you let the useflag on and then you complain that it does what it advertised? Sounds stupid.
and ressources?
root 3483 0.0 0.0 100472 2344 ? Ssl Oct07 0:00 /usr/sbin/console-kit-daemon
yeah, horrible. _________________ Study finds stunning lack of racial, gender, and economic diversity among middle-class white males
I identify as a dirty penismensch. |
|
Back to top |
|
|
remi2402 Retired Dev
Joined: 28 Jun 2003 Posts: 111 Location: Paris, France
|
Posted: Thu Oct 08, 2009 3:24 pm Post subject: |
|
|
Of all the controversies surrounding the various *Kits (PackageKit, DeviceKit, ConsoleKit, ...) ConsoleKit is the one that's actually good to have.
It's just a small daemon that sits in the background and does nearly nothing. In a nutshell, it just waits for user sessions to register themselves to the daemon. Then, other tools can ask the daemon to list all the currently running sessions on a system and query their types (X session, remote X, local console, remote console via ssh, serial, whatever).
ConsoleKit is now also used to properly replace pam_console which was just a big steaming pile of s***.
Now, the reason why it spawns 30 threads is because the kernel API for watching ttys (virtual terminals if you will) is a blocking API. So, ConsoleKit has no other choice but to spawn 1 thread for each tty on your system. Almost all of them will be asleep, so this really isn't an issue
So, yes, USE="consolekit" globally is a very good idea. |
|
Back to top |
|
|
Decibels Veteran
Joined: 16 Aug 2002 Posts: 1623 Location: U.S.A.
|
Posted: Thu Oct 08, 2009 9:24 pm Post subject: |
|
|
consolekit also wants pam installed, which is aggrevating on a single user system that I have already removed pam years ago. The other day it wanted me to reinstall pam again cause gnumeric wanted consolekit, which wanted pam. I got it remerged, but had to use -consolekit. Doing the same with -pam didn't work and had to play around with it to not install pam, when it wanted to upgrade consolekit. Seems like it is trying to defeat my use of USE Flags. _________________ Support bacteria – they’re the only culture some people have.”
– Steven Wright |
|
Back to top |
|
|
dmpogo Advocate
Joined: 02 Sep 2004 Posts: 3267 Location: Canada
|
Posted: Thu Oct 08, 2009 9:31 pm Post subject: |
|
|
remi2402 wrote: |
It's just a small daemon that sits in the background and does nearly nothing. In a nutshell, it just waits for user sessions to register themselves to the daemon. Then, other tools can ask the daemon to list all the currently running sessions on a system and query their types (X session, remote X, local console, remote console via ssh, serial, whatever).
|
And what are the scenarios when other tools do need that info ? (I am not being sarcastic, just want to judge if any of them are applicable to my setup) |
|
Back to top |
|
|
Zarhan l33t
Joined: 27 Feb 2004 Posts: 996
|
Posted: Thu Oct 08, 2009 9:41 pm Post subject: |
|
|
Where are the policies on which type of session gets access to what?
For example, someone said that SSH user wouldn't need e.g. access to CD-ROM. I disagree - I happen to have a small laptop that doesn't have a optical disc drive, but my desktop computer has. So if I want to use the DVD drive on the desktop that is sitting right next to the laptop via SSH (using e.g. scp), I bloody well need that access.
I hope it's not in a bunch of XML files like some of the recent stuff Freedesktop.org has been touting... |
|
Back to top |
|
|
|