-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
switch from hddtemp to smartmontools
hddtemp is used to monitor the hard disks temperature. This package is dormant and is not available on debian12. It is recommended to use smartmontools instead. This commit creates the snmp endpoint to retrieve the hard drive temperatures using Smartmontools, and remove the hddtemp deployment code from the playbooks. Signed-off-by: Florent CARLI <florent.carli@rte-france.com>
- Loading branch information
1 parent
e8e7bf2
commit 270b1b3
Showing
4 changed files
with
11 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/usr/bin/env bash | ||
|
||
/usr/sbin/smartctl --scan | awk '{ print $1 }' | while read i; do | ||
temp=$(/usr/sbin/smartctl -a $i | grep Temperature_Celsius | awk '{ print $10 }') | ||
if [ ! -z "$temp" ] | ||
then | ||
echo "$i;$temp" | ||
fi | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters