sensors-detect
Detect hardware monitoring chips (sensors)
SYNOPSIS
sensors-detect [options]
PARAMETERS
-h, --help
Displays a brief help message and exits.
-v, --version
Prints the program version and exits.
--auto
Runs in a less interactive mode, answering 'yes' to most common questions, but still prompting for risky probes.
--full-auto
Runs in a fully non-interactive mode, answering 'yes' to all questions, including potentially risky probes. Use with caution in automated scripts.
--quiet
Suppresses all standard output, only displaying error messages.
--force
Overrides certain warnings, such as not being run as root. Not recommended for general use.
DESCRIPTION
sensors-detect is an interactive command-line utility designed to probe your system for hardware monitoring chips supported by the lm-sensors package.
It systematically scans various system buses, including I2C/SMBus, ISA, and others, to identify embedded sensor devices capable of reporting vital system statistics such as CPU temperature, fan speeds, and voltage levels. During its operation, it asks a series of questions to guide the detection process, prompting the user for confirmation before probing potentially sensitive areas.
Upon successful detection, sensors-detect recommends which kernel modules need to be loaded to enable access to these sensors. It often offers to generate a configuration file (e.g., within /etc/modules-load.d/ or /etc/modprobe.d/) to ensure these modules are loaded automatically at boot time, making the sensor data available for tools like sensors(1).
CAVEATS
Running sensors-detect generally requires root privileges for probing hardware and configuring kernel modules. While designed to be safe, some probes involve writing to hardware registers and, in rare cases, could potentially cause system instability or require a reboot if incorrect modules are loaded. Always review the suggested changes before confirming them. The detected modules might need to be loaded manually using modprobe or require a system reboot to become active.
INTERACTIVE NATURE
The command typically runs interactively, prompting the user with 'yes/no' questions about probing different bus types (e.g., I2C/SMBus, ISA, ACPI) and specific chip addresses. This interactive design allows users to control the depth of the scan and avoid potentially risky or time-consuming probes.
KERNEL MODULE MANAGEMENT
After identifying suitable sensor chips, sensors-detect suggests the corresponding kernel modules (e.g., nct6775, coretemp, it87). It usually offers to add these modules to the system's module loading configuration (e.g., /etc/modules-load.d/*.conf or /etc/modprobe.d/*.conf) to ensure they are loaded automatically on subsequent boots. Users can then load them immediately using sudo modprobe module_name.
HISTORY
sensors-detect is a core utility of the lm-sensors project, which has been under continuous development for decades. Its evolution parallels the increasing complexity and diversity of hardware monitoring chips and the Linux kernel's module system. Initially, it was a manual process to identify and load modules; sensors-detect automated this often intricate task, making hardware monitoring accessible to a broader user base.