Initial commit
This commit is contained in:
commit
529efd53a1
140 changed files with 10310 additions and 0 deletions
46
rrdtools/scripts/old/temp-hd.sh.old
Executable file
46
rrdtools/scripts/old/temp-hd.sh.old
Executable file
|
|
@ -0,0 +1,46 @@
|
|||
#!/bin/sh
|
||||
|
||||
BASEDIR=`pwd`
|
||||
. ${BASEDIR%scripts}/rrdtool.conf
|
||||
|
||||
FILE="temp-hd"
|
||||
DBASE="${DBASEDIR}/${FILE}.rrd"
|
||||
IMG="${IMGDIR}/${FILE}.png"
|
||||
SIMG="${IMGDIR}/small-${FILE}.png"
|
||||
|
||||
if [ ! -f "${DBASE}" ]; then
|
||||
|
||||
${RRD} create ${DBASE} \
|
||||
--start N \
|
||||
--step 300 \
|
||||
DS:temp_hd:GAUGE:600:U:U \
|
||||
RRA:AVERAGE:0.5:1:288
|
||||
fi
|
||||
|
||||
${RRD} update ${DBASE} N:`smartctl -a /dev/ad0 | grep Temperature_Celsius | cut -c 88-89`
|
||||
|
||||
${RRD} graph ${IMG} \
|
||||
--imgformat=PNG \
|
||||
--title="HD Temperature" \
|
||||
--font LEGEND:7 \
|
||||
--rigid \
|
||||
--base=1000 \
|
||||
--height=100 \
|
||||
--width=400 \
|
||||
--upper-limit=100 \
|
||||
--tabwidth=20 \
|
||||
--lower-limit=0 \
|
||||
--vertical-label="celsius" \
|
||||
DEF:temp="${DBASE}":temp_hd:AVERAGE \
|
||||
AREA:temp#00CF00:"TEMP\t" GPRINT:temp:LAST:"Last\:%4.0lf %s" GPRINT:temp:AVERAGE:"Avg\:%4.0lf %s" GPRINT:temp:MAX:"Max\:%4.0lf %s"
|
||||
|
||||
${RRD} graph ${SIMG} \
|
||||
--imgformat=PNG \
|
||||
--font DEFAULT:5 \
|
||||
--height=50 \
|
||||
--width=200 \
|
||||
--tabwidth=20 \
|
||||
--lower-limit=0 \
|
||||
--no-legend \
|
||||
DEF:temp="${DBASE}":temp_hd:AVERAGE \
|
||||
AREA:temp#00CF00:
|
||||
Loading…
Add table
Add a link
Reference in a new issue