RRD file stops being updated after template change

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

Moderators: Developers, Moderators

Post Reply
p59186
Posts: 5
Joined: Tue Dec 09, 2014 4:21 pm

RRD file stops being updated after template change

Post by p59186 »

Hi all,

I've come across an issue which is causing me some pain. It is easily reproducible.

Making any change to the Data Templates -> Interface - Traffic -> Data Source Name results in all hosts using that template to stop receiving updates to their associated RRD file, and consequently graph data stops.

The Name field is left unchecked (so all data sources presumably are updated when this field is changed).

As an example, the name I had prior to the change was "|host_description| - Traffic - |query_ifName| "
I entered an extra space before the word "Traffic" and saved the template. Cacti then spent a few seconds updating in the background.
After that point, an RRD file that was being updated every minute stopped being updated.

We then get warnings in the Cacti log for "WARNING: Poller Output Table not Empty".
The debug logs show that no rrdupdate command is run for hosts with this particular template.

Removing the added space from the name (ie returning the name back to its original value) does not resolve the issue, and we are left with all hosts associated with that template continuing to have no updates to their RRDs.

Any new graphs created using the same template work correctly.

I believe something is being updated within the MySQL tables which is removing the association between the data source and the RRD file.

All GUI debugs (data source) look ok and the RRD file path is correct.

We are using Cacti version 0.8.8b running on Ubuntu 14.04

I've extensively searched the forums today, but cannot find anybody with the exact same issue, thus my post.
How can I:
1) resolve my issue without re-creating 500+ graphs
2) allow future changes to a data source name without causing the issue again?
porzech
Posts: 23
Joined: Sat Apr 14, 2012 5:02 am

Re: RRD file stops being updated after template change

Post by porzech »

You can rebuild_pooler_cache but if You changed the template you will have to either delete old RRD's or use rrdtune to modify them to be compatible with new datatemplate
pooling frequency and heartbeat are rather easy to correct using rrdtune
Generaly changing template affects only newly created RRD's and graphs and does not update existing ones.
p59186
Posts: 5
Joined: Tue Dec 09, 2014 4:21 pm

Re: RRD file stops being updated after template change

Post by p59186 »

Many thanks for the quick response.

I've deleted a couple of affected RRD files, and on the next poller run, I can see the files are re-created. However, the RRDs are not populated with data and subsequently not updated on subsequent poller runs.
p59186
Posts: 5
Joined: Tue Dec 09, 2014 4:21 pm

Re: RRD file stops being updated after template change

Post by p59186 »

Further to this I've managed to find a change that happens in the DB when the Data Template is modified.
The value of the rrd_num column in the poller_item table on a particular data source is set to 2 when a traffic graph is created and prior to a change to the template. At this value, the returned poller output all populate into the RRD files and the graphs are updated.

However...

After the data template is modified, the values of the rrd_num column are changed to 14. This is when the returned poller output is not updated into the RRD files.

I manually ran the following MySQL command to restore function:
update poller_item set rrd_num=2 where rrd_num=14;

So, I'm back up and working now, but would like to know why this changes.

Is this a bug? Surely the value should remain at 2 (whatever that does I do not know - maybe this triggers RRD updates?).
p59186
Posts: 5
Joined: Tue Dec 09, 2014 4:21 pm

Re: RRD file stops being updated after template change

Post by p59186 »

Bump.
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Re: RRD file stops being updated after template change

Post by BSOD2600 »

Why are you attempting to alter the DS name? If you want the title changed, there is a better way of accomplishing that.
data queries -> snmp interface -> select a graph type -> now either reorder and/or modify the Graph/Data template Title fields to meet your need.
then in either graph or data template management, select the existing graph(s), action menu (bottom right corner), reapply suggest names. hit ok.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest