Some OID data collected but not graphing

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
markngt
Posts: 1
Joined: Sun May 26, 2002 7:10 pm
Location: Scottsdale, AZ
Contact:

Some OID data collected but not graphing

Post by markngt »



I was testing the ability to collect OIDs and found some inconsistencies that I don't quite understand. I used and OID for CPU Utilization and .1.3.6.1.4.1.9.2.1.58.0 and I am able to collect the data and print a graph.

I try one of the memory used OIDs and all looks fine. The log also shows that the file has been written too.

INTERNAL: [10.1.2.1/public] OID: [.1.3.6.1.4.1.9.9.48.1.1.1.6.1]
/usr/local/rrdtool/bin/rrdtool update /var/www/html/cacti-0.6.8/rra/memtest.rrd --template memtest N:6228784

However the graph remains blank. The format for the graph is as follows:

Select a Graph Hierarchy: Default Tree TEST
/usr/local/rrdtool/bin/rrdtool graph - \
--imgformat=PNG \
--start="-86400" \
--title="3620_Memory_Utilization" \
--rigid \
--base=1000 \
--height=150 \
--width=500 \
--alt-autoscale-max \
DEF:a="/var/www/html/cacti-0.6.8/rra/memtest.rrd":memtest:AVERAGE \
DEF:b="/var/www/html/cacti-0.6.8/rra/3620_memory_used.rrd":3620_memory_used:AVERAGE \
AREA:b#F51D30:"Memory Used\: kB\n" \
STACK:a#00FF00:"Memory Free\: kB\n"

I am sure that I am missing something. But at this point am not sure what. I see in the post that there have been some issues collecting the data but that does not seem to be the problem here? By the way is there a way to verify data in the rrd file is good?

:-?

Mark
raX
Lead Developer
Posts: 2243
Joined: Sat Oct 13, 2001 7:00 pm
Location: Carlisle, PA
Contact:

Post by raX »

If you are getting back data and no data is showing, it is usually a permissions problem. What happens if you 'su' to the user that runs 'cmd.php' and execute:

Code: Select all

/usr/local/rrdtool/bin/rrdtool update /var/www/html/cacti-0.6.8/rra/memtest.rrd --template memtest N:6228784
You'll want to make sure the owner of all of the .rrd files match the user 'cmd.php' runs as.

-Ian
Guest

Post by Guest »

Ian,

Thanks for the response. I am looking forward to really getting this tool up and running smoothly.

Still cannot read the OID data from the graphs. A few print fine. I checked the permissions and performed the update command from the command line. All looked fine. No hiccups. the cron is running smoothly and the data is being updated according to the logs with no mishaps. 'cmd.php is the owner of the .rrd files.

I rewalked through the graph setup and also duplicated a working graph I built from another snmp oid. I can't figure out why some print and some don't. The internal SNMP command is returning valid numbers.

INTERNAL: [10.1.2.1/public] OID: [.1.3.6.1.4.1.9.2.1.8.0]
/usr/local/rrdtool/bin/rrdtool update /var/www/html/cacti-0.6.8/rra/3620_memory_free.rrd --template 3620_memory_free N:6080236

Do you know of another way to verify the rrd file is getting corrupted by the updates?

-Mark
Guest

Post by Guest »

same here...

also in the Cron Printout, if I do Show Output, there is no value for my SNMP thing, but in the Data Source, in Edit Data, I can see the actual real result.

Which is correct also.

But its not showing in the graph.

I've found something else, also, if I do this :

/usr/local/rrdtool/bin/rrdtool fetch bigbang_load.rrd AVERAGE

I get this output :
1022682300: nan
1022682600: nan
1022682900: nan
1022683200: nan
1022683500: nan
1022683800: nan

But from the Data Sources my command line seems to be okay, as far as I know.

INTERNAL: [xxx.xxx.xxx.xxx/xxxxx] OID: [.1.3.6.1.4.1.2021.10.1.3.1]
/usr/local/rrdtool/bin/rrdtool update /home/htdocs/fusion.generation.net/html/cacti/rra/bigbang_load.rrd --template bigbang_load N:enterprises.ucdavis.laTable.laEntry.laLoad.1 = 0.00

That's correct right ?
raX
Lead Developer
Posts: 2243
Joined: Sat Oct 13, 2001 7:00 pm
Location: Carlisle, PA
Contact:

Post by raX »

Actually this does not look correct:

Code: Select all

 /usr/local/rrdtool/bin/rrdtool update /home/htdocs/fusion.generation.net/html/cacti/rra/bigbang_load.rrd --template bigbang_load N:enterprises.ucdavis.laTable.laEntry.laLoad.1 = 0.00
Seems like a parsing problem on my part though. If everything were working correctly, it would look like this:

Code: Select all

 /usr/local/rrdtool/bin/rrdtool update /home/htdocs/fusion.generation.net/html/cacti/rra/bigbang_load.rrd --template bigbang_load N:0.00
If you want to take a look at the problem meanwhile, you can take a look at the cacti_snmp_get function in the 'include/snmp_functions.php'. I will try and get around to it when I get the chance (if I can duplicate the problem).

Mark: I don't think you mentioned specifically, what happens when you run the rrdtool update command as the cmd.php user at the command line?

-Ian
guest

No Response

Post by guest »

Ian,

I see the same thingI get no response. Looks like the command works fine. When I do a fetch I get the same response as our other guest. I do think your right, it is a parsing problem. I am traveling today/tomorrow so I will spend some time with it this weekend and see if I can figure out fix.

Regards,

Mark
Guest

Post by Guest »

Hi, I forgot to put a signature in my last msg, anyway...

If I do a manual snmpget (snmpget bigbang.xxxxxxxx.xxx xxxxxx .1.3.6.1.4.1.2021.10.1.3.1) from a shell, I get this :

enterprises.ucdavis.laTable.laEntry.laLoad.1 = 0.00

So that's ok I guess...

so probably its in the code it self, i don't know much about php, but I could try to troubleshoot the prob. Maybe its just my version of php and UCD-snmp, that is not giving you the good output that the function is looking for... could it be possible ?

-Eric
Guest

Post by Guest »

oh and also.... on apache, php is supporting snmp.

-Eric
Guest

Post by Guest »

finally after looking around...
I've found about the INTERNAL and UCD-SNMP, i changed the setting in config.php to show $config["php_snmp_support"] = false;

instead of #$config["php_snmp_support"] = function_exists("snmpget");

Now its working.

At first I was not sure if my problem was related to the Internal SNMP or the UCD...

But yeah, it seems that its better to use the UCD-SNMP for me.
Maybe you could put an option in the settings menu, to choose between UCD-SNMP and the internal SNMP of php. Maybe you'll save some trouble with simple questions like this one... ;)

Thanks buddy!

And keep up the good work.

-Eric
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests