Bekijk Volledige Versie : GZ: Iemand die LM_Sensors kan instaleren i.c.m Supermicro boards
Wij zijn al een tijdje bezig om lm_sensors werkent te krijgen met onze supermicro moederboarden.
Echter dit wil ons niet lukken, no sensors found.
Verder zou het leuk zijn om ook de temparaturen mee te nemen in onze monitoor software munin.
http://84.243.219.100/munin/localhost/localhost-hddtemp_smartctl.html
Wij gebruiken:
Centos en Fedora
Moederboarden varieeren: P4SCi, P8SCi, P8SCt, PDSMi
Voorkeur gaat uit naar iemand welke ervaring heeft met lm_sensors en de betreffende supermicro boarden.
Ervaring met munin is en pre.
Eventueel zijn wij ook geintreseerd in een scriptje welke bij hoge temparaturen een mail verstuurd.
p.s: wij willen ook een howto naar sucesvolle installtie zodat wij het de volgende keer weer zelf kunnen installeren en instellen.
Eventueel zijn wij ook geintreseerd in een scriptje welke bij hoge temparaturen een mail verstuurd.
#!/bin/bash
## Check the CPU and FANS every 5 minutes, and if its over/under the threshold value email the admin
## Edit this file, so that you can set your own maximum temperature,
## the minimum RPM of the fans, and don't forget to change the email address ;-)
## Save this file into /root/temperatureinfo.sh and then type the following from your ssh/telnet session:
## chown 700 /root/temperatureinfo.sh
## Then open your crontab file and go at the end. (with this command)
## pico -w /etc/crontab
## Then insert a new line in your crontab, with a :
## (copy only from the first *)
## */5 * * * * root /root/temperatureinfo.sh
## This will make the script run every 5 minutes.
## If you change it like : */15 then it will run every ... 15 minutes ...
## Set the variable ...SAFE... to the maximum temp and the minimum RPM you want before an alarm
## (in oC and RPM)
export CPUSAFETEMP=65
export MBSAFETEMP=55
export FAN1SAFE=3000
#export FAN2SAFE=3000
#export FAN3SAFE=3000
## Set who should be emailed when an alarm is generated
export ALERTME="email@domain.nl"
####### You can change the things below here, but they work fine as they are :) #######
####### If you don't have a FAN2,
####### then simply comment the export line 'nowfan 2' with a #
####### and do the same for the 3 'if' lines of the FAN2 test block
export NOWCPUTEMP=`/usr/local/bin/mbmon -I -T 3 -c 1`
export NOWMBTEMP=`/usr/local/bin/mbmon -I -T 1 -c 1`
export NOWFAN1=`/usr/local/bin/mbmon -I -F 1 -c 1`
#export NOWFAN2=`/usr/local/bin/mbmon -I -F 2 -c 1`
#export NOWFAN3=`/usr/local/bin/mbmon -I -F 3 -c 1`
####### CPU TEMP test
if [ `expr $NOWCPUTEMP \> $CPUSAFETEMP` = 1 ] ; then
/usr/bin/printf "Subject: ** CPU temp warning on $HOSTNAME **\n\nThe CPU Temperature on $HOSTNAME has exceeded
$CPUSAFETEMP oC\n\nCheck the fans manually NOW!\n\nCpu Temperature: $NOWCPUTEMP oC\n\n\n
Temperature check\n" | /usr/sbin/sendmail $ALERTME
fi
####### Motherboard TEMP test
if [ `expr $NOWMBTEMP \> $MBSAFETEMP` = 1 ] ; then
/usr/bin/printf "Subject: ** Motherboard temp warning on $HOSTNAME **\n\nThe Motherboard Temperature on $HOSTNAME has
exceeded $MBSAFETEMP oC\n\nCheck the fans manually NOW!\n\nMotherboard Temperature: $NOWMBTEMP oC\n\n\n
Temperature check\n" | /usr/sbin/sendmail $ALERTME
fi
####### Fan1 test
if [ `expr $NOWFAN1 \< $FAN1SAFE` = 1 ] ; then
/usr/bin/printf "Subject: ** FAN1 failure on $HOSTNAME **\n\nThe FAN1 on $HOSTNAME has a failure !!! \n\nCheck the
fans manually NOW!\n\nThe actual FAN1 rotation speed is : $NOWFAN1 RPM\n\n\n Temperature check\n" |
/usr/sbin/sendmail $ALERTME
fi
####### Fan2 test
#
#if [ `expr $NOWFAN2 \< $FAN2SAFE` = 1 ] ; then
# /usr/bin/printf "Subject: ** FAN2 failure on $HOSTNAME **\n\nThe FAN2 on $HOSTNAME has a failure !!! \n\nCheck the
#
#fans manually NOW!\n\nThe actual FAN2 rotation speed is : $NOWFAN2 RPM\n\n\n Temperature check\n" |
#
#/usr/sbin/sendmail $ALERTME
#fi
#
####### Fan3 test
#
#if [ `expr $NOWFAN3 \< $FAN3SAFE` = 1 ] ; then
# /usr/bin/printf "Subject: ** FAN3 failure on $HOSTNAME **\n\nThe FAN3 on $HOSTNAME has a failure !!! \n\nCheck the
#
#fans manually NOW!\n\nThe actual FAN3 rotation speed is : $NOWFAN3 RPM\n\n\n Temperature check\n" |
#
#/usr/sbin/sendmail $ALERTME
#fi
#end of script
Zet dit in een shell scriptje en laat dat met een cron lopen.
Edit: bij meerdere case fans natuurlijk wel even extra regels uncommenten
hrodenburg
19/06/07, 19:59
Hee wat leuk :) Ik kende mbmon nog niet.
Thanx :)