[mrtg] Include files and WorkDirs
Colin Horsington
chorsington at flow.com.au
Tue Feb 4 23:41:48 MET 2003
Hi,
I have one main mrtg.cfg where I set all the global config options. I then
include all other configs from a directory tree.
For example:
/etc/mrtg.cfg
/etc/mrtg/devicetype_1/device_1.cfg
/etc/mrtg/devicetype_1/device_2.cfg
/etc/mrtg/devicetype_1/device_3.cfg
/etc/mrtg/devicetype_2/device_a.cfg
/etc/mrtg/devicetype_2/device_b.cfg
/etc/mrtg/devicetype_2/device_c.cfg
Where all the devices.cfg are created from policies based upon devicetype
definitions. Now each device.cfg defines it's own WorkDir: in the
form...(via cfgmaker --global "WorkDir: %s")
WorkDir: /var/www/mrtg/device_x/
However all the rrd's/logs/htmls for all devices are placed in the same one
directory, this directory is:
/var/www/mrtg/device_x/
Any ideas?
Thanks,
Colin
PS. Main mrtg.cfg is:
###
#
# MRTG Configuration file
#
###
#
# This file contains global configuration options
# and includes which point to other configs for devices.
# This file _SHOULD_NOT_ contain information pertaining
# to devices.
#
# All device configs are stored in /etc/mrtg/
#
#
###
#
# Global configuration
#
###
WriteExpires: Yes
Refresh: 600
RunAsDaemon: Yes
Interval: 5
Forks: 4
LogFormat: rrdtool
###
#
# Global Options
#
###
XSize[_]: 600
YSize[_]: 150
Options[_]: bits
###
#
# Includes Section
#
###
Include: /etc/mrtg/devicetype_1/device1
Include: /etc/mrtg/devicetype_1/device2
Include: /etc/mrtg/devicetype_1/device3
--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive http://www.ee.ethz.ch/~slist/mrtg
FAQ http://faq.mrtg.org Homepage http://www.mrtg.org
WebAdmin http://www.ee.ethz.ch/~slist/lsg2.cgi
More information about the mrtg
mailing list