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 selecting a Consolidation Function, errors may be reported #4557

Closed
browniebraun opened this issue Feb 17, 2022 · 1 comment
Closed
Labels
bug Undesired behaviour

Comments

@browniebraun
Copy link
Member

Describe the bug

Only occurs if you are using a non-typical RRA profil. In my case only archive LAST will be created and used within the graph template.

Graph debug returns more than 20 times "Undefined offset: 1 ...." .

Solution

Simple to fix as the issue occurs in /lib/functions.php -- function generate_graph_best_cf:

image

Due to the reason that $avail_cf_functions hasn't been touched before line 2707

$best_cf = current($avail_cf_functions);

would be appropriate to return the first element.

Screenshots

image

  • Version
    Cacti 1.2.19 and above
@browniebraun browniebraun added bug Undesired behaviour unverified Some days we don't have a clue and removed unverified Some days we don't have a clue labels Feb 17, 2022
@TheWitness
Copy link
Member

Can you commit this?

@browniebraun browniebraun changed the title Undefined index messages while reviewing a graph in debug mode. Undefined index in graph debug mode Feb 18, 2022
browniebraun added a commit that referenced this issue Feb 18, 2022
#4557 - use reset to return the first element.
@netniV netniV changed the title Undefined index in graph debug mode When selecting a Consolidation Function, errors may be reported Apr 3, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Dec 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Undesired behaviour
Projects
None yet
Development

No branches or pull requests

2 participants