hddtemp is a small utility (with daemon) that gives the hard-drive temperature via S.M.A.R.T. (for drives supporting this feature).
Install hddtemp from the official repositories.
Note: Block device naming under /dev/, like /dev/sdX, is inconsistent. See Persistent block device naming for information on using persistent device paths.
Running the daemon allows access to the temperature information via TCP/IP as a regular user. This is useful for scripts and system monitors.
The daemon is controlled by hddtemp.service.
To get the temperature, connect to the daemon which listens on port 7634.
The default hddtemp daemon only monitors /dev/sda. If you have multiple disks, you need to override the default configuration to monitor them.
You will need to know which hard drives support monitoring. You can check with smartmontools.
Change the device names to the ones you want to monitor.
You can also use the auto-generate script will detect supported hard drives using smartmontools and print to the stdout.
Hddtemp can be integrated with system monitors. Conky has built in support for hddtemp in daemon mode. You just need to add $hddtemp °C to your conky configuration file.
where X is a character (e.g. a,b,c...) representing the drive. Use lsblk to check this.
This page was last edited on 5 March 2019, at 14:23.
Content is available under GNU Free Documentation License 1.3 or later unless otherwise noted.
