[mrtg] Re: 14all.cgi speed problem
Nasreddine Tabet-Aoul
Nasreddine.Tabet-Aoul at madgeweb.com
Mon Nov 20 18:08:50 MET 2000
My MRTG all odf sudden is not updating regularly the stats as it used to
(5minutes).
What could be the reasons?
How can we check that polling are actually carried out?
The MRTG is running as an NT service
thanks
Nas
-----Original Message-----
From: Chris Green [mailto:cmg at uab.edu]
Sent: 20 November 2000 16:28
To: Bjorn Nordbo
Cc: Keith McCallion; Daniel R . Kilbourne; MRTG users
Subject: [mrtg] Re: 14all.cgi speed problem
Bjorn Nordbo <bn at nextra.com> writes:
> Keith McCallion wrote:
> >
> > On Sun, 19 Nov 2000, Daniel R . Kilbourne wrote:
> >
> > > If you can tweak it to run faster, please let me know.....
> >
> > I was thinking about this the other day. What about storing
configuration
> > files in a DBM or some other binary format - wouldn't that speed things
up
> > quite a bit, since you have a unique key (the target name) for each
device
> > being monitored.
> >
> > If I had any free time I'd try to whip up a patch to mrtg/14all, but,
> > lately time is something that I severely lack.
>
> I thought Rainer Bawidamann implemented this a month or two back, but
> I might be mistaken as I can't find nothing about it on the 14all.cgi
> pages.
>
> Anyway, I tried this approach for my config files, ranging from almost
> nothing to 500kB. The performance gain is considerable, and on a 440MHz
> T1 a full MRTG-like dynamic page (9 separate CGI-invocations) for a tar-
> get in a 450kB configuration file is displayed in 3-4 seconds. I assume
> mod_perl would speed this up another 50% or so when I get around to it.
Joe Gooch <mrwizard at psu.edu> and I have done a few hacks to Rainer's
script to make it much faster and Rainer has been giving me good feed
back and trying to keep me honest with my hacks.
For 1.0, he did a very nice DBI config setup that will be updated one
day. To hack speed into 1.1, I changed I write out the configuration
straight to disk with Storable to get rid of the reparsing nightmare
if the configuration directory is writable.
The major changes from this version is addition of 14all*htmlbasedir,
the directory in your web root that mrtg graphs will be displayed in.
It works if your webroot is writable by the httpd user. Graphs are
drawn before the page is displayed so a good # of cgi invocations are
saved.
With an 8 meg config file, smaller directories in 14all* are very fast
and bigger ones are atleast usable on a dual 733. There is also a
runtime switch between logarithmic and linear graphs.
My hacks aren't so clean and lots of it should be cleaned up. I
haven't tested this with mod_perl and it probably won't work because I
need to do a stat test rather than the -M stuff I do now.
http://helium.tucc.uab.edu/~sprout/14all_cmg/
--
Chris Green <cmg at uab.edu>
A good pun is its own reword.
--
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