风扇控制无法启动-硬件配置已更改(无需重启)

风扇控制无法启动-硬件配置已更改(无需重启)

我已经fancontrol安装好了,运行后立即pwmconfig收到一条Configuration appears to be outdated, please run pwmconfig again消息。

这是一台旧的戴尔电脑 (i5-2320),我在上面安装了 Ubuntu 16.04。一些输出:

$ sensors
coretemp-isa-0000  
Adapter: ISA adapter  
Physical id 0:  +35.0°C  (high = +80.0°C, crit = +99.0°C)  
Core 0:         +35.0°C  (high = +80.0°C, crit = +99.0°C)  
Core 1:         +26.0°C  (high = +80.0°C, crit = +99.0°C)  
Core 2:         +33.0°C  (high = +80.0°C, crit = +99.0°C)  
Core 3:         +31.0°C  (high = +80.0°C, crit = +99.0°C)  

dell_smm-virtual-0  
Adapter: Virtual device  
Processor Fan:   3193 RPM  
Motherboard Fan:    0 RPM  

$ sudo find /sys -name hwmon
/sys/devices/virtual/hwmon  
/sys/devices/platform/coretemp.0/hwmon  
/sys/class/hwmon  

$ sudo pwmconfig 
#pwmconfig revision 6243 (2014-03-20)
This program will search your sensors for pulse width modulation (pwm)
controls, and test each one to see if it controls a fan on
your motherboard. Note that many motherboards do not have pwm
circuitry installed, even if your sensor chip supports pwm.

We will attempt to briefly stop each fan using the pwm controls.
The program will attempt to restore each fan to full speed
after testing. However, it is ** very important ** that you
physically verify that the fans have been to full speed
after the program has completed.

Found the following devices:  
   hwmon0 is coretemp  
   hwmon1 is dell_smm  

Found the following PWM controls:  
   hwmon1/pwm1           current value: 255  
   hwmon1/pwm2           current value: 255  

Giving the fans some time to reach full speed...  
Found the following fan sensors:  
   hwmon1/fan1_input     current speed: 3191 RPM  
   hwmon1/fan2_input     current speed: 0 ... skipping!  

Warning!!! This program will stop your fans, one at a time,
for approximately 5 seconds each!!!
This may cause your processor temperature to rise!!!
If you do not want to do this hit control-C now!!!
Hit return to continue: 

Testing pwm control hwmon1/pwm1 ...  
  hwmon1/fan1_input ... speed was 3191 now 997  
    It appears that fan hwmon1/fan1_input  
    is controlled by pwm hwmon1/pwm1  
Would you like to generate a detailed correlation (y)? n  

Testing pwm control hwmon1/pwm2 ...  
  hwmon1/fan1_input ... speed was 3191 now 3202  
    no correlation  

No correlations were detected.
There is either no fan connected to the output of hwmon1/pwm2,
or the connected fan has no rpm-signal connected to one of
the tested fan sensors. (Note: not all motherboards have
the pwm outputs connected to the fan connectors,
check out the hardware database on http://www.almico.com/forumindex.php)

Did you see/hear a fan stopping during the above test (n)? n

Testing is complete.
Please verify that all fans have returned to their normal speed.

The fancontrol script can automatically respond to temperature changes
of your system by changing fanspeeds.
Do you want to set up its configuration file now (y)? n

$ more /etc/fancontrol  
# Configuration file generated by pwmconfig, changes will be lost  
INTERVAL=10  
DEVPATH=hwmon0=devices/platform/coretemp.0 hwmon1=*devices/virtual*  
DEVNAME=hwmon0=coretemp hwmon1=dell_smm  
FCTEMPS=hwmon1/pwm1=hwmon0/temp1_input  
FCFANS=hwmon1/pwm1=hwmon1/fan1_input  
MINTEMP=hwmon1/pwm1=30  
MAXTEMP=hwmon1/pwm1=60  
MINSTART=hwmon1/pwm1=150  
MINSTOP=hwmon1/pwm1=0  
MAXPWM= hwmon1/pwm1=255  

我一开始使用autogen配置,但无法启动时,我fancontrol做了几件事 - 删除了所有引用,pwm2因为我只有一个试图控制的 CPU 风扇......我hwmon1自己添加了后面的值(斜体),因为之前那里什么都没有。即使我在运行风扇控制时接受这些值,我也会得到

$ sudo fancontrol
Loading configuration from /etc/fancontrol ...  

Common settings:  
  INTERVAL=10  

Settings for hwmon1/pwm1:  
  Depends on hwmon0/temp1_input  
  Controls hwmon1/fan1_input  
  MINTEMP=30  
  MAXTEMP=60  
  MINSTART=150  
  MINSTOP=0  
  MINPWM=0  
  MAXPWM=255  

Device path of hwmon1 has changed  
Configuration appears to be outdated, please run pwmconfig again  

奇怪的是, 中的详细关联pwmconfig会改变风扇速度,因此看起来它应该具有所需的一切……但我仍然必须输入值DEVPATHhwmon1看起来它应该将DEVPATH值与某些东西进行比较,但我不知道是什么。 同样,这个问题都在同一个会话中,我还没有重新启动。 有什么想法吗?

答案1

设备位于/sys/devices/platform/。您实际上不需要 DEVPATH,如果 hwmon 编号发生变化,则可以输入带有通配符的完整路径。

找到每个设备的位置/sys/devices/platform/<kernel_module>/hwmon/<hwmon#>

手动编辑/etc/fancontrol

移除DEVPATHDEVNAME

将每个条目替换为完整路径/sys/devices/platform/<kernel_module>/hwmon/hwmon[[:print:]]*

=hwmon0/temp1_input将会变成=/sys/devices/platform/coretemp.0/hwmon/hwmon[[:print:]]*,你只需要获取所有 hwmon1 条目的路径并替换它。

一旦它正常工作,请备份配置,以防它被覆盖或您更新操作系统。这里有一个线程,其中包含一些有关手动配置 fancontrol 的帮助:无法使用 pwmconfig 配置风扇速度!

相关内容