Poller path is invalid

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Poller path is invalid

Post by unter_hosen »

Hi all

Im in way over my head with linux and pretty much know hardly anything about it. Therefore, please go easy on me :D

I have managed to get Ubuntu up and running with MySQL, PHP, Apache2, Webmin etc

I have now put cacti on it and have most of it up and running however the graphs do not want to retrieve any data...

My graph consists of just simple interface stats from my inter-vlan router and my gateway router, both of which are cisco 1721s and both I have setup to get SNMP data from as I am a Cisco Network Engineer by trade.

I thought this might be an issue with the cronjob at first, but I modified /etc/cron.d/cacti to what it says in lvm's nan guide and now i am getting this...

Image

When i go to graph management and check one of the graph templates i get this...

Code: Select all

RRDTool Command:

/usr/local/rrdtool-1.2.15/bin/rrdtool graph - \
--imgformat=PNG \
--start=-86400 \
--end=-300 \
--title="Gateway - Traffic - Di0" \
--rigid \
--base=1000 \
--height=120 \
--width=500 \
--alt-autoscale-max \
--lower-limit=0 \
--vertical-label="bits per second" \
--slope-mode \
DEF:a="/var/www/cacti/rra/gateway_traffic_in_12.rrd":traffic_in:AVERAGE \
DEF:b="/var/www/cacti/rra/gateway_traffic_in_12.rrd":traffic_out:AVERAGE \
CDEF:cdefa=a,8,* \
CDEF:cdeff=b,8,* \
AREA:cdefa#00CF00:"Inbound"  \
GPRINT:cdefa:LAST:"Current\:%8.2lf %s"  \
GPRINT:cdefa:AVERAGE:"Average\:%8.2lf %s"  \
GPRINT:cdefa:MAX:"Maximum\:%8.2lf %s\n"  \
LINE1:cdefa#002A97:"Outbound"  \
GPRINT:cdeff:LAST:"Current\:%8.2lf %s"  \
GPRINT:cdeff:AVERAGE:"Average\:%8.2lf %s"  \
GPRINT:cdeff:MAX:"Maximum\:%8.2lf %s" 
RRDTool Says:

OK

Before modifying the cron the graphs were displaying but blank and the only way they would update was if i called poller.php manually and then the rrd files would update and i would get a little bit of data.........

Any help greatly appreciated.
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

Hi again

Worked out what my error was, i had changed the poller to cactid which is why it was saying that the path was invalid. Now that is fixed I am seeing this in the cacti.log

11/10/2006 12:51:34 AM - CMDPHP: Poller[0] ERROR: Either there are no items in the cache or polling is disabled
11/10/2006 12:51:35 AM - SYSTEM STATS: Time:1.1438 Method:cmd.php Processes:1 Threads:N/A Hosts:2 HostsPerProcess:2 DataSources:0 RRDsProcessed:0

any ideas?
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

FYI, the tickbox on the poller page under settings is ticked.
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

I am now getting nans on my graphs.............................................

arrghhh

if anyone can point me in the right direction that would be great. i have had a look at lvm's NaN debugging thing, but didnt understand a lot of it which is half of my problem.

Many Thanks in advance


Martin
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Goto Utilities -> View Poller Cache -> Clear. It would appear that your poller cache is been emptied by someone for some reason, or your poller_item table is corrupt. If it is damaged, you can rebuild it using the command from the cacti.sql file. You will extract that table structure from the file and place it in a file called "mini.sql". Then run the following command:

mysql -u root -p cacti < mini.sql

After which, you will have to "Clear" your poller cache again.

TheWitness

big problem though, where did all the data go. I hope you have a database backup....
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Also, it would appear that possibly, the path to PHP is not set properly or can't be found by Cacti. Make sure your Path's are correct:

Settings->Paths

Oh, BTB, path's includes the binary name, so make sure it's the binary and not simply the folder.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

Hi TheWitness

Thanks so much for the reply, I will do the things you suggested and get back to you. Another issue that has arisen is that i am using your 1 minute polling "hack" (for want of a better word) and the information does not get passed to the poller cache unless i add a standard 5 minute graph???? which is very strange, but thats another issue to get sorted after the poller is working automatically....
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

ok

Cleared the poller cache

The path to PHP is correct, i.e its pointing at the binary /usr/bin/php

Im also getting this in the cacti log..

11/13/2006 09:24:54 AM - SYSTEM STATS: Time:293.0283 Method:cmd.php Processes:1 Threads:N/A Hosts:2 HostsPerProcess:2 DataSources:5 RRDsProcessed:0
11/13/2006 09:24:54 AM - POLLER: Poller[0] Maximum runtime of 292 seconds exceeded. Exiting.
11/13/2006 09:19:54 AM - SYSTEM STATS: Time:292.7807 Method:cmd.php Processes:1 Threads:N/A Hosts:2 HostsPerProcess:2 DataSources:5 RRDsProcessed:0
11/13/2006 09:19:54 AM - POLLER: Poller[0] Maximum runtime of 292 seconds exceeded. Exiting.
11/13/2006 09:14:55 AM - SYSTEM STATS: Time:293.7439 Method:cmd.php Processes:1 Threads:N/A Hosts:2 HostsPerProcess:2 DataSources:5 RRDsProcessed:0
11/13/2006 09:14:55 AM - POLLER: Poller[0] Maximum runtime of 292 seconds exceeded. Exiting.
11/13/2006 09:09:55 AM - SYSTEM STATS: Time:293.8692 Method:cmd.php Processes:1 Threads:N/A Hosts:2 HostsPerProcess:2 DataSources:5 RRDsProcessed:0
11/13/2006 09:09:55 AM - POLLER: Poller[0] Maximum runtime of 292 seconds exceeded. Exiting.
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

you can test cmd.php from the command line. Turn logging to DEBUG, and then from a command line "php <path_cacti>/cmd.php" Something is definately wrong...

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

hi The Witness,

Thanks again for your reply, it is very very much appreciated.

Excuse me for being a bit slow on the uptake when it comes to linux, but how do you turn on debugging?

I am using Ubuntu Dapper Drake........

also, if it turns out that I have been a bit silly and done something wrong then i completely apologise :wink:
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

oh dear....

i did...

sudo php /var/www/cacti/cmd.php and it said..

Could not open input file: /var/www/cacti/cmd.php

I looked in the /var/www/cacti and cmd.php is not even in there and neither is poller.php?!?!?

I then did, sudo whereis cmd.php and it returned no results........

could cmd.php be installed somewhere else?
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

ok found them, they are in /usr/share/cacti/site
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

guys

Im still having serious grief getting cacti to work.

If anyone can help out then that would be great.

Im now getting nan's on my graphs

i can run poller.php from command line with no errors, I can see no errors in the cacti log even on debug mode.

Its driving me mad lol :roll:

If someone can say to me....

go and get this info and paste it here, then get this and that I can do it no problem
unter_hosen
Posts: 12
Joined: Thu Nov 09, 2006 12:13 pm

Post by unter_hosen »

ok lemme go through what i am doing...

Ive added a device and SNMP is working...

ROUTER (10.10.10.252)
SNMP Information
System: Cisco Internetwork Operating System Software IOS (tm) C1700 Software (C1700-K9O3SY7-M), Version 12.3(3.7), MAINTENANCE INTERIM SOFTWARE Copyright (c) 1986-2003 by cisco Systems, Inc. Compiled Thu 21-Aug-03 04:07 by dchih
Uptime: 822462904 (95 days, 4 hours, 37 minutes)
Hostname: NET-10-VLANRTR.dayofdefeat.local
Location:
Contact:



I am then clicking, create graphs for this host where it displays interfaces for me to choose, I have fastethernet0, null0 and my two subinterfaces of fa0.10 and fa0.20.

i have chosen fa0.10 as this holds the IP address of the device on the same subnet as the cacti server.

I now go to graph management, select my graph and then turn on debug mode and now i am getting...

ERROR: opening '/var/www/cacti/rra/router_traffic_in_30.rrd': No such file or directory

when i look in that directory that rrd file doesnt exist as if its not being created.

im slowly losing the will to live lol :wink:
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Please try my "NaN Debugging" HowTo and report your findings step by step (linked in my signature)

Reinhard
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests