diff --git a/R710-IPMI-TEMP/R710-IPMIStatic.sh b/R710-IPMI-TEMP/R710-IPMIStatic.sh index 1d450e9..87554c0 100755 --- a/R710-IPMI-TEMP/R710-IPMIStatic.sh +++ b/R710-IPMI-TEMP/R710-IPMIStatic.sh @@ -3,8 +3,9 @@ # ---------------------------------------------------------------------------------- # Script for setting manual fan speed to 2160 RPM (on my R710) # -# Requires ipmitool – apt-get install ipmitool -# Tested on Ubuntu 17.04 +# Requires: +# ipmitool – apt-get install ipmitool +# slacktee.sh – https://github.com/course-hero/slacktee # ---------------------------------------------------------------------------------- @@ -16,6 +17,6 @@ IPMIUSER=root IPMIPW=calvin printf "Activating manual fan speeds! (2160 RPM)" | systemd-cat -t R710-IPMI-TEMP -echo "Activating manual fan speeds! (2160 RPM)" +echo "Activating manual fan speeds! (2160 RPM)" | slacktee.sh -t "R710-IPMI-TEMP [$(hostname)]" ipmitool -I lanplus -H $IPMIHOST -U $IPMIUSER -P $IPMIPW raw 0x30 0x30 0x01 0x00 ipmitool -I lanplus -H $IPMIHOST -U $IPMIUSER -P $IPMIPW raw 0x30 0x30 0x02 0xff 0x09 \ No newline at end of file diff --git a/R710-IPMI-TEMP/R710-IPMITemp.sh b/R710-IPMI-TEMP/R710-IPMITemp.sh index 51a8efd..8e41328 100755 --- a/R710-IPMI-TEMP/R710-IPMITemp.sh +++ b/R710-IPMI-TEMP/R710-IPMITemp.sh @@ -1,11 +1,12 @@ -#!/usr/bin/env bash +#!/bin/bash # ---------------------------------------------------------------------------------- -# Script for checking the temperature reported by the ambient temperature sensor, +# Script for checking the temperature reported by the ambient temperature sensor, # and if deemed to high send the raw IPMI command to enable dynamic fan control. # -# Requires ipmitool – apt-get install ipmitool -# Tested on Ubuntu 17.04 +# Requires: +# ipmitool – apt-get install ipmitool +# slacktee.sh – https://github.com/course-hero/slacktee # ---------------------------------------------------------------------------------- @@ -17,7 +18,7 @@ IPMIUSER=root IPMIPW=calvin # TEMPERATURE -# Change this to the temperature in celcius you are comfortable with. +# Change this to the temperature in celcius you are comfortable with. # If the temperature goes above the set degrees it will send raw IPMI command to enable dynamic fan control MAXTEMP=27 @@ -28,8 +29,8 @@ TEMP=$(ipmitool -I lanplus -H $IPMIHOST -U $IPMIUSER -P $IPMIPW sdr type tempera if [[ $TEMP > $MAXTEMP ]]; then - printf "Temperature is too high! Activating dynamic fan control! ($TEMP C)" | systemd-cat -t R710-IPMI-TEMP - echo "Temperature is too high! Activating dynamic fan control! ($TEMP C)" + printf "Warning: Temperature is too high! Activating dynamic fan control! ($TEMP C)" | systemd-cat -t R710-IPMI-TEMP + echo "Warning: Temperature is too high! Activating dynamic fan control! ($TEMP C)" | /usr/bin/slacktee.sh -t "R710-IPMI-TEMP [$(hostname)]" ipmitool -I lanplus -H $IPMIHOST -U $IPMIUSER -P $IPMIPW raw 0x30 0x30 0x01 0x01 else # healthchecks.io diff --git a/R710-IPMI-TEMP/readme.md b/R710-IPMI-TEMP/readme.md old mode 100644 new mode 100755 index 5f8b1e3..18b955d --- a/R710-IPMI-TEMP/readme.md +++ b/R710-IPMI-TEMP/readme.md @@ -9,6 +9,9 @@ I run the script via CRON every 5 minutes from my Ubuntu Server VM running on ES Notice thate I use [healthchecks.io](https://healthchecks.io) in the script to notify if the temp goes to high (it would also trigger if the internet goes down for some reason). Remember to get your own check URL if you want it, or else just remove the curl command. +I'm also currently testing out [slacktee.sh](https://github.com/course-hero/slacktee) to get notifications in my slack channel. + + The Scripts [Reddit thread](https://www.reddit.com/r/homelab/comments/779cha/manual_fan_control_on_r610r710_including_script/) *****