Installing lm-sensors (hardware sensors) support
on Intel(R) Core(TM) i7 CPU on Debian Lenny Linux to track your
system hardware temperature
In this topic I'll explain you step by step the exact steps I took
to
install lm-sensors (sensors) support on
Debian Lenny
GNU/Linux to work with a
Quad Core Intel(R) Core(TM) i7
CPU
Normally in most hardware installing lm-sensors and running and
completing a simple
sensors-detect would be sufficient for
lm-sensors to detect most of the system hardwares,
however since
Intel i7
architecture is rather new and on the other hand Debian Lenny's
sensors kernel module and lm-sensors packages are comparatively old
as Debian's stable version releases are officially released with
the approximately 2 years release cycle.
Thus albeit the usual simple way to detect with the command:
debian-server:~# sensors-detect
wasn't able to detect any matching lm-sensors supported sensors
hardware to track.
A quick google search revealed that other people are experiencing
problems with configuring lm-sensors to work on Linux with the i7
intel CPU architecture and luckily some of them even
succeeded.
A good forum discussions on the topic that I found were the Ubuntu
forums:
lm-sensors and
P6T6 WS Revolution mobo with i7 920 CPU as well as the
debian.net forum thread:
Where is
coretemp module?
Therefore I used the information of both of the aforementioned
locations and was able to
succesfully install and run the i7
Intel CPU architecture support with lm-sensors in a quick and
simple way on a Debian kernel returning an uname of:
Linux debian-server 2.6.26-2-amd64 #1 SMP Tue Jan 12 22:12:20 UTC
2010 x86_64 GNU/Linux using the following steps:
1. Download, Compile and install a patched source of the kernel
coretemp.ko module - This is an absolute requirement except
which you won't never ever be able to make the sensors work on
Debian Lenny.
By the default the
coretemp.ko kernel module provided with
Debian Lenny prepackaged in the 64 bit kernel image in
linux-image-2.6.26-2-amd64 doesn't have an included support
for the i7 intel architecture.
So procceed with downloading:
debian-server:~# wget
http://pc-freak.net/files/coretemp.zip
2. Install necessary packages which will be required for a
succesful compile and install of the patched coretemp.ko kernel
module
debian-server:~# apt-get install build-essential gcc
linux-headers-`uname -r` module-assistant
lm-sensors
If you already have the
lm-sensors - 1:3.0.2-1+b2 utilities to
read temperature/voltage/fan sensors already installed you can
remove the lm-sensors string from the up-mentioned apt-get command
line.
3. Configure and Install the new patched version of coretemp.ko
which will support the I7 Intel CPU architecture on
Debian
debian-server:~# cd coretemp/
debian-server:/root/coretemp# m-a update
debian-server:/root/coretemp# m-a prepare
debian-server:/root/coretemp# make
debian-server:/root/coretemp# make install
You should see an output similar to if the new coretemp.ko is
properly installed:
mv
/lib/modules/2.6.26-2-amd64/kernel/drivers/hwmon/coretemp.ko
/lib/modules/2.6.26-2-amd64/kernel/drivers/hwmon/coretemp.ko.old
cp coretemp.ko
/lib/modules/2.6.26-2-amd64/kernel/drivers/hwmon/
depmod -a
4. Load the intel i7 lm-sensors necessary kernel modules and
configure the modules to be loaded on Linux System Boot
First we load the necessary modules into the kernel:
debian-server:~# modprobe coretemp
debian-server:~# modprobe w83627ehf
force_id=0x8860
Next we schedule the modules to automatically load in debian boot
time:
debian-server:~# echo "w83627ehf force_id=0x8860" >>
/etc/modules
debian-server:~# echo "coretemp" >>
/etc/modules
Now you could try out the sensors if they already report properly
the CPU and system temperatures and statuses using:
debian-server:~# sensors
w83627ehf-isa-0ca0
Adapter: ISA adapter
VCore: +0.99 V (min = +0.00 V, max = +1.74 V)
in1: +6.34 V (min = +4.59 V, max = +7.66 V)
AVCC: +3.34 V (min = +3.12 V, max = +0.03 V) ALARM
3VCC: +3.34 V (min = +2.05 V, max = +2.78 V) ALARM
in4: +1.22 V (min = +0.08 V, max = +1.94 V)
in5: +0.97 V (min = +0.87 V, max = +0.35 V) ALARM
in6: +3.07 V (min = +2.71 V, max = +2.87 V) ALARM
VSB: +3.33 V (min = +2.53 V, max = +3.49 V)
VBAT: +3.28 V (min = +3.36 V, max = +2.51 V) ALARM
in9: +0.00 V (min = +0.70 V, max = +0.82 V) ALARM
Case Fan: 0 RPM (min = 1506 RPM, div = 128) ALARM
CPU Fan: 0 RPM (min = 703 RPM, div = 128) ALARM
Aux Fan: 0 RPM (min = 2636 RPM, div = 128) ALARM
fan4: 0 RPM (min = 3515 RPM, div = 128) ALARM
fan5: 0 RPM (min = 703 RPM, div = 128) ALARM
Sys Temp: +32.0°C (high = +72.0°C, hyst = -34.0°C) sensor =
thermistor
CPU Temp: -31.5°C (high = +80.0°C, hyst = +75.0°C) sensor =
thermis
AUX Temp: +29.0°C (high = +80.0°C, hyst = +75.0°C) sensor =
thermis
cpu0_vid: +3.500 V
coretemp-isa-0000
Adapter: ISA adapter
Core 0: +55.0°C (high = +80.0°C, crit = +100.0°C)
coretemp-isa-0001
Adapter: ISA adapter
Core 1: +53.0°C (high = +80.0°C, crit = +100.0)
coretemp-isa-0002
Adapter: ISA adapter
Core 2: +53.0°C (high = +80.0°C, crit = +100)
coretemp-isa-0003
Adapter: ISA adapter
Core 3: +52.0°C (high = +80.0°C, crit = +100)
coretemp-isa-0004
Adapter: ISA adapter
Core 4: +55.0°C (high = +80.0°C, crit = +100.0)
coretemp-isa-0005
Adapter: ISA adapter
Core 5: +53.0°C (high = +80.0°C, crit = +100)
coretemp-isa-0006
Adapter: ISA adapter
Core 6: +53.0°C (high = +80.0°C, crit = +100)
coretemp-isa-0007
Adapter: ISA adapter
Core 7: +52.0°C (high = +80.0°C, crit = +100)
Yeah! It's pretty handsome that lm-sensors reports the CPU system
statuses for each of the Intel i7 cores :)
debian-server:~# unzip coretemp.zip
debian-server:~# cd coretemp/