Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When a device indexes have changed, it is not always reflected in the data #454

Closed
cigamit opened this issue Mar 20, 2017 · 117 comments
Closed
Labels
api API related issues bug Undesired behaviour
Milestone

Comments

@cigamit
Copy link
Member

cigamit commented Mar 20, 2017

Had a situation where when a device was rebooted, a volume with the label /volume1 changes from index 50 to index 51, and Cacti's re-indexing algorythm did not catch the index change. Also, after manually correcting the index numbers in the Database, subsequent re-indexing did not restore the graphs original name. In the past, this was handled during re-index.

@cigamit cigamit added the bug Undesired behaviour label Mar 20, 2017
@cigamit cigamit modified the milestones: Cacti Release 1.2.0, Cacti Release 1.3.0 Mar 27, 2017
@dagmoller
Copy link

Cacti must re-index when iface idb changes...

@cigamit cigamit added the api API related issues label Feb 6, 2018
@netniV
Copy link
Member

netniV commented Aug 3, 2018

This issue seems to be in two milestones. Which milestone should it be for?

image

@cigamit
Copy link
Member Author

cigamit commented Aug 7, 2018

Oh, that's odd. Well, I need to retest after all these recent changes from @hb9xar.

@cigamit
Copy link
Member Author

cigamit commented Aug 7, 2018

Could actually be resolved.

@netniV
Copy link
Member

netniV commented Sep 14, 2018

This may well be resolvd if you had the reindex set to verify all. There was a problem pre-1.2 were the index did not include the index name since around v1.0.5

@pautiina
Copy link
Contributor

Hello. I also have this problem on develop branch, but I use reindex on uptime

@netniV
Copy link
Member

netniV commented Sep 14, 2018

Can you reproduce it on FreeBSD using just the local machine??

@netniV
Copy link
Member

netniV commented Sep 14, 2018

And did you rerun the DB upgrade?

@pautiina
Copy link
Contributor

pautiina commented Sep 14, 2018

#Can you reproduce it on FreeBSD using just the local machine??
It,s can reproduce only after delete some vlan and reboot server.
I try repoduce on mondey

@netniV
Copy link
Member

netniV commented Sep 15, 2018

So this may also work by adding/removing nfs mounts.

@pautiina
Copy link
Contributor

@netniV Perhaps, I have this observed exactly on the traffic graphs.
Now I'm trying to repeat this problem. There is one server not loaded, which I can reboot.

@pautiina
Copy link
Contributor

pautiina commented Sep 17, 2018

And so I was able to repeat this bug.
Initial information. Worked with vlan800:
100
101
After that I deleted from server vlan 800 and restarted the server.
The graph remained from 800, but DS from the other interface, and all the following graphs also shifted.
102
After that, I returned the vlan 800 bus and added another vlan 799 and rebooted the server:
image

@netniV
Copy link
Member

netniV commented Sep 17, 2018

So, there's a question as to whether it's just the graph title that is wrong, since the data source has updated?

@pautiina
Copy link
Contributor

rrd file remains from the old ds

@netniV
Copy link
Member

netniV commented Sep 17, 2018

So, the RRD/Title aren't changing but the data source is?

@netniV
Copy link
Member

netniV commented Oct 5, 2018

Boo 👎 Just kidding. Have a good weekend, I'm going to be having a busy one!

@cigamit
Copy link
Member Author

cigamit commented Oct 6, 2018

Beta was delayed a week to work through this. See what you can do. Beta1 will likely go out in the next 24 hours regardless. Glad it started working for you. I put a lot of time into re-engineering this part of Cacti to make it make sense in all cases, and as a result make re-index a real fast process.

@cigamit
Copy link
Member Author

cigamit commented Oct 6, 2018

Found one minor issue. It's resolved now. Affected new installs mostly.

@pautiina
Copy link
Contributor

pautiina commented Oct 8, 2018

The problem is not solved until the end. After the server has rebooted - you must manually re-index.
I am glad that at least interface indices are preserved, and that there is no offset.

cacti01
cacti02

I sent an email with debug information.

@netniV
Copy link
Member

netniV commented Oct 8, 2018

Hi Alex,

Thanks for your logs, unfortunately they aren't showing anything like what I would expect. There appears to be no recaching going on at all. Can you let me know what is in Console -> Configuration -> Settings -> General -> Selective Device Debug ?

@netniV
Copy link
Member

netniV commented Oct 8, 2018

And also what the normal logging level is set to?

@netniV
Copy link
Member

netniV commented Oct 8, 2018

Also, what happens if you switch this to use the CMD.PHP rather than Spine?

@pautiina
Copy link
Contributor

pautiina commented Oct 8, 2018

Hi Alex,

Thanks for your logs, unfortunately they aren't showing anything like what I would expect. There appears to be no recaching going on at all. Can you let me know what is in Console -> Configuration -> Settings -> General -> Selective Device Debug ?

This menu item is empty.
image

@pautiina
Copy link
Contributor

pautiina commented Oct 8, 2018

Also, what happens if you switch this to use the CMD.PHP rather than Spine?

I'm afraid to do it. There are too many devices that are monitored

@pautiina
Copy link
Contributor

pautiina commented Oct 8, 2018

@netniV I sended mail for you

@cigamit
Copy link
Member Author

cigamit commented Oct 8, 2018

@Pautina, @netniV is looking into the spine code right now. I did make a change last night that before the change was evil. Only happens when you create a second network graph from the same interface (like bandwidth, Nth ptile, etc.), not sure that's your case. Seeing the cacti.log for a reboot would be important. Spine should log a reindex request, then there should be a POLLER output with a re-index confirmation after every reboot. Both appear in the log at LOW level.

@cigamit
Copy link
Member Author

cigamit commented Oct 8, 2018

@Pautina, is this device a local device or managed by a remote data collector?

@pautiina
Copy link
Contributor

pautiina commented Oct 8, 2018

Local

@pautiina
Copy link
Contributor

pautiina commented Oct 8, 2018

@cigamit I sended mail for you

@cigamit
Copy link
Member Author

cigamit commented Oct 10, 2018

From my perspective, uptime goes backwards is working with cmd.php, just going to check now with spine.

cigamit added a commit that referenced this issue Oct 10, 2018
If re-indexing fails, don't continue
cigamit added a commit that referenced this issue Oct 10, 2018
The logic on the query was flawed.
cigamit added a commit that referenced this issue Oct 10, 2018
Don't remap graphs to the new index until all the data sources have been
remapped.
cigamit added a commit that referenced this issue Oct 10, 2018
This will add some reporting.
@pautiina
Copy link
Contributor

Almost fixed.

cigamit added a commit that referenced this issue Oct 10, 2018
This change allows remapping to work even when a users has edited the
Data Source and forced an index.
@cigamit
Copy link
Member Author

cigamit commented Oct 10, 2018

This is fixed now including remapping of indexes and indexes that have been forced through the Data Sources page.

@cigamit cigamit closed this as completed Oct 10, 2018
@pautiina
Copy link
Contributor

Original bug fixed. A lot of work has been done to correct this bug. thank @cigamit

cigamit added a commit that referenced this issue Oct 11, 2018
Cacti Re-Index does not resolve index changes properly during re-index
@netniV netniV changed the title Cacti Re-Index does not resolve index changes properly during re-index When a device indexes have changed, it is not always reflected in the data Dec 27, 2018
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
api API related issues bug Undesired behaviour
Projects
None yet
Development

No branches or pull requests

4 participants