Ticket #1191 (closed patch: wontfix)

Opened 4 months ago

Last modified 4 months ago

CGI graph strategy + big datafile = very slow graph generation

Reported by: asimon Assigned to: nobody
Priority: normal Milestone: Munin 1.4.7
Component: master Version: 1.4.6
Severity: major Keywords:
Cc:

Description

Hi all,

we monitor 35 nodes from one master which creates about 6508 graphs. Today, in graph_strategy=cron the time slot is exceeded (ie. graph generation takes more than 5 mn !) so we have to use graph_strategy=cgi.

But, in our case, cgi generation is very slow. I've traced the code and the bottleneck is in datafile read function which has very poor performance with big datafile (55875 lines in our case). Remember that the datafile is (re)readed for each graph generation !

So, I think about a kind of "cache" to speed up this process. Please see the attached patch, which is in production in our environment.

Please let's me know what you think about this. I'm remain available to help you correct this performance problem.

Alex.

Attachments

datafile-cached.patch (1.2 kB) - added by asimon on 01/24/12 10:37:39.

Change History

01/24/12 10:37:39 changed by asimon

  • attachment datafile-cached.patch added.

01/24/12 12:07:12 changed by snide

  • status changed from new to closed.
  • resolution set to wontfix.

Sorry, but closing the ticket since CGI on 1.4 has critical issues anyway. The only good way to fix this is to upgrade to 2.0, so closing the ticket as "wontfix".

Thx for the attached patch as it still might be quite useful for others :-)

In 2.0 there is already a full support for FastCGI and binary Storable datafiles, and many many bugfixes :p