Thanks alot for sharing this! I just signed up for this.
I'm not actually using Xpenology but rather Openmediavault and the fans seem to kick in to 100% and then ramp down. Your code helped me figure out how to manage the fans.
For reference to anyone stumbling on this thread and wants to port it to OMV:
1. You need to change where the drives are detected since it's different from DSM. For me it was located in /run/disks
EDIT: These did not exist by default. I've created this directory and just created empty files inside (as root):
mkdir /run/disks
cd /run/disks
touch sda sdb sdc
This far from perfect and if you're a Linux wizard you probably can do something better with regex, e.g. /dev/sd*[a-z]
2. Replace the directory in line 51 (fancontrol.cpp) with the directory containing your drives. For me that was:
conststaticchar* synostoragedir ="/run/disks";
3. Compile fancontrol.cpp and run with sudo.
Tip: You can use a docker gcc image to avoid installing dependencies on OMV/Debian/Ubuntu
Pull the image:
docker pull gcc
Compile fancontrol.cpp (you must be in the same directory)
This helped me out tremendously. I'm running this on OMV 5 and it works flawlessly. The only issue I had is that I didn't pay attention to where the /run/disks was supposed to be created at. It's /var/run/disks, and then you create each file with that name.
Terramaster F4-220 fan control
in Software Modding
Posted
This helped me out tremendously. I'm running this on OMV 5 and it works flawlessly. The only issue I had is that I didn't pay attention to where the /run/disks was supposed to be created at. It's /var/run/disks, and then you create each file with that name.