microsoft / microsoft/WSL

"sensors-detect" from lm-sensors package detects no sensors

Open
#12,259 4 comments 0 reactions 0 assignees View on GitHub
feature kernel
Dominant language
C++
Stars
33.7k
Forks
1.8k
Avg merge
3d 17h
Merged PRs (30d)
116

Description

### Windows Version

Microsoft Windows [Version 10.0.19045.5011]

### WSL Version

WSL version: 2.3.24.0

### Are you using WSL 1 or WSL 2?

- [x] WSL 2
- [ ] WSL 1

### Kernel Version

Linux version 5.15.153.1-microsoft-standard-WSL2 (root@941d701f84f1) (gcc (GCC) 11.2.0, GNU ld (GNU Binutils) 2.37) #1 SMP Fri Mar 29 23:14:13 UTC 2024

### Distro Version

Release: 22.04

### Other Software

lm-sensors
sensors
sensors-detect

### Repro Steps

sudo apt install lm-sensors
sensors
sensors-detect

### Expected Behavior

sensors should return a listing containing sensors available to the kernel and their current value
sensors-detect should probe for embedded sensors and tell you what is available

### Actual Behavior

```
BASH:Phydeaux:ROOT:5:/mnt/c/ReallyTempEmptyEveryDay> sensors
No sensors found!
Make sure you loaded all the kernel drivers you need.
Try sensors-detect to find out which these are.
BASH:Phydeaux:ROOT:6:/mnt/c/ReallyTempEmptyEveryDay> sensors-detect
# sensors-detect version 3.6.0
# Kernel: 5.15.153.1-microsoft-standard-WSL2 x86_64
# Processor: AMD Ryzen 7 2700 Eight-Core Processor (23/8/2)

This program will help you determine which kernel modules you need
to load to use lm_sensors most effectively. It is generally safe
and recommended to accept the default answers to all questions,
unless you know what you're doing.

Some south bridges, CPUs or memory controllers contain embedded sensors.
Do you want to scan for them? This is totally safe. (YES/no):
modprobe: FATAL: Module cpuid not found in directory /lib/modules/5.15.153.1-microsoft-standard-WSL2
Failed to load module cpuid.
Silicon Integrated Systems SIS5595... No
VIA VT82C686 Integrated Sensors... No
VIA VT8231 Integrated Sensors... No
AMD K8 thermal sensors... No
AMD Family 10h thermal sensors... No
AMD Family 11h thermal sensors... No
AMD Family 12h and 14h thermal sensors... No
AMD Family 15h thermal sensors... No
AMD Family 16h thermal sensors... No
AMD Family 17h thermal sensors... No
AMD Family 15h power sensors... No
AMD Family 16h power sensors... No
Hygon Family 18h thermal sensors... No
Intel digital thermal sensor... No
Intel AMB FB-DIMM thermal sensor... No
Intel 5500/5520/X58 thermal sensor... No
VIA C7 thermal sensor... No
VIA Nano thermal sensor... No

Some Super I/O chips contain embedded sensors. We have to write to
standard I/O ports to probe them. This is usually safe.
Do you want to scan for Super I/O sensors? (YES/no):
/dev/port: No such file or directory

Some systems (mainly servers) implement IPMI, a set of common interfaces
through which system health data may be retrieved, amongst other things.
We first try to get the information from SMBIOS. If we don't find it
there, we have to read from arbitrary I/O ports to probe for such
interfaces. This is normally safe. Do you want to scan for IPMI
interfaces? (YES/no):
/dev/port: No such file or directory

Some hardware monitoring chips are accessible through the ISA I/O ports.
We have to write to arbitrary I/O ports to probe them. This is usually
safe though. Yes, you do have ISA I/O ports even if you do not have any
ISA slots! Do you want to scan the ISA I/O ports? (YES/no):
/dev/port: No such file or directory

Lastly, we can probe the I2C/SMBus adapters for connected hardware
monitoring devices. This is the most risky part, and while it works
reasonably well on most systems, it has been reported to cause trouble
on some systems.
Do you want to probe the I2C/SMBus adapters now? (YES/no):
Sorry, no supported PCI bus adapters found.
modprobe: FATAL: Module i2c-dev not found in directory /lib/modules/5.15.153.1-microsoft-standard-WSL2
Failed to load module i2c-dev.

Sorry, no sensors were detected.
Either your system has no sensors, or they are not supported, or
they are connected to an I2C or SMBus adapter that is not
supported. If you find out what chips are on your board, check
https://hwmon.wiki.kernel.org/device_support_status for driver status.
```

### Diagnostic Logs

_No response_

Contributor guide

Open the contributing guide

Research direction

Start with the reported WSL2 kernel and reproduce the `sensors` and `sensors-detect` commands. Investigate the missing `cpuid` and `i2c-dev` modules, `/dev/port` errors, and unavailable PCI/SMBus paths. Done means confirming whether this is a WSL2 hardware-monitoring limitation or a WSL defect, with the supported scope clearly identified.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux, ubuntu
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.