[mrtg] Re: General setup of multiple config files

William Owen william.owen at profilesmail.com
Mon Mar 7 16:22:38 MET 2005


I've setup an individual config for each of my devices and then have an
include.cfg that has all of my global stuff in it such as paths, log format,
ect... that I include at the top of each one.  I then run a separate task
for each one of my devices.  Note: My installation is a Win32 platform with
a routers2 front-end so there might be some extra stuff in there but you
should get the idea.  More notes: Since Windows doesn't do forks, this
allows multiple instances of Perl to be spawned which helps prevent a down
host from pushing me over the polling cycle.  It also allows you to spread
each process over the five minute polling cycle so they don't all start at
the same time which helps with resource contention.

Sample Include.cfg:

##### change dirs as needed versions etc etc ####

PathAdd: D:\MRTG\MRTG\bin
LibAdd: D:\MRTG\MRTG\lib\mrtg2

PathAdd: D:\MRTG\RRDTool\src\tool_release
# LibAdd: D:\MRTG\RRDTool\Perl-Shared

###### the rest of your cfg file here #####

LogFormat: rrdtool

WorkDir: D:\MRTG\Data\

Refresh: 300
Interval: 5

----------------------------------------------------------------------

Sample Device.cfg

Include: D:\MRTG\Configs\Include\Include.cfg

routers.cgi*Icon: windows2003-sm.gif
routers.cgi*InMenu: yes

Directory[_]: Servers\Server1

EnableIPv6: no

######################################################################
# System:
# Description:
# Contact:
# Location:
######################################################################

<Target stuff goes here>

-----Original Message-----
From: Shane Presley [mailto:shane.presley at gmail.com] 
Sent: Monday, March 07, 2005 9:06 AM
To: mrtg at list.ee.ethz.ch
Subject: [mrtg] General setup of multiple config files

Hello,

Just wondering if there are any "best practices" for how to setup
large environments?

Right now I've been sloppy, one config file with a mix of:

Switch Interfaces
Unix CPU, Disk, Memory, etc
Misc custom scripts.

It's about 10,000 lines.  It takes about 2 minutes to run (and is
cron'd for every 5 minutes).

Is that an acceptable method?  Or should I setup multiple config files
(for example one for switches, one for servers) and cron them all
independently?

Thanks
Shane

--
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

--
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