Title: Dimke Hddetemp
Explanation: To not risk damage to your harddrives, you may wish to monitor their temperature values to be on the safe side. For this purpose you probably have hddtemp in use, which does a quite good job. Except: Hddtemp can only handle internal drives, though the hddtemp developers claim that they are using the S.M.A.R.T. values, which are processed and passed through most of the USB-to-SATA-controllers out there in these days. So, this is obviously not completely true, but, instead they most likely use some own and buggy routines for getting the values out of the drives. In the field, this is not a solution at all.
So, I decided to create an own version, relying closer on the original S.M.A.R.T. routines, and processing the data received. Hence, Dimke Hddetemp, indeed, can handle internal and external harddisks.
How it works: Hddetemp, standing for Hdd external temperature, is a Linux Bash script, which calls smartctl out of a package called Smartmontools, and processes the data coming back from the drives.

Smartmontools has to be installed, of course.

Since smartctl needs root rights, you have a few options:
1. You use the script as is and let it invoke smartctl via sudo.
So, it would be best, to create a line in /etc/sudoers for a certain person or group, to invoke sudo smartctl without the need to type the password every time. You need a line similar to:
%wheel ALL=(root) NOPASSWD:/usr/sbin/smartctl
which is group-based for everyone belonging to group wheel, or
admin ALL=(root) NOPASSWD:/usr/sbin/smartctl
which is user-based for a user called admin.

2. You run the whole script hddetemp as user root.
In this case you can even remove the sudo statement, but it is not good style, and I really do not recommend this way.

3. You use policy kit and set up a rule for hddetemp. But, since polkit has shocked the whole Linux community several times having severy bugs, this is also far from perfect.
Better use 1.
How to use: First, download the archive linked below and unpack hddetemp into /bin.
Verify, that the rights are correct: root:root, 0755.

Then, create the needed line in /etc/sudoers, as described above.

Now you're done, and hddetemp is ready to use.

Usage is very similar to usage known from hddtemp. You can invoke hddetemp with --help or -h to get some hints, or you can tell hddetemp which drive to check.
Or, without any parameters, hddetemp shows every drive it finds. Internal and external disks.
Download package: hddetemp.tgz
[Developer Root] [Main Page]