Comment 11 for bug 284229

Revision history for this message
Jeffrey Baker (jwbaker) wrote :

The way I read it, sessions are being leaked into console-kit-daemon, and every time a session is added or removed console-kit-daemon does something that's either O(N) or O(N^2) or worse. I'm up to Session #31399 and every time a session is added or removed, c-k-d eats another 4 or 5 CPU seconds (100% utilization for several seconds). This would also account for c-k-d's ever-increasing memory size.

From what I can tell, the extra sessions are due to cron. I have some cron jobs that fire every minute, so they are creating and destroying sessions pretty frequently.

Which means that I'm leaking a session every minute. The superlinear big-O explains why c-k-d is taking an increasingly large fraction of CPU time as the system stays up longer. It was 4.1% yesterday and it's up to 4.8% now. It takes me 2-3 seconds to sudo because c-k-d is spending so long with its head up its ass.

I suspect that this would hit anyone with minutely cron jobs.