Ubuntu – Laptop CPU+GPU overheating after update to 18.04 LTS

18.04cpu loadinteltemperature

I had this same issue in my last attempt to upgrade (with a clean install) from 16.04 LTS to 18.04 LTS. When I am browsing internet and specially when I am playing videos my CPU+GPU raises to fast to high levels causing throttling to fire and producing intolerable lags, leaving the system unusable for about 60 seconds or more.

With Ubuntu 16.04 LTS I never experienced this problem. Of course temperatures raised and throttling fired frequently (after all this is a laptop), but system was never unusable and video playback was smooth.

My previous solution was to downgrade to 16.04 LTS again, but now I need the newer version so I want to find a solution.

System specs:

  • CPU: Intel Core i7-6500U
  • GPU: Intel HD Graphics 520
  • Ubuntu: 18.04 LTS
  • Linux: 4.15.0-30
  • Mesa: 18.0.5
  • Hardware acceleration: on

UPDATE 1

Definitively it is a problem with frequency throttling. Instead of throttling CPU frequency to avoid overheating the procesor, the system is waiting until temperature reaches a limit (default of 85ºC) and then intel_powerclamp module fires, turning the system unusable for 60 seconds or more.

I would expect a progressive performance degradation from intel_powerclamp, but no, it is all or nothing. ¿Can this be configured?

My current solution is a modification of the script of this answer. It seems to work, but it is a big hack. There must be a conventional way to tweak system configuration to accomplish the same result.

UPDATE 2

If I turn off frequency turbo boost (echo "1" | sudo tee /sys/devices/system/cpu/intel_pstate/no_turbo) the problem completely disappears. Temperature never reaches the limit and the script introduced on update 1 nor intel_powerclamp fires and the laptop is smooth and usable.

Problem now is that turbo boost is disabled. With Ubuntu 16.04 LTS I never had this issue.

This is clearly a bad configuration of the thermal management subsystem of Ubuntu 18.04 LTS. Is there a way to fix it?

UPDATE 3

System is still unusable. Installing Ubuntu 18.04 LTS server and anything else than Gnome3 works. Well, it's not a novelty that Gnome sucks, but it was usable with 16.04…

Best Answer

Disable intel_pstate at boot by editing your grub configuration.

Open /etc/default/grub with your preferred text editor and locate the line that begins with:

GRUB_CMDLINE_LINUX_DEFAULT

And add intel_pstate=disable at the end of that string. Here's how mine looks after that:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash intel_pstate=disable"

Now, execute:

sudo update-grub

And reboot your laptop. That's it. It should work as smooth and cool as with 16.04.

Some additional information: intel_pstate governor seems to be buggy, or just plain stupid and unable to detect quick temperature raises and reduce the processor speed in consequence. It seems it'd just pray to Saint Cooling Device for it to keep the CPU below the shutdown threshold. In a desktop computer with a DC9 turbine like fan such leap of faith maybe justified, but in laptops with one small fan like my XPS13 it's better to be skeptic and leave those things to the good old ACPI (Atheist Configuration and Power Interface). At least until the intel_pstate governor grow some brains.

And the turbo boost is mostly useless. Chances are that you won't lose anything for having it disabled. That feature was useful in the days of monocore 32 bit processor, but not in the 64 bit multicore world we're living on right now.

Related Question