Menu

#8 build index sould build indexs for the previous day

open-works-for-me
Build Index (1)
5
2003-10-23
2003-10-23
Ted Cabeen
No

build_indexes.pl currently builds the index files for
the current day. Since the data we're putting into the
RRD files is for the previous day, the INDEX files
should also be created for the previous day, not the
current day that we don't have any data for yet.

The line:
$options_ref->{'ts'} = localtime;

should be changed to:
my $time = localtime;
$options_ref->{'ts'} = $time - 86400;

Thanks.

--Ted

Discussion

  • Todd A. Green

    Todd A. Green - 2003-10-23

    Logged In: YES
    user_id=186122

    Which version are you using.

    The current version supports the reading of current days
    data directly from the Cricket RRD files.

    So a better way to handle it would be for it to verify that
    the indexes for both yesterday and today are written.

     
  • Todd A. Green

    Todd A. Green - 2003-10-23
    • assigned_to: nobody --> slarti71
    • status: open --> pending-works-for-me
     
  • Ted Cabeen

    Ted Cabeen - 2003-10-23
    • status: pending-works-for-me --> open-works-for-me
     
  • Ted Cabeen

    Ted Cabeen - 2003-10-23

    Logged In: YES
    user_id=40466

    I'm running the latest version.

    IWriting indexes for both days isn't a bad idea. It was
    confusing when I was setting up that according to the docs
    the program should be getting the data from the previous
    day, but the web interface would only show today's data..
    For now I've implemented my change here, but I'll look
    forward to a better solution in the next version.

    Thanks for all of the good work. It looks like a nice program.

     

Log in to post a comment.

MongoDB Logo MongoDB