Bug 253606 - knotify4 and "kdeinit: kded4" each consume close to 100% CPU after KDE startup until they are killed
Summary: knotify4 and "kdeinit: kded4" each consume close to 100% CPU after KDE startu...
Status: RESOLVED DUPLICATE of bug 220047
Alias: None
Product: kdelibs
Classification: Frameworks and Libraries
Component: kded (show other bugs)
Version: SVN
Platform: Mandriva RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: David Faure
URL:
Keywords:
: 254902 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-10-08 18:26 UTC by Shlomi Fish
Modified: 2011-05-17 01:38 UTC (History)
11 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
view of htop output (45.53 KB, image/png)
2011-03-13 21:07 UTC, Kevin Coonan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Shlomi Fish 2010-10-08 18:26:48 UTC
Version:           SVN (using Devel) 
OS:                Linux

After I started KDE on Mandriva Linux Cooker, I'm getting this output on ps:

[quote]
USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
shlomif   3867 77.6  0.8 136752 21500 ?        Sl   11:08 212:31 kdeinit4: kded4 [kdeinit]  
shlomif   3953 77.9  1.0 150812 26172 ?        Sl   11:10 212:24 /usr/bin/knotify4
[/quote]

Apparently, they each consume as much CPU as they can with no end in sight, until I kill them using SIGTERM or SIGKILL, when they die and nothing appears to happen. Before they are killed, they make the rest of the processes not responsive.

I'm on Mandriva Linux Cooker using kdelibs4-4.5.71-0.svn1183355.1mdv2011.0.src.rpm and kdebase4-4.5.68-1mdv2011.0.src.rpm running on an x86-32 on a P4-2.4GHz machine with an ATI Radeon HD 2600 Pro card , no KMS, and apparently no 3-d acceleration enabled (due to some kind of bug). 



Reproducible: Always
Comment 1 Christoph Feck 2010-10-08 19:39:58 UTC
If I understood last nights' IRC discussion correctly, this is probably a problem caused by Solid fstab kded module causing many D-Bus calls.
Comment 2 info 2010-10-11 21:20:36 UTC
same problem here.

Thinkpad t30, mandriva cooker, kde4.5.71.

Luca.
Comment 3 bill p. (aka google01103) 2011-01-06 14:44:57 UTC
have this problem when restarting kde with alt+ctrl+bksp in  4.5.95 (4.6 RC2) under 64bit openSuse
Comment 4 Jon Nelson 2011-02-03 19:19:23 UTC
Bug 242909 probably related.

I have a backtrace that might also be related.
Since upgrading to 4.6.0, this seems to be happening rather more frequently.


(gdb) bt
#0  0x00007f9b9ed136b3 in __poll (fds=<value optimized out>, 
    nfds=<value optimized out>, timeout=<value optimized out>)
    at ../sysdeps/unix/sysv/linux/poll.c:87
#1  0x00007f9b9c2cafd4 in g_main_context_poll (context=0x7c6bf0, block=1, 
    dispatch=1, self=<value optimized out>) at gmain.c:2904
#2  g_main_context_iterate (context=0x7c6bf0, block=1, dispatch=1, 
    self=<value optimized out>) at gmain.c:2586
#3  0x00007f9b9c2cb510 in IA__g_main_context_iteration (context=0x7c6bf0, 
    may_block=1) at gmain.c:2654
#4  0x00007f9b9f444a8f in QEventDispatcherGlib::processEvents (this=0x7984d0, 
    flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:422
#5  0x00007f9b9f419262 in QEventLoop::processEvents (
    this=<value optimized out>, flags=...) at kernel/qeventloop.cpp:149
#6  0x00007f9b9f419475 in QEventLoop::exec (this=0x7f9b9215ede0, flags=...)
    at kernel/qeventloop.cpp:201
#7  0x00007f9b9f32c1a4 in QThread::exec (this=<value optimized out>)
    at thread/qthread.cpp:490
#8  0x00007f9b9f3fa918 in QInotifyFileSystemWatcherEngine::run (this=0x786900)
    at io/qfilesystemwatcher_inotify.cpp:248
#9  0x00007f9b9f32ea1e in QThreadPrivate::start (arg=0x786900)
    at thread/qthread_unix.cpp:285
#10 0x00007f9b9ce21a4f in start_thread (arg=0x7f9b9215f710)
    at pthread_create.c:297
#11 0x00007f9b9ed1c82d in clone ()
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#12 0x0000000000000000 in ?? ()


and strace shows a /very/ tight loop:

[pid 24272] poll([{fd=14, events=POLLIN}, {fd=12, events=POLLIN}], 2, -1) = 1 ([{fd=12, revents=POLLIN}])
Comment 5 Lamarque V. Souza 2011-02-04 15:49:49 UTC
*** Bug 254902 has been marked as a duplicate of this bug. ***
Comment 6 Arkadiusz Miskiewicz 2011-02-05 16:27:29 UTC
https://bugs.kde.org/show_bug.cgi?id=220047
I've placed traces there that point to fstab module, too.
Comment 7 Kevin Coonan 2011-03-13 21:07:17 UTC
Created attachment 57934 [details]
view of htop output

This is ~4h after updated to 4.6.1, restarted X with Ctrl+Alt+Backspace.
Comment 8 Kevin Coonan 2011-03-13 21:09:07 UTC
Platform was openSUSE 11.3 x86_64
Comment 9 bill p. (aka google01103) 2011-03-13 21:10:56 UTC
for me this was resolved when I upgraded to 4.6.1 and concurrently openSuse 11.4
Comment 10 Alex Merry 2011-04-07 23:09:40 UTC
I think the kded4 part might be Bug 220047.  Don't know about the knotify4 part - I don't get that behaviour.

Certainly Jon Nelson's situation sounds very much like Bug 220047.
Comment 11 Adam Felson 2011-04-27 03:13:10 UTC
This is getting to be a very old bug, going back at least 2 years.
Any change it'll ever have a solution other than "kill it when it kde4/knotify has gone bazerk?"
Comment 12 David Faure 2011-04-27 12:03:33 UTC
Needs more info on the problem before it can have a solution -- which kded module is the culprit, with which backtrace. Or a sure way to reproduce the bug for everyone.

See also comment #23 in 220047, looks like recent developments in this bug investigation.
Comment 13 Adam Felson 2011-04-27 18:17:26 UTC
A problem is that it is not repeatable for me.  About once every other week I notice that my cpu usage indicator is showing runaway process(es) and often kded4 or knotify are the culprits.

Must I rebuild kde4/knotify with full debugging information?  What libraries just be retuilt likewise?  How do I determine which module has gone bazerk?  How do I get debugging information on the runaway process as I kill it?
Comment 14 crispin 2011-05-08 13:19:56 UTC
Am experiencing same problem on Kubuntu 11.04 / KDE 4.6.2 (i5-2400 / 8Gb RAM)
kded4 / knotify4 go to 100% CPU intermittently / system becomes sluggish (even though only one or two cores tied up) and unable to log out or shutdown.
Fault occurs 4-5 times per day - am unable to replicate bug.

Came back just now and my CPU was running at 95deg Celcius - not sure why automatic fan speed (BIOS) hadn't kicked up. I'm afraid KDE might be cooking my chips ...
Comment 15 Dion Moult 2011-05-11 18:23:33 UTC
I have just recently started experiencing this too - KDE 4.6.2, Gentoo, 64bit. It may be because I have started using KAlarm - it might be related to knotify not stopping calls to phonon or such from the little I have read online and my small tests.
Comment 16 Lamarque V. Souza 2011-05-17 01:38:37 UTC

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