# Set base temp if we got nothing in stdout, this mean we are asleep Temperature=$(hddtemp -n /dev/sdc 2>/dev/null) This has been stable for me: FILE=/tmp/Hddtemp I found Mathew Wai's answer really good, but I ran into some issues with drives sleeping and temperature data corruption. Note that "HDD_temp" and "Hddtemp" are the script file and output file respectively. Then, the fan controlled by “ hwmon1/pwm1” will respond to “ /Fancontrol/Hddtemp”, the hard disk temperature. Save the file and run the following command to restart Fancontrol. Replace it with “ /Fancontrol/Hddtemp”, and the line will become: the chipset temperature) currently read by Fancontrol. On that line, “ hwmon1/temp1_input” is the temperature (e.g. (7) Run the following command to edit “ fancontrol”, the configuration file.įind the line that begins with “ FCTEMPS”. Then, the script “ HDD_temp” will be run as a system service at Linux startup. Sudo chmod 664 /lib/systemd/system/HDD_rvice (6) Run the following commands one by one: (5) Copy the following lines into the file and save it. (4) Run the following command to create a service file. (3) Run the following command to make it executable. (2) Copy the following script into the file and save it. Sudo mkdir -p "/Fancontrol/" & sudo xed /Fancontrol/HDD_temp (1) Run the following command to create a script file. If you have not yet configured Fancontrol, see this page, this page, and this page and run the following commands one by one (restart Linux after running the first one): Replace “ /dev/sda” with the correct one in the script if necessary. Use only the one supported by Hddtemp, which will display the temperature rather than “S.M.A.R.T. Press Ctrl + Alt + T to open Terminal and run the following command to check whether “ /dev/sda” is the correct one: In the following script, “ /dev/sda” is the hard disk to be monitored, and “ /Fancontrol/Hddtemp” is the output file to be read by Fancontrol. I finally found a simple script to control fan speed according to hard drive temperature via Fancontrol, Hddtemp, and Lm-sensors.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |