# # drraw configuration template/sample # # $Id: drraw.conf,v 1.20.2.2 2004/11/13 20:01:22 kalt Exp $ # # This file should be installed in the same directory as drraw.cgi and # edited as needed to customize your installation. At a minimum, you # need to edit variables which are not commented (below) since # # this will help catch configuration mistakes use strict; # The title used as header for the index web pages #$title = 'Draw Round Robin Archives on the Web'; # If you want to add a custom header for all pages, define this.. #$header = # If you want to add a custom footer for all pages, define this.. #$footer = # Directories where Round Robin Databases may be found # They will be searched recursively for files matching *.rrd (Round Robin # Database files) and *.evt (Event files). %datadirs = ("/var/db/rrdtool" => "[Label1] " ); # This function is used to sort *.rrd and *.evt filenames before displaying # them for the user to choose from. It is passed the two arguments that # need to be compared. #sub mydatafnsort { return $_[0] cmp $_[1]; } # Default DS filter when adding graph data sources from RRD files #$dsfilter_def = ''; # Names of defined RRAs and the names to use on the graphs #@rranames = ( 'MIN', 'AVERAGE', 'MAX', 'LAST' ); #%rranames = ( 'MIN' => 'Min', # 'AVERAGE' => 'Avg', # 'MAX' => 'Max', # 'LAST' => 'Last' # ); # Viewer automatic refresh timer (seconds) #$vrefresh = '900'; # Minimum dashboard automatic refresh timer (seconds) #$drefresh = 1800; # Default Views and their names #@dv_def = ( 'end - 28 hours', 'end - 1 week', 'end - 1 month', 'end - 1 year' ); #@dv_name = ( 'Past 28 Hours', 'Past Week', 'Past Month', 'Past Year' ); # How many seconds for each of the above views? # (Ignored when using rrdtool 1.0.47 or later) #@dv_secs = ( 100800, 604800, 2419200, 31536000 ); # Format used for the "Additional GPRINTs" #$gformat = "%8.2lf"; # Graph Overlay (Requires RRDtool 1.0.36 or later) #$overlay = '/somewhere/logo.gd'; # Maximum time (seconds) CGI processes may be running (0 to disable) #$maxtime = 60; # Cache refresh time (seconds) #$crefresh = 3600; # Where to save data and store temporary files # These directories MUST EXIST and the user running CGI scripts must have # read AND write access to them. It is entirely safe to delete any content # found in the temporary directory. $saved_dir = '/var/db/drraw/saved'; $tmp_dir = '/var/db/drraw/tmp'; # By default, critical errors are shown in the produced HTML pages produced # and sent to standard error (which web servers typically write to some # logfile). If the following is defined, such errors will be written to # file directly by drraw. #$ERRLOG = '/somewhere/drraw/tmp/errors.log'; # By default (as long as the Digest::MD5 Perl module is available), drraw # will cache images to avoid recomputing them needlessly. The following # sets how often drraw should purge expired images from the cache. # (Expired images being are automatically purged when refreshed.) # Setting this to 0 will disable caching altogether. $clean_cache = 21600; # 6 hours # Whether or not RCS will be used, this requires: # (1) The Perl "Rcs" module to be installed # (2) The $saved_dir/RCS directory to exist #$use_rcs = 1; # Security Levels: # 0 : Read-Only (e.g. graph viewing only) # 1 : Limited Read-Write (such users can define/save new graphs, # and delete saved graphs they saved) # 2 : Read-Write # User authentication/validation handling is left up to the web server. In # other words, for things to work, you will need to change the web server # configuration. If you don't, nothing will happen :-) # # Authenticated users automatically set the level to 2 unless the username # is found in %users (below) in which case the level is set accordingly to # what is defined. # Unauthenticated users get the 'guest' username. # # If you don't care for authentication, set the following to 2. #%users = ( 'guest' => 0 ); # By default, drraw will use the REMOTE_USER environment variable to find # the user's username. If you wish to use something else, simply define # the following subroutine. # NOTES: (1) drraw will fall back to using the REMOTE_USER environment variable # if this subroutine returns 'undef': use 'guest' if you wish to # leave the user unauthenticated. # (2) this subroutine may manipulate the %users array based on external # data allowing to process authentication entirely out of this # configuration file. #sub &mygetuser { return $ENV{'SSL_CLIENT_EMAIL'}; } # If you want to override your system's default timezone, you may do so here. #$ENV{'TZ'} = 'UCT'; # If you have many RRD files and templates, indexes can become extremely # big and slow to load. This variable allows you to prevent all templates # choices from being displayed in the indexes based on how many choices # are available per template. #$IndexMax = 100; # Custom Index Definition # # Custom Indexes are defined as a HASH: # - Each key is the name that will be presented to the user # - Keys are sorted when the index is built # - If a key matches ^\d+\s+(\S.*)$ then only $1 will be shown # (This allows for keys to be sorted independently of what is shown.) # - The value for a given key must be one of the following: # - A HASH (for nested indexes) # - A SCALAR (for leaves) which will be matched as a regular expression # against the Graph titles, Template titles and Dashboard titles. # Matching titles will be presented to the user. # - An ARRAY (for leaves) containing 3 elements. Each element will be # matched as a regular expression against the Graph titles, Template # titles and Dashboard titles (respectively). Matching titles will # be presented to the user. # # For example: # %Index = ( '1 Network' => { 'Cisco' => [ undef, 'Cisco', 'Cisco' ], # 'Interfaces Statistics' => 'Interface', # 'Miscellaneous' => [ 'Traffic', '(DMZ Traffic|Firewall)', undef ], # 'VPN' => 'VPN' }, # '2 Storage' => [ undef, '(Disk|SAN)', '(Disk|SAN)' ], # '3 UNIX' => [ '(Solaris|BSD)', '(Solaris|BSD)', 'UNIX' ], # '4 Windows => [ 'Windows', 'Windows', 'Windows' ], # '5 Environmental' => [ 'Datacenter', undef, 'Datacenter' ] ); # # IMPORTANT NOTE: Nested indexes are implemented using JavaScript. # # Icons used in the browser # These may be copied from the drraw distribution if they are missing from # your web server installation. $icon_new = 'icons/generic.gif'; $icon_closed = 'icons/folder.gif'; $icon_open = 'icons/folder.open.gif'; $icon_text = 'icons/text.gif'; $icon_help = 'icons/unknown.gif'; $icon_bug = 'icons/bomb.gif'; $icon_link = 'icons/link.gif'; # Custom Style Sheet # $CSS 1;