CPU Temperature

From FreekiWiki
Revision as of 12:36, 9 May 2014 by Aroberts (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
deletion

This page has been migrated to a document on Free Geek's Google Drive.

Information remaining behind may no longer be relevant.

MIGRATOR:

When you have tagged this page as migrated,
please add a link to the new document on Google Drive.

(Link to new page immediately below.)


[1]

Overview

Systems that freeze after a period of use (but not when started cold) may be having problems with overheating. This is especially true for laptops. You can use lm-sensors to determine the temperature of the CPU.

Using lm-sensors

Install and Configure lm-sensors

  • Install the lm-sensors package (see InstallingSoftware).
  • Run sudo sensors-detect and answer YES to all YES/no questions. I generally use the ISA bus rather than the SMBus bus, your choice to this question!.
  • At the end of sensors-detect, a list of modules that needs to be loaded will displayed. Type "yes" to have sensors-detect insert those modules into /etc/modules, or edit /etc/modules yourself.
  • Next, run "sudo /etc/init.d/module-init-tools". This will read the changes you made to /etc/modules in step 3, and insert the new modules into the kernel.
  • Run "sensors" to get temperature readings.

Run a Stress Test

It is useful to have this running continuously and also have it logging to a file. The following file will record the output of sensors and uptime (so you can monitor the load and get a timestamp) in a file, every 30 seconds and display it on the screen (thanks to the magic of tee and an infinite loop).

while  [[ true ]] ; do uptime ; sensors ; sleep 30s; done | tee temp_load.log

Run that command in one terminal window and this in another:

 stress --cpu 8 --io 4 --vm  2 --vm-bytes 128M  --timeout 4h 

This will stress the machine for four hours, or until it crashes ;)

(add --hdd 2 to stress the hard drive as well, though this shouldn't be necessary)

More Information

The ubuntu-maintained page can be found here.

This page contains commands written thanks to the magic of tea!