My X login manager (slim) has brought with it a dependency on a package consolekit I don't know what consolekit is good for, other login managers such as wdm do not need it.

But anyway, the problem I am having is that consolekit is logging lots of garbage in /var/log/ConsoleKit/history. I am not interested in those logs. Is it possible to disable logging?

I have tried removing the log file and creating a symlink to /dev/null

ln -s /dev/null /var/log/ConsoleKit/history

But that does not work, because consolekit now complains that there are too many levels of symbolic links.


ConsoleKit doesn't accept symbolic links for the log file as you mentioned in your question.

But you can trick consolekit a bit, when you create a null device instead of a normal log file. First remove the history file:

rm /var/log/ConsoleKit/history 

And then use this command:

mknod /var/log/ConsoleKit/history c 1 3

That creates a null device (c: character special, 1: major number and 3 minor number).

Now, everthing that is logged in this file is deleted and needs no space on the filesystem.

| improve this answer | |
  • so basically, this will create a second /dev/null file, named /var/log/ConsoleKit/history ? I have /var partition mounted with nodev option, will this still work? – Martin Vegter Jul 18 '14 at 16:45
  • @MartinVegter This will end in a Permissin denied when writing to this device. But, there is stil another option: a bind mount. Before creating the null device, run this command: mount --bind $(mktemp -d) /var/log/ConsoleKit/. Then create the device as in my answer. You can test with echo "blah" >/var/log/ConsoleKit/history which should not fail in a permissin error. – chaos Jul 18 '14 at 17:03

From FreeDesktop.Org

ConsoleKit is a framework for defining and tracking users, login sessions, and seats.

Also note:

ConsoleKit is currently not actively maintained. The focus has shifted to the built-in seat/user/session management of Software/systemd called systemd-logind!


No longer maintained but available here

To disable it, see:
console-kit-daemon Hogging CPU and RAM or
Gentoo Wiki: Consolekit

| improve this answer | |

Make the log file immutable as root.

sudo echo "" > /var/log/ConsoleKit/history/<log_filename>
sudo chattr +i /var/log/ConsoleKit/history/<log_filename>
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.