Plasmashell CPU Usage

I’ve been noticing an increase in CPU usage by the plasmashell process. Top says that, on my laptop, plasmashell is using around 5% of my CPU immediately after start up and then it grows from there. Within an hour or so, the plasmashell process will be using over 20% of my cpu and my laptop fans begin to run too. My laptop has an 8 core Intel i7-4810MQ CPU @ 2.80 GHz. I am running KDE Plasma Version 5.4.3 with Qt Version 5.5.1. I have several widgets on my desktop including the CPU Load Monitor and it appears that the plasmoid widgets could be the culprit. For example, when I remove the CPU Load Monitor then plasmashell’s CPU usage decreases by around 3%. Is it normal for plasmoid widgets to use this much CPU time? Also, why does the plasmashell CPU usage increase with time and is there a fix to prevent this? Having your computer consuming over 20% of a very modern CPU’s cycles while doing nothing but running widgets seems a bit far fetched not to be a bug especially since the CPU usage continues to grow past that until I restart plasmashell.

Thanks,

Gordon

I’ve been noticing this too, on my desktop PC. I have an 8-core processor too, but it is an AMD FX-8350.
I noticed it primarily because of my fans starting to go loud, otherwise I think it would have gone unnoticed. But I too think this in Not Good.
If I restart plasmashell, it will go back to using 1-2% of CPU and then increase again after a couple hours.

I have a few widgets on my desktop:

  • system load viewer
  • hard disk space usage
  • network monitor
  • notes

Cris

As a test

  1. remove widgets see if makes a difference

  2. try xrandr instead of openGL

3)) turn off effects

also what video and what driver

And are you fully up to date with updates

Hi Cris70 and gogalthorp,

Thanks for your replies!

In reply to gogalthorp, I disabled my “active” full screen widgets which were:

  • Load Monitor
  • Network Monitor
  • Memory Status
  • Analog Clock (with second hand)

With these widgets removed, plasmashell CPU usage decreased to under 1%. Whereas, with these widgets active, the plasmashell CPU usage started at 5% and went up quickly from there until I restarted plasmashell. This morning, I let plasmashell run for about 3 hours without restarting and the plasmashell CPU utilization grew to around 50% of my 8 core Intel i7-4810MQ CPU @ 2.80 GHz!..

I am currently running the Intel graphics driver using Bumblebee with hybred video enabled in BIOS which I have been running for about a week. Prior to that, I was running the nVidia driver exclusively with a Quadro K2200M video adapter. I did not notice this CPU usage problem until I switched to Bumblebee so it may also have something to do with Bumblebee or the Intel graphcs driver too. I switched to Bumblebee because of the following bug that causes Konsole not to play nicely with the dedicated nVidia driver:

https://bugs.kde.org/show_bug.cgi?id=343803
When I get some extra time, I will return to the dedicated nVidia driver and see if I detect the problem occurring with that setup as well. However, I will not have time to do that until the middle or end of next week so, if anybody else is running the dedicated nVidia or AMD drivers with the “active” plasmoid widgets, it will be interesting to hear if you are seeing this problem.

In summary, based on my research, this problem is definitely caused by the “active” plasmoid widgets, however, I am uncertain if the problem only occurs with the Intel graphics driver using Bumblebee or with any other graphics drivers as well.

Its also strange that the problem grows and grows over time, to the point where plasmashell is consuming over half of my CPU cycles, until plasmashell is restarted. As a bandaid, I therefore have programed a keyboard shortcut, <meta>-F2, to restart plasmashell which I have been using to mitigate this problem every hour or so… Ugh…

FYI,

Gordon

If you don’t have a Optimus notebook DO NOT use bumblebee.

Try adding the widgets back one at a time to find the one that is eating CPU cycles.

The normal NVIDIA driver makes changes to the X stack mesa in particular. Since the nvidia-bumblebee package does not change the files you run with the stock mesa.

If you find only one widget that is bad report on bugzilla

Note you should always remove the NVIDIA driver before changing types sine simply overwriting may leave parts of the previous one.

My computer IS an Optimus laptop. Furthermore, my BIOS allows me to “enable hybrid graphics” to enable Optimus or “disable hybrid graphics” so that I only run the dedicated nVidia card exclusively if I prefer. I have run it both ways and I have only noticed this CPU usage problem when running the Intel driver with Bumblebee which is the way that my laptop is currently configured. I will test it the other way with the dedicated nVidia card soon.

I have done that and all of the widgets cause the problem, however, some impact the CPU usage more than others. The widgets that create the most video also create the most CPU consumption. Accordingly, the Load Monitor widget is the worst culprit.

I will probably file a bug report (or update an existing bug) after testing with the dedicated nVidia card setup without Optimus. If you google this you will find that there are already several KDE bug reports on the plasmoids consuming lots of CPU usage and lots of forum posts on several forums. So, lots of Plasma 5 users have also experienced this problem.

Yes, everytime that I have switched back and forth I always remove the appropriate drivers. That is, I remove the Nvidia driver when I run Optimus and I remove the Intel driver and Bumblebee package when I run the dedicated nVidia card.

Thanks,

Gordon

Suspected a plasma5 problem there seems to be many. Also never heard of a optimus machine you could disable hybrid. That is a nice feature

Maybe try going to plasma 5.5 it is available don’t know if that will fix the problem but it might

I have observed this type of behavior of Konsole. But I don’t remember which OS it was, since I have changed it a few times recently.

It was quite strange, unexpected bug.

One problem that makes it difficult to investigate Nvidia-related bugs is that, generally, it is impossible to install old Nvidia drivers without changing the kernel version.

I uninstalled Bumblebee and the intel graphics driver and then reinstalled the dedicated nVidia driver with hybrid graphics disabled in BIOS. The excessive Plasma 5 CPU usage problem with the active widgets persisted with the dedicated nVidia driver as well. So, this problem occurs with nVidia Graphics or Intel graphics with or without Bumblebee. This problem is not related to the graphics driver at all and I think that it is a Plasma 5 issue exclusively.

Also, I did a clean install of Leap 42.1 with Plasma 5 on another laptop (w/ Intel Graphics), immediately added the CPU Monitor and Analog Clock widgets to the desktop and the Plasma 5 CPU usage immediately went from less than 1% to over 5%. Also, after two hours the Plasma 5 CPU usage had increased to between 10% and 15% and was still growing. Again, this is on a fresh install…

FYI,

Gordon

I just added the KDE “Frameworks 5 & Plasma 5” repo and updated to Plasma Version 5.5.2. The same problem persists with plasmashell’s CPU usage on Plasma Version 5.5.2 so I am at a dead end. Guess its time to file a bug report…

Not sure if this is relevant on Leap but I have just cured a similar problem on Tumbleweed, for me it was the Desktop Toolbox plasmoid that caused 100% CPU on one core, also Iknow that the CPU monitor has been causing it for other people.

baskitcaise, thanks for your reply!

I have done quite a bit of testing and the problem appears to be caused exclusively by animated desktop widgets. In other words, any widget that creates video animation will consume excessive CPU cycles and the amount of CPU usage appears to be related to the amount of animation. When I loaded my desktop up with lots of animated widgets, then after a few hours, Plasmashell was using over 50% of my of my 8 core Intel i7-4810MQ CPU @ 2.80 GHz!.. For this and for many other reasons, I continue to be completely underwhelmed by Plasma 5…

Over three weeks ago I filed a bug report here:

https://bugs.kde.org/show_bug.cgi?id=357597

However, the KDE developers have not replied or commented on the bug and the bug continues to be listed as “UNCONFIRMED”. Ugh… I feel like a mushroom…

FYI,

Gordon

Hi all,

I know this is an old thread but I am experiencing the same problem.

After looking with System Monitor I realized as soon as I use the Application Menu it is hugging 50% of (2 out 4 cores). After removing the widget it didn’t help either until I restarted plasmashell. Then after adding back the Application Menu widget it kicked in with 75% of CPU usage.

I can also use the Plasma Search launcher to start applications but I would also like to use an application menu…

Any advice?

I think I found a workaround while trying to provide more diagnostic info. I right clicked on the widget and under Application Menu Settings I unchecked everything. When I clicked Apply it then logged the suspicious lines below but it doesn’t hug my CPU anymore.

file:///usr/share/plasma/plasmoids/org.kde.plasma.kicker/contents/ui/main.qml:73:5: QML RootModel: Binding loop detected for property “showRecentApps”
file:///usr/share/plasma/plasmoids/org.kde.plasma.kicker/contents/ui/main.qml:73:5: QML RootModel: Binding loop detected for property “showRecentDocs”

When searching with the message it looks like it is a common QT issue associated with high CPU usage so it seems like this was the problem…

I suppose that this issue, at least for me on Tumbleweed, is connected with “Plasma search” which uses baloo’s db. I say this, because I can reproduce the exact issue with ‘krunner’ (Alt+F2). I just start to type something to search for a file (without clicking on it), then for another, then for another… and lo… plasmashell (if you used the Application menu) or krunner goes crazy…

OK, I reinstalled (update unconditionally) all the baloo packages, then I logged out, and logged in a standard text console, and with mc I deleted the contents of “/home/user/.cache” folder, and the contents of “/home/user/.local/share/baloo/” and after that I logged in Plasma 5, and opened a Konsole and issued this command to rebuild the baloo db: “balooctl check”. (You can check the indexer’s status with: “balooctl status”)

Now it seems, the issue went away… at least for me, for now :slight_smile:

Great help, thank for sharing

[QUOTE=atskler;2785756]OK, I reinstalled (update unconditionally) all the baloo packages, then I logged out, and logged in a standard text console, and with mc I deleted the contents of “/home/user/.cache” folder, and the contents of “/home/user/.local/share/baloo/” and after that I logged in Plasma 5, and opened a Konsole and issued this command to rebuild the baloo db: “balooctl check”. (You can check the indexer’s status with: “balooctl status”)

I have similar issue.

I deleted all baloo packages, the cache and the baloo folder, and have very few apps running.

plasmashell is increasing its CPU usage, over a few hours going from 15% to 95%.
However, RAM usage is not ballooning. (Does this mean they have already learned to release memory? Will they also learn to release the CPU after usage?)

[quote="“ZStefan,post:18,topic:113535”]

I’m afraid my and JeromeQc’s issue was a different one.
So I don’t know … :frowning:

(If you are interested, you may try to use the Kepner-Trego’s “Analytic trouble shooting process guide” (and/or the “Rational manager”) to clarify your issue and try to find its cause and fix it. Of course you will need technical knowledge too. You can borrow and read freely these books online in the openlibrary as linked.)

The plasmashell devil has deep roots.

Recently I installed opensuse 13.2 on a laptop. After some time and updates, the OS became slow. I investigated and found the same devil that eats CPU power in Tumbleweed and Leap: the plasmashell.

It took me half a day to see which package the devil belongs to, and to delete it and all the chain of associated packages. They include libKF5, plasma5, breeze and many others. I put “Taboo - never install” label on many, perhaps innocent and useful, packages. The process finished successfully (I don’t know for how long). It is actually a type of exorcism.

A professional exorcist will do it easily, in a straightforward manner, and will exterminate the devil forever. There is a big need in him.