|
|
| Author |
Message |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12295 Location: Muenster, Germany
|
Posted: Sun Mar 09, 2008 6:02 am Post subject: |
|
|
With Cacti 087b (at least), handling of ALL|SIMILAR_DATA_SOURCES_(NO)?DUPS has been corrected.
Unfortunately, this unveils an error with the old "Thread" Graph Template. This is due to the fact, that the AREA/STACK was using the MAXIMUM consolidation function whereas the TOTAL uses AVERAGE. As AVERAGE was never used, the Total of ALL never used datasources is "nothing"; ugly.
So I changed AREA/STACK to AVERAGE and now the Total shows up as requested.
Please be aware of the fact, that even the LEGENDs (Current, Average, Max) are referring to the CDEF=ALL_DATA_SOURCES_NODUPS which is now calculated for the AVERAGE consolidation function.
So, I you were assuming, e.g. the Legend for totalling "MAX" would refer to the Sum of all data sources Maximum of all Maxima (as it should), please note that is only sums the Maximum of all AVERAGEs.
Reinhard |
|
| Back to top |
|
 |
GauTux
Joined: 10 Mar 2008 Posts: 1
|
Posted: Mon Mar 10, 2008 5:37 am Post subject: |
|
|
Hye,
I'm a new user of this forum.
Thanks a lot for your scripts and templates.
I've a little problem with it. I think that this is the apache configuration who isn't good.
I have any graphs for "Apache statistics kbits/s", hits, etc ...
But I have no problem "Apache statistics with thread details"
I have this in run the perl script manually :
perl ws_apachestats.pl localhost
apache_busy_workers:1 apache_idle_workers:9 thread_O:246 threadC:0 threadD:0 threadG:0 threadI:0 threadK:0 threadL:0 threadR:0 threadS:0 threadW:1 thread_W:9 apache_cpuload:W__..___.____...................................................................................................................................................................................................................................................
Please, can you help me ...
GauTux
From Paris (sorry for my english) |
|
| Back to top |
|
 |
neowdj
Joined: 29 Mar 2008 Posts: 1
|
Posted: Sat Mar 29, 2008 7:54 pm Post subject: |
|
|
hello
I'm turn on CentOS 5 and my error is
| Code: | 03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/serveur_aide_info_apache_busy_workers_33.rrd --template apache_busy_workers:apache_idle_workers:thread_O:threadC:threadD:threadG:threadI:threadK:threadL:threadR:threadS:threadW:thread_W 1206837533:1:8:247:0:0:0:0:0:0:0:0:1:8
OK u:0.00 s:0.00 r:1.06
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/serveur_aide_info_apache_busy_workers_31.rrd --template apache_busy_workers:apache_idle_workers:thread_O:threadC:threadD:threadG:threadI:threadK:threadL:threadR:threadS:threadW:thread_W 1206837533:1:8:247:0:0:0:0:0:0:0:0:1:8
OK u:0.00 s:0.00 r:1.06
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/serveur_aide_info_apache_busy_workers_30.rrd --template apache_busy_workers:apache_idle_workers:thread_O:threadC:threadD:threadG:threadI:threadK:threadL:threadR:threadS:threadW:thread_W 1206837533:1:8:247:0:0:0:0:0:0:0:0:1:8
OK u:0.00 s:0.00 r:1.06
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/localhost_proc_26.rrd --template proc 1206837533:106
OK u:0.00 s:0.00 r:1.06
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/localhost_users_25.rrd --template users 1206837533:2
OK u:0.00 s:0.00 r:1.06
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/localhost_hdd_free_27.rrd --template hdd_free:hdd_used 1206837533:8858484:5490448
OK u:0.00 s:0.00 r:1.06
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool create /usr/bin/perl /var/www/cacti/scripts/ws_apachestats.pl 127.0.0.1 --step 300 DS:apache_busy_workers:GAUGE:600:0:500 DS:apache_total_hits:COUNTER:600:0:10000 DS:apache_total_kbytes:COUNTER:600:0:40000 DS:apache_idle_workers:GAUGE:600:0:1000 DS:threadC:GAUGE:600:0:500 DS:thread_O:GAUGE:600:0:500 DS:threadD:GAUGE:600:0:500 DS:threadK:GAUGE:600:0:100 DS:threadI:GAUGE:600:0:500 DS:threadG:GAUGE:600:0:500 DS:threadL:GAUGE:600:0:500 DS:threadW:GAUGE:600:0:500 DS:threadS:GAUGE:600:0:500 DS:threadR:GAUGE:600:0:500 DS:thread_W:GAUGE:600:0:500 DS:apache_cpuload:GAUGE:600:0:100 RRA:AVERAGE:0.5:1:500 RRA:AVERAGE:0.5:1:600 RRA:AVERAGE:0.5:6:700 RRA:AVERAGE:0.5:24:775 RRA:AVERAGE:0.5:288:797 RRA:MAX:0.5:1:500 RRA:MAX:0.5:1:600 RRA:MAX:0.5:6:700 RRA:MAX:0.5:24:775 RRA:MAX:0.5:288:797
ERROR: can't parse argument '/var/www/cacti/scripts/ws_apachestats.pl'
03/30/2008 01:38:54 AM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /usr/bin/perl /var/www/cacti/scripts/ws_apachestats.pl 127.0.0.1 --template apache_busy_workers:apache_idle_workers:thread_O:threadC:threadD:threadG:threadI:threadK:threadL:threadR:threadS:threadW:thread_W N:1:8:247:0:0:0:0:0:0:0:0:1:8
ERROR: opening '/usr/bin/perl': Text file busy
|
| Code: | /var/www/cacti/scripts/ws_apachestats.pl 127.0.0.1
apache_busy_workers:1 apache_idle_workers:9 thread_O:246 threadC:0 threadD:0 threadG:0 threadI:0 threadK:0 threadL:0 threadR:0 threadS:0 threadW:1 thread_W:9 apache_cpuload:_W________...................................................................................................................................................................................................................................................... |
|
|
| Back to top |
|
 |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12295 Location: Muenster, Germany
|
Posted: Sun Mar 30, 2008 7:17 pm Post subject: |
|
|
Where is your perl located? Please run "which perl"
Reinhard |
|
| Back to top |
|
 |
sgm277
Joined: 24 May 2007 Posts: 7
|
Posted: Tue May 20, 2008 9:59 pm Post subject: |
|
|
| Ingimar wrote: | | lvm wrote: | This may be related to rrdtool 1.0.x. I used the TREND function. You may delete the "30 min moving average" items out of the graph template to get rid of this
Reinhard |
That did the trick! Thanks alot!  |
me too .thank you very much
I have 2 questions :
1) I found the pictures apache statistics -bytes/request , cpu load ,hits/s ,
KBits /s is empty ,what wrong with it ?
2) Is the template can draw the mem used of apache ?
Thank you very much ! |
|
| Back to top |
|
 |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12295 Location: Muenster, Germany
|
Posted: Sat May 24, 2008 3:43 pm Post subject: |
|
|
| sgm277 wrote: | | KBits /s is empty ,what wrong with it ? | I was under the impression that I've posted updated templates; hmmm.
Please visit the failing graph at Graph Management as switch to DEBUG. Post a screenshot, please
Reinhard |
|
| Back to top |
|
 |
sgm277
Joined: 24 May 2007 Posts: 7
|
Posted: Mon May 26, 2008 1:44 am Post subject: |
|
|
| gandalf wrote: | | sgm277 wrote: | | KBits /s is empty ,what wrong with it ? | I was under the impression that I've posted updated templates; hmmm.
Please visit the failing graph at Graph Management as switch to DEBUG. Post a screenshot, please
Reinhard |
thank you .It is my apache server problem , I want to monitor the memory the apache used , How can I do with the template ? |
|
| Back to top |
|
 |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12295 Location: Muenster, Germany
|
Posted: Mon May 26, 2008 12:19 pm Post subject: |
|
|
The data is retrieved from "server-status" URL. IMHO, server-status does not print information on memory consumption, does it?
Reinhard |
|
| Back to top |
|
 |
djmerlyn
Joined: 24 Jul 2006 Posts: 1
|
Posted: Sat Jun 07, 2008 12:11 am Post subject: |
|
|
Is there a way to display grand total hits, not as a graph but as a total number on the output of the legend below the graph?
**Well, I hate to come back here and just say "I figured it out" because its hard! And most forum threads and google searches end in a post that says "nevermind I figured it out" without telling how to do it
But, nevermind, I figured it out.
I even managed to compound my graphs in to one super graph of apache hits/s,hits/min,hits/hr,hits/day once I mastered cdef, which really only took a few minutes once I finally found the post that referred me to the rrdtools cdef tut. which is here by the way: http://oss.oetiker.ch/rrdtool/tut/cdeftutorial.en.html |
|
| Back to top |
|
 |
elpiako Cacti User
Joined: 01 Jul 2008 Posts: 66 Location: Lille (FRANCE)
|
Posted: Tue Jul 15, 2008 5:00 am Post subject: |
|
|
Got some prob.
Thanks to Gandalf, the owningmaster of Cacti , i've seen that there are some new stuffs for Apache Statistics with new versions of Cacti :
- a new ws_apachestats.pl file, i've updated it on my Server2
- a xml file of the host_template, but i don't know where to update it, and what for ?
At this stage, my graphs of Apache stats still don't work, and the command perl ws_apachestats.pl localhost or perl ws_apachestats.pl myremothost.domain.com return nothing.
For information, my previous version of ws_apachestats.pl returned
<HTML>
<HEAD><TITLE>An Error Occurred</TITLE></HEAD>
<BODY>
<H1>An Error Occurred</H1>
404 Not Found
</BODY>
</HTML> |
|
| Back to top |
|
 |
elpiako Cacti User
Joined: 01 Jul 2008 Posts: 66 Location: Lille (FRANCE)
|
Posted: Fri Jul 18, 2008 2:14 am Post subject: |
|
|
I've discovered that my server2 had to be able to contact the server-status page, and it can't.
It must be an allowing rule for server2 to contact the status page in the Apache configuration file on target server , or somethg... |
|
| Back to top |
|
 |
tuple
Joined: 21 Jul 2008 Posts: 1
|
Posted: Mon Jul 21, 2008 7:45 am Post subject: |
|
|
by default, server-status is commented out, | Code: | #<Location /server-info>
# SetHandler server-info
# Order deny,allow
# Deny from all
# Allow from .example.com
#</Location>
|
when you uncomment it, the Allow from directive should be changed. My preference is to set it to the internal subnet of your network, so it would become
| Code: |
Allow from 192.168.0.0/24
|
or
| Code: |
Allow from 10.0.0.0/8
|
depending on your internal subnet, it could be something completely different.
In the httpd.conf, it says .example.com and you may be tempted to change that to yoursite.com, but that very likely resolves through dns to an external IP address, and firewalls generally don't like it when you go out of the firewall and then directly back into the firewall.
To connect to server-status at that point, connect to the IP apache is listening on inside the firewall.
If that doesn't answer your question, perhaps someone will find it useful  |
|
| Back to top |
|
 |
elpiako Cacti User
Joined: 01 Jul 2008 Posts: 66 Location: Lille (FRANCE)
|
Posted: Mon Jul 21, 2008 10:35 am Post subject: |
|
|
yep !! I've finally found what was wrong, i just had to add "Allow from IP_of_my_server2" in the apache2.conf target host  |
|
| Back to top |
|
 |
waeltec
Joined: 14 Aug 2008 Posts: 7
|
Posted: Mon Aug 18, 2008 6:26 am Post subject: |
|
|
Dear,
I have Imported the attached template, and i have added a new input method related to the attached perl script but the charts display no data (empty charts),
please if any one has a solution, provide me with it as soon as possible
Thanks All, |
|
| Back to top |
|
 |
buddhabadboy
Joined: 19 Sep 2008 Posts: 2
|
Posted: Tue Sep 23, 2008 4:06 pm Post subject: ERROR: invalid rpn expression 'a,1800,TREND' |
|
|
I get an error / no graph when I use:
"WebServer - Apache Statistics - CPU Load"
Can anyone point me in the right direction?
All the other apache graphs work fine....
/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="nat228 (tools) - Apache Statistics - CPU Load" \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="Apache CPU Load %" \
DEF:a="/web/sites/app/cacti/rra/nat228_tools_apache_busy_workers_68.rrd":apache_cpuload:AVERAGE \
DEF:b="/web/sites/app/cacti/rra/nat228_tools_apache_busy_workers_68.rrd":apache_cpuload:MAX \
CDEF:cdeff=a,1800,TREND \
AREA:a#FF5F00:"Apache CPU Load" \
GPRINT:a:LAST:" Current\:%8.2lf %s" \
GPRINT:a:AVERAGE:"Average\:%8.2lf %s" \
GPRINT:b:MAX:"Maximum\:%8.2lf %s" \
LINE1:b#FF0000:"MAX" \
LINE1:cdeff#000000:"30min moving average\n"
RRDTool Says:
ERROR: invalid rpn expression 'a,1800,TREND' |
|
| Back to top |
|
 |
|
Powered by phpBB © 2001, 2005 phpBB Group
|
|