CPU usage on PI4 is insane

  • On my pi4 2gb kodi.bin uses 30% CPU while idle. A quick use of strace shows why.

    I assume this is a kodi issue rather than a libreelec issue?

  • I would go through your installed add-on list and disable them one by one and observe any change in cpu behavior, by ssh'ing to your box and running top.

    For example, I had a similar issue where my cpu was being smashed, and I found it was caused by the Library Watchdog add-on.

  • I checked my Pi4 and found similar results to yours - ~30% CPU usage at idle. I removed a redundant Aeon NOX skin and was then able to remove something called Library Data Provider. This brought it down to ~21%. I then removed a redundant Spotify add-on and that reduced by another couple of percent. My strace also provided similar data to yours.

    20% still seems to me to be a little high, especially when the Windows laptop I'm typing this on will idle at around 1-3%. I suppose there's always the danger of comparing apples with oranges though.

  • kodi.bin consuming about 15-20% on idle is quite normal on a clean install. Keep in mind that this is the percentage of a single core, RPi4 has 4 cores so it can go up to 400%. If you look at the "%Cpu(s)" summary in top you'll see about 95% idle.

    Also keep in mind that the CPU frequency will have scaled down to 700MHz (check with bcmstat.sh or "vcgencmd measure_clock arm") and the load values reported from top are relative to that. So in absolute terms (4 cores at 1.5GHz max) kodi comsumes about 2.5% of available CPU resources.

    Of course addons etc running in the background will consume CPU resources, so 20-30% (of a single core, at 700MHz) still look rather plausible.

    so long,

    Hias