Graphs menu- tree mode : tree leafs disappearing

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

Moderators: Developers, Moderators

Post Reply
Canto
Posts: 12
Joined: Fri Mar 05, 2010 6:43 am

Graphs menu- tree mode : tree leafs disappearing

Post by Canto »

Hi everyone,

First my infos :

Linux RedHat
Cacti Version 0.8.7c
Cacti OS unix
SNMP Version net-snmp
RRDTool Version RRDTool 1.2.x
Hosts 813
Graphs 4746
Data Sources Script/Command: 2887
SNMP: 1150
SNMP Query: 2008
Script Query: 2
Total: 6047


For some time now, most of the tree menu (in Tree mode) disappears in the left tree frame after some modifications (new device and associated graphs, addition of some graphs for some existing device,...).
But the problem doesn't appear every time or for every modification/addition. Until now, I have not found a specific action that lead to this problem. Each time, the only solution I found is to restore my latest archive of the /var/lib/mysql/BD_CACTI directory (as I am not sure of the exact file that is used for the tree data ...)

Today, while the problem appeared once again, I have found some interesting clues :
when the menu frame was loaded in Firefox, I noticed an exclamation mark in the information bar of the browser( bottom left) , showing that there is a problem in the page. Looking at the message details, it appears that the "ou5" object doesn't exist. So i looked at the source of the menu frame : to my surprise, all the menu tree leafs are present in the source (even those not appearing in the page) and I have only those lines that include "ou5"

Code: Select all

...
....
ou6 = insFld(ou5, gFld("Groups traffic", "graph_view.php?action=tree&tree_id=98&leaf_id=3022"))
ou6.xID = "tree_98_leaf_3022"
ou6 = insFld(ou5, gFld("Interfaces Brodcasts/Multicasts", "graph_view.php?action=tree&tree_id=98&leaf_id=3240"))
ou6.xID = "tree_98_leaf_3240"
ou6 = insFld(ou5, gFld("Interfaces Errors", "graph_view.php?action=tree&tree_id=98&leaf_id=3023"))
ou6.xID = "tree_98_leaf_3023"
ou6 = insFld(ou5, gFld("Interfaces traffic", "graph_view.php?action=tree&tree_id=98&leaf_id=3351"))
ou6.xID = "tree_98_leaf_3351"
...
...
So I have lines referencing "ou5" but ou5 is not "instantiated" anywhere. So first leafs in the tree are displayed but once the script reaches the lines referencing the missing "ou5" and get an error, following leafs are not displayed.

So the question is : what can cause the menu not being generated correctly or maybe some information not correctly being inserted in the mysql table ?

Thanks in advance for your time on this...
rhaskins
Posts: 16
Joined: Thu Aug 31, 2006 8:37 am

Re: Graphs menu- tree mode : tree leafs disappearing

Post by rhaskins »

We're seeing a similar issue with our 0.8.7b installation. Does anyone have any thoughts as to what might be causing this issue?
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: Graphs menu- tree mode : tree leafs disappearing

Post by TheWitness »

It's a nasty bug that has not been addressed. What can happen is if two people are modifying the tree simultaneously, we don't a good way to interlock between who goes first in a change.

The way to correct the problem is to delete the tree items that are corrupt. The easy way to find them is to view a broken page and look for non-sequential incrementation decrementation of the insFld(XXX) statements. When you see the integer jump by more than 1, you have found your problem. Sorry about this. Been needing a rewrite for several years now.
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?
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests