|
NAMErtgplot - generate plots of RTG dataSYNOPSISrtgplot -h[elp]rtgplot -t tablename(s) -i interface(s) [options] begin end rtgplot.cgi ?t1=tablename &t1_name=descname &t2=tablename &t2_name=descname &iid=interface &begin=unixtime &end=unixtime &[options] DESCRIPTIONrtgplot generates traffic plots of RTG data in PNG format. It operates in two modes: either taking command line arguments or parsing stdin from a web page CGI. An RTG plot can be embedded in any HTML page simply with an IMG tag and appropriate arguments. Unless otherwise specified, it outputs the PNG plot to stdout. rtgplot minimally requires MySQL table name, MySQL interface id and UNIX epoch start and end arguments. In addition, there are several optional arguments that modify the plot appearance or logic.OPTIONS
EXAMPLESExample HTML IMG TAG:<img src="rtgplot.cgi? t1=ifInOctets_2& t1_name=Input& t2=ifOutOctets_2& t2_name=Output& iid=4& begin=1046754000& end=1046840399& units=bits/s& factor=8& scalex=yes& title=Bandwidth+Graph" /> will plot two lines from the MySQL tables ifInOctets_2 and ifOutOctets_2 corresponding to interface 4 on router 2 for the time span 1046754000 to 1046840399 (UNIX epoch seconds). The factor argument allows for bits per second; the units argument is displayed as the Y-axis label on the plot. The scalex argument auto-adjusts the X time axis according to the available data samples rather than according to the actual time span given. It will have a graph title of "Bandwidth Graph" and legend tags of "Input" and "Output" for t1 and t2 respectively. Draw a 95th percentile line: <IMG SRC="rtgplot.cgi? t1=ifInOctets_2& t2=ifOutOctets_2& iid=4& begin=1046754000& end=1046840399& units=bits/s& factor=8& percentile=95> percentile=95> Draw input and output bits per second for three different interfaces on the same plot. Enlarge the plot bottom border to fit extra legends: <IMG SRC="rtgplot.cgi? t1=ifInOctets_2& t2=ifOutOctets_2& iid=4& iid=5& iid=7& xplot=500& yplot=150& borderb=150& begin=1046754000& end=1046840399& units=bits/s& factor=8> As last example, but aggregate input and output bits per second for the three different interfaces. <IMG SRC="rtgplot.cgi? t1=ifInOctets_2& t2=ifOutOctets_2& iid=4& iid=5& iid=7& begin=1046754000& end=1046840399& units=bits/s& factor=8& aggr=yes> SEE ALSOrtgpoll(1)VERSIONThis manual page documents rtgplot version 0.7.5AUTHOR(c) 2002-2003 by Robert Beverly
Visit the GSP FreeBSD Man Page Interface. |