Mercurial > repos > other > usr-local-bin
view load-graph @ 28:278968272584
Add Exif Graphr to backup list
It is its own repo under the main IBBoard website
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Wed, 30 Dec 2020 17:14:21 +0000 |
parents | 2576b5cfb71c |
children | c2584db4a650 |
line wrap: on
line source
#! /bin/bash start="-6h" end="0" if [ $# -eq 1 ] then start=$1 elif [ $# -eq 2 ] then start=$1 end=$2 fi rrdtool graph /tmp/load-percent.png -w 1280 -h 1024 -a PNG --start "$start" --end "$end" \ --vertical-label "Usage (%)" \ DEF:core1=$HOME/.load.rrd:core1:AVERAGE \ DEF:core2=$HOME/.load.rrd:core2:AVERAGE \ DEF:core3=$HOME/.load.rrd:core3:AVERAGE \ DEF:core4=$HOME/.load.rrd:core4:AVERAGE \ DEF:CPU=$HOME/.load.rrd:core_avg:AVERAGE \ DEF:GPU=$HOME/.load.rrd:GPU:AVERAGE \ LINE1:core1#99000030:"Core 1" \ LINE1:core2#99000030:"Core 2" \ LINE1:core3#99000030:"Core 3" \ LINE1:core4#99000030:"Core 4" \ LINE2:CPU#990000:"CPU" \ LINE2:GPU#009900:"GPU" \ && rrdtool graph /tmp/load-type.png -w 1280 -h 1024 -a PNG --start "$start" --end "$end" \ --vertical-label "Usage (%)" \ DEF:user=$HOME/.load.rrd:user:AVERAGE \ DEF:system=$HOME/.load.rrd:system:AVERAGE \ DEF:iowait=$HOME/.load.rrd:iowait:AVERAGE \ AREA:iowait#888888:"I/O Wait" \ STACK:system#6666FF:"System" \ STACK:user#CCCC66:"User" \ && eog /tmp/load-*.png rm -f /tmp/load-*.png