swooningfish / mysql-cacti-templates

Automatically exported from code.google.com/p/mysql-cacti-templates
GNU General Public License v2.0
0 stars 0 forks source link

Support for apache1 #138

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,

Unfortunately, I have some customers still running apache1 for very
specific legacy reasons.

Would it be possible to add support for apache1?

Most of the apache-related items seem to work fine, with the exception of
"X Apache Workers GT".

From what I can see, one difference in apache1 in the output of a
/server-status?auto is, for example:

Apache 2:

Total Accesses: 530575
Total kBytes: 51901090
CPULoad: .0208016
Uptime: 668988
ReqPerSec: .793101
BytesPerSec: 79443.5
BytesPerReq: 100168
BusyWorkers: 1
IdleWorkers: 9
Scoreboard:
W__._.___.__._..................................................................
........................................

Apache 1, instead, we have:

Total Accesses: 11383507
Total kBytes: 115588311
CPULoad: 32.4302
Uptime: 82673
ReqPerSec: 137.693
BytesPerSec: 1431690
BytesPerReq: 10397.7
BusyServers: 40
IdleServers: 20
Scoreboard:
_KW_K_KWKKK_K_WWWWWKWKW__WWWK_KW_WWWK_KWWWWW____K__W_KWW_W__....................
........................................

So I suppose if it would be possible to add some parsing for:

BusyServers
IdleServers

Perhaps that might be all that is needed?

Original issue reported on code.google.com by moo...@gmail.com on 9 Apr 2010 at 6:24

GoogleCodeExporter commented 9 years ago
Removing unused labels.

Original comment by baron.schwartz on 16 Apr 2010 at 2:14

GoogleCodeExporter commented 9 years ago
Please attach a text file with apache1 output for a test case.  (I want to be 
sure
that all whitespace is correct for the test case.)

Original comment by baron.schwartz on 16 Apr 2010 at 2:16

GoogleCodeExporter commented 9 years ago
Thank you.  Here's some output files.  A typical /server-status (which I don't 
think
you need, but nonetheless, just in case), and one from /server-status?auto.

Original comment by moo...@gmail.com on 23 Apr 2010 at 11:17

Attachments:

GoogleCodeExporter commented 9 years ago
Unfortunately I don't have time to do this, but have you looked at the wiki?  
There is a really comprehensive instruction guide on how to do this, and it 
isn't hard.  I would love for someone else to do this so I can just include it.

Original comment by baron.schwartz on 15 Jan 2011 at 6:59

GoogleCodeExporter commented 9 years ago
here is a fix:

in the apache section of ss_get_by_ssh.php you will find:

      if ($words[0] == "Total kBytes") {
         $words[1] = big_multiply($words[1], 1024);
      }

change it to:

      if ($words[0] == "Total kBytes") {
         $words[1] = big_multiply($words[1], 1024);
      } else if ($words[0] == "BusyServers"){
         $words[0] = "BusyWorkers";
      } else if ($words[0] == "IdleServers") {
         $words[0] = "IdleWorkers";
      }

and apache 1.3 worker status starts working :)

Original comment by ewint...@gmail.com on 5 Apr 2011 at 4:34