sensors:No sensors found!Make sure you loaded all the kernel drivers you need.Try sensors-detect to
程序员文章站
2024-02-21 09:54:04
...
执行sensors命令:
~# sensors
No sensors found!
Make sure you loaded all the kernel drivers you need.
Try sensors-detect to find out which these are.
记修复过程
1. 保证systemd-modules-load.service和kmod.service,注释/etc/modules文件中 coretemp 和nct6775
~# cat /etc/modules
# /etc/modules: kernel modules to load at boot time.
#
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.
# Generated by sensors-detect on Tue Mar 31 14:28:01 2020
# Chip drivers
#coretemp
#nct6775
~# systemctl status systemd-modules-load.service
● systemd-modules-load.service - Load Kernel Modules
Loaded: loaded (/lib/systemd/system/systemd-modules-load.service; static; vendor preset: enabled)
Active: active (exited) since 二 2020-03-31 15:13:43 CST; 9s ago
Docs: man:systemd-modules-load.service(8)
man:modules-load.d(5)
Process: 4811 ExecStart=/lib/systemd/systemd-modules-load (code=exited, status=0/SUCCESS)
Main PID: 4811 (code=exited, status=0/SUCCESS)
3月 31 15:13:43 tesra44 systemd[1]: Starting Load Kernel Modules...
3月 31 15:13:43 tesra44 systemd[1]: Started Load Kernel Modules.
[email protected]:~# systemctl status kmod
kmod.service kmod-static-nodes.service
~# systemctl status kmod.service
● systemd-modules-load.service - Load Kernel Modules
Loaded: loaded (/lib/systemd/system/systemd-modules-load.service; static; vendor preset: enabled)
Active: active (exited) since 二 2020-03-31 15:13:43 CST; 19s ago
Docs: man:systemd-modules-load.service(8)
man:modules-load.d(5)
Process: 4811 ExecStart=/lib/systemd/systemd-modules-load (code=exited, status=0/SUCCESS)
Main PID: 4811 (code=exited, status=0/SUCCESS)
3月 31 15:13:43 tesra44 systemd[1]: Starting Load Kernel Modules...
3月 31 15:13:43 tesra44 systemd[1]: Started Load Kernel Modules.
2. 查找模块coretemp.ko,如果本机没有,就需要从其它机子拷贝过来
~# find /lib/modules/4.15.0-91-generic/kernel/drivers/ -name coretemp.ko
/lib/modules/4.15.0-91-generic/kernel/drivers/hwmon/coretemp.ko
3. 向内核加载模块coretemp.ko
~# insmod /lib/modules/4.15.0-91-generic/kernel/drivers/hwmon/coretemp.ko
4.再次执行命令
~# sensors
coretemp-isa-0000
Adapter: ISA adapter
Package id 0: +40.0°C (high = +86.0°C, crit = +96.0°C)
Core 0: +35.0°C (high = +86.0°C, crit = +96.0°C)
Core 1: +32.0°C (high = +86.0°C, crit = +96.0°C)
Core 2: +31.0°C (high = +86.0°C, crit = +96.0°C)
Core 3: +34.0°C (high = +86.0°C, crit = +96.0°C)
上一篇: Nginx 多server配置
下一篇: ES2016指南