cacti icon indicating copy to clipboard operation
cacti copied to clipboard

[QA 1.3] graph error image does not contain any information

Open xmacan opened this issue 8 months ago • 3 comments

Display graph debug information if rrd file is missing says a lot of information:

  • image with "Failed to open data file ..."
  • correct rrdtool command
  • RRDtool Says: ERROR: opening '/usr/local/share/cacti/rra/pokus_fg_snmp_oid_35399.rrd': No such file or directory

In 1.3 I get only:

  • image unknown rrdtool error
  • empty rrdtool command
  • empty rrdtool Says:

xmacan avatar Apr 09 '25 20:04 xmacan

I had only few minutes for debug now. It seems that the code is very similar to 1.2.x. I don't know if it is any small bug or any bigger issue. I can look at it. @TheWitness any advice?

xmacan avatar Apr 09 '25 20:04 xmacan

@TheWitness I found it. Please check lib/rrd.php line 1815. Someone add these lines: if (!rrdtool_file_exists($data_source_path, $rrdtool_pipe)) { return false; }

It causes my issue. Without lines it works well. But I do not know the consequences of my modification or the reason for this condition. Please have a look at it

xmacan avatar Apr 10 '25 14:04 xmacan

Yea, we need to improve that. The file missing was causing other issues with export and ptile data. So, I think we can simply change the check to not fail if it's not export for example.

TheWitness avatar Apr 18 '25 16:04 TheWitness