Php weathermap not reading RRD's (CPu Enhanced)

Support questions about the Network Weather Map plugin

Moderators: Developers, Moderators

Post Reply
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

Hello all,

I have a graph of CPU usage advanced.
I can not get just "last Total CPU Usage" information ?

Code: Select all

NODE node0555
        LABEL {node:this:inpercent:CPU %0.1f}%
        INFOURL /graph.php?rra_id=all&local_graph_id=38
        OVERLIBGRAPH /graph_image.php?rra_id=0&graph_nolegend=true&graph_height=100&graph_width=300&local_graph_id=38
        TARGET gauge:/var/www/cacti/rra/xxxxxxxxxxxxx_cpu_idle_106.rrd:cpu_idle:-
        POSITION 400 520
Thank you for your help.
Attachments
Sans-titre.JPG
Sans-titre.JPG (124.92 KiB) Viewed 3945 times
Last edited by sidacoq on Mon Dec 06, 2010 8:15 am, edited 1 time in total.
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: CPU's utilisation (Enhanced)

Post by sidacoq »

information of rrd file:

Code: Select all

/usr/local/rrdtool/bin/rrdtool info 75.rrd
the result

Code: Select all

rrdtool info /var/www/cacti/rra/65.rrd
filename = "/var/www/cacti/rra/65.rrd"
rrd_version = "0003"
step = 300
last_update = 1291638903
header_size = 2276
ds[cpu_idle].index = 0
ds[cpu_idle].type = "COUNTER"
ds[cpu_idle].minimal_heartbeat = 600
ds[cpu_idle].min = 0,0000000000e+00
ds[cpu_idle].max = NaN
ds[cpu_idle].last_ds = "42024480"
ds[cpu_idle].value = 2,6598338870e+02
ds[cpu_idle].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 500
rra[0].cur_row = 177
rra[0].pdp_per_row = 1
rra[0].xff = 5,0000000000e-01
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 600
rra[1].cur_row = 352
rra[1].pdp_per_row = 1
rra[1].xff = 5,0000000000e-01
rra[1].cdp_prep[0].value = NaN
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 700
rra[2].cur_row = 447
rra[2].pdp_per_row = 6
rra[2].xff = 5,0000000000e-01
rra[2].cdp_prep[0].value = 8,8639509106e+01
rra[2].cdp_prep[0].unknown_datapoints = 0
rra[3].cf = "AVERAGE"
rra[3].rows = 775
rra[3].cur_row = 157
rra[3].pdp_per_row = 24
rra[3].xff = 5,0000000000e-01
rra[3].cdp_prep[0].value = 6,2328895537e+02
rra[3].cdp_prep[0].unknown_datapoints = 0
rra[4].cf = "AVERAGE"
rra[4].rows = 797
rra[4].cur_row = 464
rra[4].pdp_per_row = 288
rra[4].xff = 5,0000000000e-01
rra[4].cdp_prep[0].value = 1,3803651155e+04
rra[4].cdp_prep[0].unknown_datapoints = 0
rra[5].cf = "MAX"
rra[5].rows = 500
rra[5].cur_row = 0
rra[5].pdp_per_row = 1
rra[5].xff = 5,0000000000e-01
rra[5].cdp_prep[0].value = NaN
rra[5].cdp_prep[0].unknown_datapoints = 0
rra[6].cf = "MAX"
rra[6].rows = 600
rra[6].cur_row = 459
rra[6].pdp_per_row = 1
rra[6].xff = 5,0000000000e-01
rra[6].cdp_prep[0].value = NaN
rra[6].cdp_prep[0].unknown_datapoints = 0
rra[7].cf = "MAX"
rra[7].rows = 700
rra[7].cur_row = 551
rra[7].pdp_per_row = 6
rra[7].xff = 5,0000000000e-01
rra[7].cdp_prep[0].value = 8,8639509106e+01
rra[7].cdp_prep[0].unknown_datapoints = 0
rra[8].cf = "MAX"
rra[8].rows = 775
rra[8].cur_row = 760
rra[8].pdp_per_row = 24
rra[8].xff = 5,0000000000e-01
rra[8].cdp_prep[0].value = 9,1451069194e+01
rra[8].cdp_prep[0].unknown_datapoints = 0
rra[9].cf = "MAX"
rra[9].rows = 797
rra[9].cur_row = 244
rra[9].pdp_per_row = 288
rra[9].xff = 5,0000000000e-01
rra[9].cdp_prep[0].value = 9,6136177778e+01
rra[9].cdp_prep[0].unknown_datapoints = 0 
Thank you for your support.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by Howie »

What does the Cacti log say? (look for WEATHERMAP lines, and especially lines mentioning ReadData)
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

Nothing, 0 warning.
I pick out a return but I think it's a Counter32.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by Howie »

OK, then turn on DEGUG logging for a cycle. Weathermap should give you the information you need.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

Still no warnings.
I get good information, that is why the debug does not return any warnings. However, it is not good.
It proved that return informations is not gauge but SNMP Counter32.

Code: Select all

12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] DEBUG: [weathermap_run_maps@poller-common.php:196] [Map 1] IDPS_Platform: Wrote HTML to /var/www/cacti/plugins/weathermap/output/6f7b140579ded8e9c02e.html
12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] DEBUG: [ProcessString@Weathermap.class.php:517] [Map 1] IDPS_Platform: Trace: ProcessString(Intrusion Detection and Prevention System, map)
12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] DEBUG: [weathermap_run_maps@poller-common.php:220] [Map 1] IDPS_Platform: TIME: /var/www/cacti/plugins/weathermap/configs/IDPS_Platform took 1 seconds.
12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] DEBUG: [weathermap_memory_check@poller-common.php:11] [Map 1] IDPS_Platform: MEM after 1: memory_get_usage() says 8.6MBytes used. Limit is 128M
12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] DEBUG: [weathermap_run_maps@poller-common.php:239] Iterated all 2 maps.
12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] DEBUG: [weathermap_memory_check@poller-common.php:11] MEM Final: memory_get_usage() says 8.6MBytes used. Limit is 128M
12/07/2010 11:54:36 AM - WEATHERMAP: Poller[0] STATS: Weathermap 0.97a run complete - Tue, 07 Dec 2010 11:54:36 CET: 2 maps were run in 2 seconds with 0 warnings.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by Howie »

That's not the debug log. The debug log is much more detailed.

Weathermap doesn't care if it's gauge or counter, it just gets the value out of the rrd file.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

I didn't copy everything.
please see in attach (MAP 1)
Attachments
debug.txt
(729.43 KiB) Downloaded 134 times
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by Howie »

This is a relevant chunk.

Code: Select all

12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [ReadData@Weathermap.class.php:901] [Map 1] IDPS_Platform: ReadData: New Target: scale:0.1:/var/www/cacti/rra/fr182-roc-idp02-11_cpu_idle_39.rrd:cpu_idle:-
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [ProcessString@Weathermap.class.php:517] [Map 1] IDPS_Platform: Trace: ProcessString(scale:0.1:/var/www/cacti/rra/fr182-roc-idp02-11_cpu_idle_39.rrd:cpu_idle:-, node:node0557)
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [ReadData@WeatherMapDataSource_rrd.php:496] [Map 1] IDPS_Platform: Special DS names seen (cpu_idle and -).
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [ReadData@WeatherMapDataSource_rrd.php:516] [Map 1] IDPS_Platform: SCALING result by 0.1
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [ReadData@WeatherMapDataSource_rrd.php:574] [Map 1] IDPS_Platform: RRD ReadData: Target DS names are cpu_idle and -
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:322] [Map 1] IDPS_Platform: RRD ReadData: traditional style
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:362] [Map 1] IDPS_Platform: RRD ReadData: Running: /usr/bin/rrdtool fetch /var/www/cacti/rra/fr182-roc-idp02-11_cpu_idle_39.rrd AVERAGE --start now-800 --end now
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:382] [Map 1] IDPS_Platform: > 1291722600: 4,2256166113e+01
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:382] [Map 1] IDPS_Platform: > 1291722900: 4,3029524836e+01
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:382] [Map 1] IDPS_Platform: > 1291723200: 4,3383004800e+01
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:382] [Map 1] IDPS_Platform: > 1291723500: nan
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:382] [Map 1] IDPS_Platform: >
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:390] [Map 1] IDPS_Platform: RRD ReadData: Read 5 lines from rrdtool
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:391] [Map 1] IDPS_Platform: RRD ReadData: Headings are:                        cpu_idle
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:400] [Map 1] IDPS_Platform: --
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:400] [Map 1] IDPS_Platform: --1291723500: nan
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:400] [Map 1] IDPS_Platform: --1291723200: 4,3383004800e+01
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:421] [Map 1] IDPS_Platform: 4,3383004800e+01 is OK value for cpu_idle
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [wmrrd_read_from_real_rrdtool@WeatherMapDataSource_rrd.php:455] [Map 1] IDPS_Platform: RRD ReadDataFromRealRRD: Returning (4,3383004800e+01,0,1291723200)
12/07/2010 01:01:54 PM - WEATHERMAP: Poller[0] DEBUG: [ReadData@WeatherMapDataSource_rrd.php:616] [Map 1] IDPS_Platform: RRD ReadData: Returning (4.33830048,0,1291723200)
I think it's a problem with LOCALE, since 4,33e01 (i.e. 43) has turned into 4.3

I thought I had fixed these issues in 0.97... what locale is your server set to?
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

Cacti : 0.8.7g
Weathermap : 0.97a
I have this problem of "locale" ?
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by Howie »

Yes - international settings. What language is your server set to? This governs things like whether decimals are , or . and so on...
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

I don't think taht i have this problem ...

Code: Select all

[root@xxxxxxxxx ~]# locale -a
aa_DJ
aa_DJ.iso88591
aa_DJ.utf8
....
zh_TW
zh_TW.big5
zh_TW.euctw
zh_TW.utf8
zu_ZA
zu_ZA.iso88591
zu_ZA.utf8
Last edited by sidacoq on Tue Dec 07, 2010 7:59 am, edited 1 time in total.
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by Howie »

When you installed the OS, what country did you use?
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

french
sidacoq
Posts: 14
Joined: Wed Jul 30, 2008 3:34 am
Location: Chartres

Re: Php weathermap not reading RRD's (CPu Enhanced)

Post by sidacoq »

I really think it's another issue.
Type COUNTER is recognized in weathermap because :

Code: Select all

[root@xxxxxxxxxxxxxx ~]# rrdtool info /var/www/cacti/rra/39.rrd
filename = "/var/www/cacti/rra/39.rrd"
rrd_version = "0003"
step = 300
last_update = 1291737313
header_size = 2276
ds[cpu_idle].index = 0
ds[cpu_idle].type = "COUNTER"
ds[cpu_idle].minimal_heartbeat = 600
ds[cpu_idle].min = 0,0000000000e+00
ds[cpu_idle].max = NaN
ds[cpu_idle].last_ds = "90426121"
ds[cpu_idle].value = 8,4439333333e+02
ds[cpu_idle].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 500
rra[0].cur_row = 332
rra[0].pdp_per_row = 1
rra[0].xff = 5,0000000000e-01
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 600
rra[1].cur_row = 404
rra[1].pdp_per_row = 1
rra[1].xff = 5,0000000000e-01
rra[1].cdp_prep[0].value = NaN
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 700
rra[2].cur_row = 688
rra[2].pdp_per_row = 6
rra[2].xff = 5,0000000000e-01
rra[2].cdp_prep[0].value = 2,7360028889e+02
rra[2].cdp_prep[0].unknown_datapoints = 0
rra[3].cf = "AVERAGE"
rra[3].rows = 775
rra[3].cur_row = 361
rra[3].pdp_per_row = 24
rra[3].xff = 5,0000000000e-01
rra[3].cdp_prep[0].value = 1,3038611252e+03
rra[3].cdp_prep[0].unknown_datapoints = 0
rra[4].cf = "AVERAGE"
rra[4].rows = 797
rra[4].cur_row = 276
rra[4].pdp_per_row = 288
rra[4].xff = 5,0000000000e-01
rra[4].cdp_prep[0].value = 1,4313936596e+04
rra[4].cdp_prep[0].unknown_datapoints = 0
rra[5].cf = "MAX"
rra[5].rows = 500
rra[5].cur_row = 395
rra[5].pdp_per_row = 1
rra[5].xff = 5,0000000000e-01
rra[5].cdp_prep[0].value = NaN
rra[5].cdp_prep[0].unknown_datapoints = 0
rra[6].cf = "MAX"
rra[6].rows = 600
rra[6].cur_row = 167
rra[6].pdp_per_row = 1
rra[6].xff = 5,0000000000e-01
rra[6].cdp_prep[0].value = NaN
rra[6].cdp_prep[0].unknown_datapoints = 0
rra[7].cf = "MAX"
rra[7].rows = 700
rra[7].cur_row = 256
rra[7].pdp_per_row = 6
rra[7].xff = 5,0000000000e-01
rra[7].cdp_prep[0].value = 6,4336307937e+01
rra[7].cdp_prep[0].unknown_datapoints = 0
rra[8].cf = "MAX"
rra[8].rows = 775
rra[8].cur_row = 770
rra[8].pdp_per_row = 24
rra[8].xff = 5,0000000000e-01
rra[8].cdp_prep[0].value = 6,6062166667e+01
rra[8].cdp_prep[0].unknown_datapoints = 0
rra[9].cf = "MAX"
rra[9].rows = 797
rra[9].cur_row = 168
rra[9].pdp_per_row = 288
rra[9].xff = 5,0000000000e-01
rra[9].cdp_prep[0].value = 9,0916563355e+01
rra[9].cdp_prep[0].unknown_datapoints = 0

Code: Select all

[root@xxxxxxxx ~]# rrdtool fetch /var/www/cacti/rra/39.rrd AVERAGE --start now-800 --end now
                       cpu_idle

1291736700: 5,6016214047e+01
1291737000: 5,0927047619e+01
1291737300: nan
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest