#!/usr/bin/rrdcgi <RRD::GOODFOR -600>
<RRD::INCLUDE nav.inc.html>

## system statistics

<RRD::GRAPH ../rrd-img/sys-mem-day.png --imginfo '<IMG SRC=/rrd-img/%s WIDTH=%lu HEIGHT=%lu >' --lazy -i -a PNG --title="Memory Usage (Day)" -v Byte --base 1000 -l -0 -u 64000000 --rigid DEF:used=/var/lib/rrd/system.rrd:mem-used:AVERAGE DEF:free=/var/lib/rrd/system.rrd:mem-free:AVERAGE DEF:cache=/var/lib/rrd/system.rrd:mem-cache:AVERAGE AREA:used#1111FF:Used GPRINT:used:MIN:" Min\: %3.1lf%s " GPRINT:used:MAX:" Max\: %3.1lf%S" GPRINT:used:AVERAGE:" Avg\: %3.1lf%S" GPRINT:used:LAST:" Current\: %3.1lf%SByte\n" STACK:free#00FF00:Free GPRINT:free:MIN:" Min\: %3.1lf%S" GPRINT:free:MAX:" Max\: %3.1lf%S" GPRINT:free:AVERAGE:" Avg\: %3.1lf%S" GPRINT:free:LAST:" Current\: %3.1lf%SByte\n" LINE2:cache#000000:Cached GPRINT:cache:MIN:" Min\: %3.1lf%s " GPRINT:cache:MAX:" Max\: %3.1lf%S" GPRINT:cache:AVERAGE:" Avg\: %3.1lf%S" GPRINT:cache:LAST:" Current\: %3.1lf%SByte\n">

<RRD::GRAPH ../rrd-img/sys-mem-week.png --imginfo '<IMG SRC=/rrd-img/%s WIDTH=%lu HEIGHT=%lu >' --lazy -i -a PNG --title="Memory Usage (Week)" -v Byte --base 1000 -l -0 -u 64000000 --rigid -s -1week DEF:used=/var/lib/rrd/system.rrd:mem-used:AVERAGE DEF:free=/var/lib/rrd/system.rrd:mem-free:AVERAGE DEF:cache=/var/lib/rrd/system.rrd:mem-cache:AVERAGE AREA:used#1111FF:Used GPRINT:used:MIN:" Min\: %3.1lf%s " GPRINT:used:MAX:" Max\: %3.1lf%S" GPRINT:used:AVERAGE:" Avg\: %3.1lf%S" GPRINT:used:LAST:" Current\: %3.1lf%SByte\n" STACK:free#00FF00:Free GPRINT:free:MIN:" Min\: %3.1lf%S" GPRINT:free:MAX:" Max\: %3.1lf%S" GPRINT:free:AVERAGE:" Avg\: %3.1lf%S" GPRINT:free:LAST:" Current\: %3.1lf%SByte\n" LINE2:cache#000000:Cached GPRINT:cache:MIN:" Min\: %3.1lf%s " GPRINT:cache:MAX:" Max\: %3.1lf%S" GPRINT:cache:AVERAGE:" Avg\: %3.1lf%S" GPRINT:cache:LAST:" Current\: %3.1lf%SByte\n">

<RRD::GRAPH ../rrd-img/sys-mem-month.png --imginfo '<IMG SRC=/rrd-img/%s WIDTH=%lu HEIGHT=%lu >' --lazy -i -a PNG --title="Memory Usage (Month)" -v Byte --base 1000 -l -0 -u 64000000 --rigid -s -1month DEF:used=/var/lib/rrd/system.rrd:mem-used:AVERAGE DEF:free=/var/lib/rrd/system.rrd:mem-free:AVERAGE DEF:cache=/var/lib/rrd/system.rrd:mem-cache:AVERAGE AREA:used#1111FF:Used GPRINT:used:MIN:" Min\: %3.1lf%s " GPRINT:used:MAX:" Max\: %3.1lf%S" GPRINT:used:AVERAGE:" Avg\: %3.1lf%S" GPRINT:used:LAST:" Current\: %3.1lf%SByte\n" STACK:free#00FF00:Free GPRINT:free:MIN:" Min\: %3.1lf%S" GPRINT:free:MAX:" Max\: %3.1lf%S" GPRINT:free:AVERAGE:" Avg\: %3.1lf%S" GPRINT:free:LAST:" Current\: %3.1lf%SByte\n" LINE2:cache#000000:Cached GPRINT:cache:MIN:" Min\: %3.1lf%s " GPRINT:cache:MAX:" Max\: %3.1lf%S" GPRINT:cache:AVERAGE:" Avg\: %3.1lf%S" GPRINT:cache:LAST:" Current\: %3.1lf%SByte\n">

<RRD::GRAPH ../rrd-img/sys-mem-year.png --imginfo '<IMG SRC=/rrd-img/%s WIDTH=%lu HEIGHT=%lu >' --lazy -i -a PNG --title="Memory Usage (Year)" -v Byte --base 1000 -l -0 -u 64000000 --rigid -s -1year DEF:used=/var/lib/rrd/system.rrd:mem-used:AVERAGE DEF:free=/var/lib/rrd/system.rrd:mem-free:AVERAGE DEF:cache=/var/lib/rrd/system.rrd:mem-cache:AVERAGE AREA:used#1111FF:Used GPRINT:used:MIN:" Min\: %3.1lf%s " GPRINT:used:MAX:" Max\: %3.1lf%S" GPRINT:used:AVERAGE:" Avg\: %3.1lf%S" GPRINT:used:LAST:" Current\: %3.1lf%SByte\n" STACK:free#00FF00:Free GPRINT:free:MIN:" Min\: %3.1lf%S" GPRINT:free:MAX:" Max\: %3.1lf%S" GPRINT:free:AVERAGE:" Avg\: %3.1lf%S" GPRINT:free:LAST:" Current\: %3.1lf%SByte\n" LINE2:cache#000000:Cached GPRINT:cache:MIN:" Min\: %3.1lf%s " GPRINT:cache:MAX:" Max\: %3.1lf%S" GPRINT:cache:AVERAGE:" Avg\: %3.1lf%S" GPRINT:cache:LAST:" Current\: %3.1lf%SByte\n">