Due to driver support for current hardware (and also me using an older CentOS release with a stable but ancient kernel) I have been running a home server lacking hardware monitoring for more than 4 years now, having access to only the hard disks temperatures.

Now the time has come to upgrade the good ol’ machine to a new hardware configuration – and of course the new hardware is also unsupported in even the latest CentOS kernels. Bellow is the output of sensors-detect:

Now follows a summary of the probes I have just done.
Just press ENTER to continue:

Driver 'to-be-written':
* ISA bus, address 0x290
Chip `ITE IT8655E Super IO Sensors' (confidence: 9)

Note: there is no driver for ITE IT8655E Super IO Sensors yet.
Check https://hwmon.wiki.kernel.org/device_support_status for updates.

No modules to load, skipping modules configuration.

But having to also migrate everything to a newer OS release (I won’t get into the support cutoff and Stream switch discussion – for my usage case any of the update policies works) this offered the occasion to play around with kernels and drivers. I’d really prefer to restore full hardware monitoring and balance noise and temperatures as best as possible. 

Thankfully, I’m not the only person in the world having this kind of a problem and someone has already put the effort in patching up the code necessary to support the I/O chip my motherboard uses. However, since this code didn’t make it into the mainline kernel (for obvious quality and assurance reasons), it needs to be manually compiled and installed – patched up code is good enough for me.

I didn’t want to get stuck to the (already old) kernel line on the new machine for the next couple of years – as I don’t have the habit on changing core things once everything is set up and running – so I decided to get dirty and migrate the OS to a newer kernel. Fortunately, ELRepo maintains an alternate kernel-lt branch that’s based on the current Linux Kernel Archive code but also includes the RHEL customizations. They also have a kernel-ml branch, but that’s too edgy for me.

My machine is currently running kernel-lt 5.4.100, so your results may vary with a different, especially (the official) older kernel.

The Action

Download, compile and install the custom IT87 Github repo from a1wong:

git clone https://github.com/a1wong/it87.git
cd it87/
make clean
make
make install

If you get any compilation errors, ensure that you have the kernel-headers package also installed.

Installing the custom module will have no effect on the output of the sensor-detect program, which will continue to report missing an IT8665E driver.

However, running sensors now should display a bunch of sensor information under the new “it8665-isa” section:

If there’s nothing new displayed, try a module (re)load:

modprobe it87

You should get no output if the module file exists and gets loaded correctly.

Even if everything works as expected the new module will still need to be loaded at every boot for the sensors to be visible. On CentOS 7/8 this is done by creating a new file under /etc/modules-load.d/ – name it it87.conf for example – and simply write the module’s name in it:

it87

Test the module load by performing a reboot and running sensors again after reboot.

Sensors configuration

The sensor names and limits can be further tweaked through the /etc/sensors3.conf file. For my particular Asus PRIME B450M-A board I use the following config:

chip "it8665-*"

    ignore in0
    ignore in1
    ignore in2
    ignore in3
    ignore in4
    ignore in5
    ignore in6

    label fan1 "CPU Fan"
    label fan2 "SYS1 Fan"
    label fan3 "SYS2 Fan"

    label temp1 "CPU Temp"
    label temp2 "MB Temp"
    label temp3 "PCH Temp"
    ignore temp4
    ignore temp5
    ignore temp6

    set temp1_min 0
    set temp1_max 70
    set temp1_crit 80
    set temp2_min 0
    set temp2_max 60
    set temp2_crit 70
    set temp3_min 0
    set temp3_max 60
    set temp3_crit 70

    set fan1_min 200
    set fan2_min 0
    set fan3_min 0

    ignore intrusion0

I don’t know the exact math algorithms required to make the voltage sensors make sense, so I’m just ignoring them all (I only care about the fans and temps anyway).

Addendum

The module will need to be recompiled and reinstalled after every kernel change. This can be done by running the make commands described in this article again.

Automatic kernel updates, in case the system performs updates automatically or you wouldn’t want to forget and accidentally break the sensors reading, can be disabled by adding the following configuration line at the end of the /etc/dnf/dnf.conf (or /etc/yum.conf in CentOS 7) file:

# exclude kernel releases from automatic update
exclude=kernel*

When manually performing updates, add the parameter to temporarily bypass the exclusion and include kernel updates:

dnf --disableexcludes=all update

The parameter can be:

  • all – disables all excludes
  • main – disable excludes defined in [main] section of the conf
  • repoid – disables excludes defined for given repo id

The reverse of the above would be to manually exclude kernel when performing other updates, with:

dnf --exclude=kernel\* update

Leave a Reply