Kodi Community Forum

Full Version: Ubuntu Server 18.04 LTS - Kodi 17.6 stable PPA / high CPU
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Ubuntu Server 18.04 LTS, fresh install.
Kodi 17.6 stable PPA. Running on openbox, without pulseaudio, custom edid, custom systemd launch and suspend scripts.
Hardware: Intel apollo lake, asrock J4205

I am noticing long periods of high CPU usage, with one of the cpu cores staying at 100% for many minutes at a time. The process hogging the CPU is kodi.bin. This happens both with Kodi being idle, and with Kodi playing back content. Video playback is not impacted at all, but all GUI operations become sluggish while this lasts.

Before using the kodi PPA, I tried the original debian package, it had the same problem, only worse (Kodi stayed more often at 100% cpu utilization). Then I tried building Kodi from source, it worked fine but it showed the same problem. Finally the ppa-stable build became available, the situation improved significantly with it but I still see high 100% CPU starting anywhere from 15 minutes to an hour after starting Kodi.

This same hardware has been running Kodi on Fedora server 27 for about a year before this, same 17.6 release built from source, very similar environment (openbox, no pulseaudio, same custom scripts etc) with no high CPU issues at all, ever. Older kernel though, 4.13. Using the exact same Kodi configuration including all addons (I ported over the entire .kodi directory since I was already running 17.6 on linux) in both cases.

Anyone on ubuntu 18.04 noticing High CPU issues with the kodi process, any hint of what the issue could be?
Found a solution / back to normal by disabling IPv6. I use IPv6 in my home network, and the HTPC server was picking up a public IPv6 address, and that was somehow bothering kodi, idling at 30% CPU and peaking at 100% randomly 

This is how I solved the problem:
 
  • IPv6 (system slowness in kodi and then the system - high CPU in the kodi.bin process)
    • tried disabling IPv6 in /etc/sysctl.conf  - the slowness goes away but then the kodi systemd service does not start properly (kodi crashes)
    • disabling IPv6 with a kernel parameter solved the problem; kodi idles at 6% CPU as normal
      • ipv6.disable=1