Control QNAP NAS Fan Speed in PVE
It’s getting hot in summer, the hard disks in my QNAP NAS are overheating. Since I’m using PVE, I can’t control the fan speed. Luckily, somebody has already solved this problem. Here is the guide.
Install the 8528 Kernel Module
First, install the 8528 kernel module to get the fan speed information. In Linux, you can install the lm-sensors package to get the CPU and HDD temperature. You can run sensors command to see the temperature. However, the fan speed information is not shown. As the QNAP uses a ITE8528 embedded controller to control the fan speed, the lm-sensors package does not support it.
Option 1: Install with DKMS
qnap8528 provides a kernel module to support this controller. It contains the instruction to install with DKMS and autoload module on startup with systemd. Don’t forget to install the pre-requisite packages: apt install build-essential pve-headers dkms. You may need to install proxmox-headers-$(uname -r) if the kernel is not the latest version.
This methods automatically rebuild the kernel module when the kernel is updated.
Option 2: Build module in Docker
Gzxiexl created a more conventient script to build, install and automatically load the kernel module. This script does not support PVE 9 currently, but I’ve created a PR. Before it’s merged, you need to install the kernel headers with apt install proxmox-headers-$(uname -r) and edit the Dockerfile to use debian:13 as base image. Then you can run the sudo build.sh.
This methods is more convenient, but you need to rebuild the kernel module when the kernel is updated.
After install the kernel module, the fan speed and NAS temperature appear in the sensors output.
| |
The above output contains the drivetemp-scsi-1-0, which shows the hard disk temperature. It’s not shown by default, you need to load the drivetemp module with sudo modprobe drivetemp
Cooler Control
Second, Cooler Control can control the fan speed with customized fan speed curve, which is based on the CPU or HDD temperature. After install the debian package, don’t forget to edit the /etc/coolercontrol/config.toml to change the bind IP addresses. The service can be started with systemctl enable --now coolercontrold, and the web UI is available at http://<your-pve-host>:11987. There is a pretty dashboard to show CPU and HDD temperature in the web UI. By setting a fan speed curve profile, the fan speed can be controlled with the HDD temperature.

Now the hard disks can be kept in a safe temperature range.