- Cacti Beginner's Guide(Second Edition)
- Thomas Urban
- 121字
- 2021-07-02 20:15:33
Back to the basics - rrdtool graph command
Let's look at the rrdtool graph command that Cacti uses to create this graph:
/bin/rrdtool graph - --imgformat=PNG --start='-180000' --end='-300' --pango-markup --title='Local Linux Machine - Running Processes' --vertical-label='processes' --slope-mode --base=1000 --height=150 --width=500 --alt-autoscale-max --lower-limit='0' --border 1 --slope-mode --watermark 'Copyright (C) 2004-2017 The Cacti Group' DEF:a='/var/www/html/cacti/rra/local_linux_machine_runprocesses_21.rrd':'runProcesses':AVERAGE CDEF:cdefc='a,435,470,LIMIT' CDEF:cdefd='a,0,434,LIMIT' HRULE:470#E5E4E2FF:'Threshold (470) n' AREA:a#FF6044FF:'Over Threshold ' AREA:cdefc#FFFF00FF:'Near Threshold ' AREA:cdefd#8AFB17FF:'Under Thresholdn' COMMENT:'Running Processes ' GPRINT:a:LAST:'Cur:%8.2lf %s' GPRINT:a:AVERAGE:'Avg:%8.2lf %s' GPRINT:a:MAX:'Max:%8.2lf %sn'
Doesn't this one look familiar? It's almost the same command that you hopefully came up with in the Have a go hero challenge of Chapter 2, Using Graphs to Monitor Networks and Devices. Here you can see the tight integration of the rrdtool with the web interface of Cacti.