Cacti (home)ForumsDocumentation
Cacti: offical forums and support
It is currently Sun Aug 20, 2017 11:25 pm

All times are UTC - 5 hours




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: New RRDTOOL option "--showtime" in XPORT operations
PostPosted: Tue Jul 12, 2016 1:58 pm 
Offline

Joined: Thu Sep 08, 2005 8:09 am
Posts: 14
Location: Spain
Hello.

It seems in modern versions of RRDTOOL, specifically in 1.6.0, the original behavior to include the timestamp in each line when executing a XPORT does not work anymore, and that you need to include in the function call the option "--showtime" to get it back again.

To solve this a fast and dirty solution may be to add in the lib/rrd.php file the following three lines marked with ==> (after line 1249 based on the as per today development version on Github):

Code:
       /* +++++++++++++++++++++++ GRAPH OPTIONS +++++++++++++++++++++++ */

       if (!isset($graph_data_array['export_csv'])) {
              $graph_opts = rrd_function_process_graph_options($graph_start, $graph_end, $graph, $graph_data_array);
       }else{
              /* basic export options */
              $graph_opts =
                     '--start=' . cacti_escapeshellarg($graph_start) . RRD_NL .
                     '--end=' . cacti_escapeshellarg($graph_end) . RRD_NL .
                     '--maxrows=10000' . RRD_NL;
==>         if (read_config_option("rrdtool_version") == "rrd-1.6.x") {
==>            $graph_opts .= "--showtime" . RRD_NL;
==>         }
      }


Could you please consider this??

Many thanks and best regards.


Top
 Profile  
 
 Post subject: Re: New RRDTOOL option "--showtime" in XPORT operations
PostPosted: Tue Feb 07, 2017 9:54 pm 
Offline
Cacti User
User avatar

Joined: Mon Jan 05, 2015 10:10 am
Posts: 481
Please create a pull request on GitHub.

_________________
Before history, there was a paradise, now dust.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  

Protected by Anti-Spam ACP Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group