Paid Apps Gone Free - PAGF (Beta)

Fix Random System Freeze and Crashes in Fanless Intel Laptops

If you own a fanless Laptop/Desktop PC with Intel chip, then you may have faced random system lockups making entire OS unresponsive.

Tl;dr
sudo apt remove thermald
These system crashes mainly occur when using CPU intensive tasks or when CPU temperature crosses a particular threshold limit.

I recently purchased two fanless laptops with intention of installing Ubuntu on both. Unfortunately my experience has not been very good. I faced above mentioned freezes on Ubuntu as well as on all Ubuntu derivatives I installed on these laptops (including KDE Neon). These crashes were so bad that the live installer would freeze entire system before finishing installation. 

While testing these Ubuntu builds, I noticed that Windows 10 that came pre-installed on these laptops, had no such issues. On all Ubuntu and derivative builds I installed, my system would freeze exactly when CPU temperature reached 67 C while Windows 10 kept running smoothly even at 72 0 C+. So I ruled out any hardware defects.

To test 67 o C theory, I stressed CPU numerous times using command below and each time my system would freeze precisely at 67 o C.

stress -c4
I tried numerous fixes mentioned on Web that included replacing Intel pstate and adding various Grub parameters. None of them worked. At this time, I more or less figured out that these random freezes occur because of the way system manages CPU temperature.

And so I came to know about "thermald". Check out the thermald package description below.

Thermal Daemon is a Linux daemon for monitoring and controlling platform temperatures. Once the system temperature reaches a certain threshold, the Linux daemon activates various cooling methods to try to cool the system.
I was now pretty sure that thermald was culprit and ran the command below:

grep -r . /sys/class/thermal/*
One of the output lines mentioned:

/sys/class/thermal/thermal_zone7/temp:67000
I figured that once CPU temperature reached 67 o C, thermald would trigger a CPU cooling algorithm that crashed my entire system. So I tweaked thermald config files after referring to man pages. Unfortunately this did not resolve my issue.

I ran all these tests on Ubuntu 16.04 LTS and derivatives, so I decided to look at newer thermald package in Ubuntu 16.10 and check if there are any upstream changes. One of the changelog lines had this:

  * upstream fix 53154fd496a ("Remove auto adjusted max temp")
    - addresses aggressive over-throttling on some H/W (LP: #1600599)
I immediately grabbed Ubuntu 16.10 thermald deb package and installed it on Ubuntu 16.04 LTS. After reboot, my problem was gone, but not completely.

System freezing exactly at 67 o C was resolved. I ran numerous CPU stress tests again and this time my system kept running even after crossing 70 o C. However, my system would still freeze randomly once a day. Earlier it was once every few minutes (yes, it was that bad), but now at least I had some peace of mind. 

I decided to completely remove thermald, at the cost of removing an OS level laptop cooling mechanism (which is all the more important on a fanless system, but stability was crucial for me). Since then it has been more than 90 days and I haven't faced a single system freeze. 

I suggested the same fix to one of our readers whose Intel braswell laptop would freeze at certain temperatures while light gaming. His problem was also resolved.

If you are facing similar system crashes, give this a shot and hopefully things will work for you (even on systems having fan based cooling).

However, it goes without saying that I am not responsible for any hardware damages you may have to face after following this guide. Use it at your own discretion.

1 comments:

Unknown said...

Awesome post dear......really great topic it is i am also stressed with this same issue i also have intel braswell....tha k you once again for sharing your experience....

Follow Us !!

Follow on TwitterFollow on FacebookGet PAGF Android App on Play StoreSubscribe via emailSubscribe to RSSFollow on Google Plus