[Solved] host graph snmp query issues

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

Moderators: Developers, Moderators

Post Reply
btomjack
Posts: 19
Joined: Mon Aug 13, 2007 11:09 am

[Solved] host graph snmp query issues

Post by btomjack »

i am running Version 0.8.7b fully patched. my problem seems to have started after a large power outage where the core network went down where this cacti installation is hosted.

here is my problem:

i can no longer add graphs to hosts, when i do it it returns a message saying that the data query returned 0 rows. however this is not true. when the query is run in debug mode it returns all the necessary data. and i can manually probe the remote hosts using snmpwalk.

i guess i don't really have a clue what is causing this because snmp is working and returning queries but not to the add graph screen. if anyone has seen this before or has any suggestions that would be greatly appreciated.

attached are 3 screen shots, the screen where it tells me i have no rows in the query. one showing the same query in 'debug mode' and a 3rd showing the summary of the query from the edit host screen.
Attachments
query summary on the edit host screen
query summary on the edit host screen
edithost.JPG (22.14 KiB) Viewed 2995 times
query in debug mode
query in debug mode
snmpquery.JPG (83.56 KiB) Viewed 2995 times
when trying to add a new graph
when trying to add a new graph
addgraph.JPG (38.87 KiB) Viewed 2995 times
Last edited by btomjack on Wed Jul 23, 2008 3:33 pm, edited 1 time in total.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Please verify, that your httpd's user is allowed to update cacti.log. Then, please visit again the "Create Graphs for this Host" page and see, if any error message is found in cacti.log
Reinhard
btomjack
Posts: 19
Joined: Mon Aug 13, 2007 11:09 am

Post by btomjack »

i went ahead and turned up the logging to debug and clicked around on that host's page, however it resulted in no messages in the log file specificly relating to the host i was looking at there were errors in the log file, and they are as follows:

07/10/2008 10:41:35 AM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed!, Error:'1146', SQL:"SELECT name, file, function FROM plugin_hooks WHERE status = 1 AND hook = 'poller_bottom'"

07/10/2008 10:41:35 AM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed!, Error:'1146', SQL:"SELECT name, file, function FROM plugin_hooks WHERE status = 1 AND hook = 'poller_on_demand'"

07/10/2008 10:41:35 AM - CMDPHP: Poller[0] ERROR: SQL Assoc Failed!, Error:'1146', SQL:"SELECT name, file, function FROM plugin_hooks WHERE status = 1 AND hook = 'poller_output'"


these are the only critical items that appeared.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

That's from PIA only. That does not relate to your bug
Reinhard
btomjack
Posts: 19
Joined: Mon Aug 13, 2007 11:09 am

Post by btomjack »

any other ideas? i guess i dont really want to have to start all from scratch, including the sql db. to fix this unless its my last option.
killshoot
Cacti User
Posts: 84
Joined: Wed Mar 26, 2008 2:51 am

Post by killshoot »

Hi,

I've exactly the same problem since today ! :o

@btomjack :

have you find a workaround ?

Best regards,

Vince
killshoot
Cacti User
Posts: 84
Joined: Wed Mar 26, 2008 2:51 am

Post by killshoot »

Ok I've (momently ?) solved the problem :

1. Stop poller

2. run
php repair_database.php => no errors found

3. run
mysqlcheck --auto-repair --databases cacti

4. run
myisamchk -r host_snmp_cache.MYI

5. rebuild poller cache

6 restart poller

http://forums.cacti.net/viewtopic.php?t=27374
btomjack
Posts: 19
Joined: Mon Aug 13, 2007 11:09 am

Post by btomjack »

Ok I've (momently ?) solved the problem :

1. Stop poller

2. run
php repair_database.php => no errors found
same result for me.
3. run
mysqlcheck --auto-repair --databases cacti
all databases processed porperly
4. run
myisamchk -r host_snmp_cache.MYI
ran it on the specific MYI file with no result in the end so i also tried it with *.MYI
5. rebuild poller cache

6 restart poller

unfortunately after all that nothing seems to have changed. i agree that it is something to do with the SQL database, because this all started happening after a power outage hit the city where this server is, and after 4 hours on battery the computer lost power, however none of the checkers or repair utilities report any of the tables having any issues.
btomjack
Posts: 19
Joined: Mon Aug 13, 2007 11:09 am

Post by btomjack »

though, i did notice my poller cache showed empty when i viewed it before clearing it. however, running a show command on the poller's sql table showed there was data inside of it.
btomjack
Posts: 19
Joined: Mon Aug 13, 2007 11:09 am

Post by btomjack »

after playing around a little bit i rebuilt the poller cache from the command line, as opposed to in the web interface, and now things appear to be relatively normal again. i can create graphs, and the pages are no longer contradicting themselves with the information they are displaying.

thanks for the help with this Vince!
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests