When I put more than 4 days it shows the graphs correctly but when I put less than four days like 3,2,1 day it shows the same last day graph for those.
How can I check what the issue is?
Cacti Presets not showing correctly for less than 4 days
Moderators: Developers, Moderators
-
- Posts: 35
- Joined: Thu Aug 15, 2019 12:10 pm
-
- Posts: 35
- Joined: Thu Aug 15, 2019 12:10 pm
Re: Cacti Presets not showing correctly for less than 4 days
Please let me know how it goes for you. My issue started this week and I do not know what to check or what could cause it.
-
- Posts: 35
- Joined: Thu Aug 15, 2019 12:10 pm
Re: Cacti Presets not showing correctly for less than 4 days
@tenpin784 I have version 1.1.38 not sure if it will work for me but I will take a look at those files. So now you can presets is working correctly for you?
-
- Posts: 35
- Joined: Thu Aug 15, 2019 12:10 pm
Re: Cacti Presets not showing correctly for less than 4 days
@tenpin784 thank you so much!! It worked for me
Re: Cacti Presets not showing correctly for less than 4 days
Worked on 0.8.8b, though I only had to edit 2 files
graph_image.php and graph_xport.php
Also, info was a bit different, for example this is from graph_image.php
/* override: graph start time (unix time) */
if (!empty($_GET["graph_start"]) && $_GET["graph_start"] < 1600000000) {
$graph_data_array["graph_start"] = $_GET["graph_start"];
}
/* override: graph end time (unix time) */
if (!empty($_GET["graph_end"]) && $_GET["graph_end"] < 1600000000) {
$graph_data_array["graph_end"] = $_GET["graph_end"];
}
Once replaced 1600000000 with FILTER_VALIDATE_MAX_DATE_AS_INT - accordingly to https://github.com/Cacti/cacti/commit/b ... dc8b18c1b7 I was working. I also restarted the OS, though I'm not 100% sure if this is required.
graph_image.php and graph_xport.php
Also, info was a bit different, for example this is from graph_image.php
/* override: graph start time (unix time) */
if (!empty($_GET["graph_start"]) && $_GET["graph_start"] < 1600000000) {
$graph_data_array["graph_start"] = $_GET["graph_start"];
}
/* override: graph end time (unix time) */
if (!empty($_GET["graph_end"]) && $_GET["graph_end"] < 1600000000) {
$graph_data_array["graph_end"] = $_GET["graph_end"];
}
Once replaced 1600000000 with FILTER_VALIDATE_MAX_DATE_AS_INT - accordingly to https://github.com/Cacti/cacti/commit/b ... dc8b18c1b7 I was working. I also restarted the OS, though I'm not 100% sure if this is required.
Re: Cacti Presets not showing correctly for less than 4 days
Thanks for this topic, i was looking why i couldn't have my graphs from several days
This helped me fixing the values in graph_image.php and graph_xport.php with adding the constant in globals
This helped me fixing the values in graph_image.php and graph_xport.php with adding the constant in globals
Who is online
Users browsing this forum: No registered users and 1 guest