# /etc/netdraw.conf -- 2007-12-17 -- last edit 2009-10-02
#
# configuration for the netdraw network interface monitor suite.
#
# Copyright (C) 2007 Grant Coady GPLv2
#
# this file's location is hard coded into netsample, netdraw, netdrawcopy
#
# Rules: Comment and blank lines okay, comments start with '#' and go
# to the end-of-line, variables take the form of key / value pairs,
# each being one string, where blanks may be part of the value,
# substitute underscores '_' instead
#
# bash scripts can use awk to read a configuration variable:
# CONF="/etc/netdraw.conf"
# SOMEVALUE=$(awk '$1=="somekey"{print $2}' $CONF)
#
codepath /usr/local/bin # where the scripts found
datapath /home/grant/netdraw # where to keep the sample data
htmlpath /home/web/bugsplatter/netdraw # where to write html and images
#
# data capture -- netsample
#
# Note that the capture rate is set by root's crontab entry, see
# http://bugsplatter.mine.nu/system/crontab for details
#
interface ppp0 # which interface to monitor
datafile sampledata
#
# netdraw related -- create fly script for image
#
# Note that chart is hard coded to 288 samples being 24 hours at
# rate of one sample per 300 seconds, next two settings are the
# chart image size for html generation, do not change unless you
# have also changed the netdraw script's hard-coded sizes
dayimgsizex 320
dayimgsizey 132
sampletime 300 # mostly hard-coded in scripts
sumimgsizey 80
#
# define data rate scale in bytes per second for chart, enable auto-scale
# by setting 0 to use all samples to calculate the scale (recommended),
# or -1 to use only the displayed data to calculate the chart scale, or
# set a fullscale value -- if the set fullscale value is below the data
# values, the data will be clipped to fit into the chart area
#fullscale 0
fullscale 64000 # -1, 0, or, for example: 60000
#
# define colour scheme, comma separated R,G,B 0-255 values
col_back 255,255,229 # chart background
col_base 153,153,153 # chart baseline and pips
col_grid 204,204,204 # chart gridlines, top and sides
col_rx 255,76,76 # chart rx (receive, download) data
col_tx 51,102,255 # chart tx (transmit, upload) data
col_text 0,0,0 # text
col_fade 153,153,153 # text, faded (yesterday's hours)
col_shdw 204,216,230 # text shadow -- blue tinted grey
#
# labels, must use "_" for blanks, comment out to disable
axis_x Hour
axis_y Data_rate
#
# title, must use '_' for blanks, comment out to disable
#title Internet_Monitor
#
# enable daily rx and tx bytes total display above chart
totals 1 # 0 - disable, 1 - enable
showtotGB 1 # 1 to enable totals in GB display
#
# define netdraw output file (fly input file), this file is left in place
# for post mortem analysis
dayfly /tmp/netdrawday.fly
#
# fly related -- image destination
imagtemp /tmp/netdraw.png
imagfile netdraw.png
#
# netdrawcopy related -- midnight image copy, uses destpath above
daycopylog netdrawday.log # lists most recent images
moncopylog netdrawmon.log
daylogmax 7 # keep last n daily snapshots
monlogmax 3 # keep last n monthly snapshots
samplemax 8929 # keep 31 * 24 * 12 + 1 samples
copytmp /tmp/netdrawcopy.tmp
#
# netdrawhtml related
htmlfileday netdrawday.ssi # daily reports
htmlfilemon netdrawmon.ssi # monthly report
htmldaynum 7 # how many daily snapshots to show
htmlmonnum 3 # how many monthly snapshots to show
imagepath . # prefix for
tag
imagetitle 0 # '1' to enable image title tag
#
# netdrawmon related -- monthly summary
monfly /tmp/netdrawmon.fly # fly script
monimg netdrawmon.png # image name
#montitle Monthly_Summary # centre title, comment out for total
monaxisx Days # chart axis labels
monaxisy Daily_Totals
montotals 1 # print month's totals if non-zero
#
# netdrawmonsum
monsumfile monsumfile.log # where to write month's summary info