0

I am running into a problem with fancontrol that I cannot fix. I tried things I found on internet but none of them seem to work. Hopefully you can help me.

Problem

Fancontrol does not start at bootup. When executing fancontrol in the terminal I got the following error.

Loading configuration from /etc/fancontrol ...

Common settings:  INTERVAL=1

Settings for hwmon2/pwm1:  Depends on hwmon1/temp5_input  Controls hwmon2/fan1_input  MINTEMP=40  MAXTEMP=80  MINSTART=77  MINSTOP=24  MINPWM=0  MAXPWM=255  AVERAGE=20

Settings for hwmon2/pwm2:  Depends on hwmon1/temp5_input  Controls hwmon2/fan2_input  MINTEMP=40  MAXTEMP=80  MINSTART=100  MINSTOP=92  MINPWM=0  MAXPWM=255  AVERAGE=20

Settings for hwmon2/pwm3:  Depends on hwmon1/temp5_input  Controls hwmon2/fan3_input  MINTEMP=40  MAXTEMP=80  MINSTART=64  MINSTOP=64  MINPWM=64  MAXPWM=255  AVERAGE=20

Error: file hwmon2/pwm1 doesn't exist Error: file hwmon2/pwm2 doesn't exist Error: file hwmon2/pwm3 doesn't exist

At least one referenced file is missing. Either some required kernel modules haven't been loaded, or your configuration file is outdated. In the latter case, you should run pwmconfig again.

This is what my settingsfile looks like.

# Configuration file generated by pwmconfig, changes will be lost
INTERVAL=1
DEVPATH=hwmon1=devices/platform/coretemp.0 hwmon2=devices/platform/it87.2608

DEVNAME=hwmon1=coretemp hwmon2=it8728 FCTEMPS=hwmon2/pwm1=hwmon1/temp5_input hwmon2/pwm2=hwmon1/temp5_input hwmon2/pwm3=hwmon1/temp5_input FCFANS=hwmon2/pwm1=hwmon2/fan1_input hwmon2/pwm2=hwmon2/fan2_input hwmon2/pwm3=hwmon2/fan3_input MINTEMP=hwmon2/pwm1=40 hwmon2/pwm2=40 hwmon2/pwm3=40 MAXTEMP=hwmon2/pwm1=80 hwmon2/pwm2=80 hwmon2/pwm3=80 MINSTART=hwmon2/pwm1=77 hwmon2/pwm2=100 hwmon2/pwm3=64 MINSTOP=hwmon2/pwm1=24 hwmon2/pwm2=92 hwmon2/pwm3=64 MINPWM=hwmon2/pwm1=0 hwmon2/pwm2=0 hwmon2/pwm3=64 MAXPWM=hwmon2/pwm1=255 hwmon2/pwm2=255 hwmon2/pwm3=255 AVERAGE=hwmon2/pwm1=20 hwmon2/pwm2=20 hwmon2/pwm3=20

The really weird thing is, when I execute this command (sudo services fancontrol start), fancontrol starts working perfectly. When running fancontrol in the terminal I get the exact same errors as before although this time fancontrol works perfectly. Running pwmconfig does not help as it will create a similar settings file as mine, creating the same errors.

The fans are originally automatically controlled by the motherboard but that control makes a mess of things. This is why I need fancontrol.

I am running kubuntu 22.04

Any help would be greatly appreciated!

  • what is in /sys/devices/platform/it87.2608/hwmon/ and the hwmon# directory in that? Sometimes the number can change causing issues, but I don't think that is it. – rtaft Nov 13 '23 at 20:01
  • The files that my settings file are referring to do actually exist at the specified location. I did try the [[:print:]]* trick mentioned at some places on the internet in order to get a direct path to files, but that does not fix the error. – Frankyie Nov 13 '23 at 20:09
  • Can you access the contents of the pwms listed (read/write as root)? Did you rebuild grub with acpi_enforce_resources=lax in your grub config? I wonder if it's a timing issue at startup. Maybe the module isn't fully loaded when the fancontrol service starts. – rtaft Nov 13 '23 at 20:16
  • I can read for example pwm1 file. I opened it in kate, changed the value and try to store it (password was needed) but could not change the value. I did not modify Grub – Frankyie Nov 13 '23 at 20:23
  • it's not a standard file, editing it by hand is a pain. echo 255 | sudo tee /sys/devices/platform/it87.2608/hwmon2/pwm1 should turn on a fan. You have the interval set to 1 second though, so any change you make will be overwritten immediately. Should be a number 0-255 (0 is off, 255 full speed). Be careful not to leave fans off and watch temps. watch sensors – rtaft Nov 13 '23 at 21:20
  • I changed your code a little bit. 'echo 255 | sudo tee /sys/devices/platform/it87.2608/hwmon/hwmon2/pwm1' Response: Device or resource busy. This was with sudo service fancontrol stop. – Frankyie Nov 14 '23 at 05:56
  • change the interval to 10. With fancontrol off, it reverts to the bios settings which won't let you edit the pwm. – rtaft Nov 14 '23 at 13:09
  • Ok. That helped. I can indeed control all 3 fans with 'echo 255 | sudo tee /sys/devices/platform/it87.2608/hwmon/hwmon2/pwmX'

    I noticed another weird thing. I have another computer which has fancontrol issues. With that computer I switched graphic cards. I did the same with the computer which is causing problems. Could it be that changing the amount of sensors messes a lot more things up?

    – Frankyie Nov 14 '23 at 18:41
  • I don't think so, I have 5 different devices in my sensor output with no issue, the video card is not one of them (not sure why, have to use nvidia-smi). It almost sounds like a timing issue. You could try and add a sleep call to the beginning of /usr/sbin/fancontrol as a test to see if that solves the issue, maybe 10 seconds. – rtaft Nov 14 '23 at 18:59
  • The delay of 10 seconds. That did not solve anything sadly enough My comment about the graphic card was not related on how many pwm channels there are, but purely the switching of hardware that can cause problems. It is weird that my other machine that ran fancontrol for 7 years immediately stops working when I changed the grapic card. I noticed some changes in the path to the sensors, fixed them in fancontrol and got the same errors my current machine has. – Frankyie Nov 14 '23 at 19:14
  • Also interesting that with both machine running pwmconfig does not fix anything. Just causes the same errors once again. – Frankyie Nov 14 '23 at 19:16
  • is it an AMD card? I can't remember if that goes through lm-sensors. I do see that the fancontrol service is dependent on lm-sensors to have started, I'm not sure if that is what initializes the it87 module...if it even is a timing issue. You could alternatively modify fancontrol to just not quit when it hits that error outdated = 0 would do it...but this is a hack to get around whatever the issue really is and would be overwritten the next time fancontrol gets updated. – rtaft Nov 14 '23 at 19:21
  • or even put a loop in there to keep checking if it fails. – rtaft Nov 14 '23 at 19:25
  • The new had a nvidea card which is replaced by antoher nvidea card. So no AMD there. – Frankyie Nov 14 '23 at 19:37

0 Answers0