[Orca-users] Re: rebuild rrd files from percol files

Blair Zajac blair at akamai.com
Mon Feb 5 13:44:45 PST 2001


John,

The attached patch should fix this problem.  Let me know if you can
load all of the data files in one pass with the patch installed.  If
it does not work, as there may be something else going on.

Regards,
Blair

jon.tankersley at sabre.com wrote:
> 
> I've got some more 'input' for you guys on this one.
> 
> I've been seeing this too.  Three directories with percol files in
> them:  XXX/percol...2001-01-20.gz through 30.gz.  YYY with
> 2001-01-05.gz through 30.gz, ZZZ with 01-05 through 01-30.
> 
> Destroying the RRD and html and png and ... and running orca again
> gives valid 'daily' plots, but the 'weekly' has 01-21 through 01-24
> missing from EACH system, despite the existance of the percol files.
> 
> Some interesting issues noticed with the -v flag for orca.
> 
> 01-29 01-20 01-21 01-27 01-22 ... are the order of the percol files
> processed.
> 
> Some data lines in the percol files don't have the right number of
> columns.  This should be eliminating that data point, not the entire
> file.  I'm also not sure WHY this is happening, but then I'm testing
> some hacks to diskinfo.se in the SEToolkit.
> 
> The data was gathered out of order (ftp problems).  Rebuilding the
> directories XXX,YYY,ZZZ with the files in the correct order didn't do
> any good.  Same 'parse' order as above.
> 
> I've started a rebuild copying one file at a time into the XXX,YYY,ZZZ
> directory and running orca -o.  It isn't done yet.
> 
> >From the code, it looks like the names are stored in a hash instead of
> an array or some such.  This seems to be overriding the date order.
> 
> ------------------------ Yahoo! Groups Sponsor ---------------------~-~>
> eGroups is now Yahoo! Groups
> Click here for more details
> http://click.egroups.com/1/11231/1/_/804404/_/980959924/
> ---------------------------------------------------------------------_->
-------------- next part --------------
--- ../orca-0.26/src/orca.pl.in	Thu Mar  9 14:49:59 2000
+++ src/orca.pl.in	Mon Feb  5 11:19:09 2001
@@ -965,17 +965,23 @@
 
     # Create a new list of filenames sorted by subgroup name and
     # inside each subgroup sorted using the filename_compare
-    # configuration option function or by the Perl cmp function.  This
-    # will cause the created plots to appear in subgroup order.  The
-    # compare subroutine expects the input in the $a and $b package
-    # variables.  Since the subroutine was eval'ed in the Orca::Config
-    # package, the sort subroutine needs be in that package.
+    # configuration file function or by the default compare function
+    # that uses cmp to compare filenames.  This will cause the created
+    # plots to appear in subgroup order.  Note that the FIDs are not
+    # being sorted, but the filename the FID references.
+    #
+    # The compare subroutine expects the input in the $a and $b
+    # package variables and since the compare subroutine was eval'ed
+    # in the Orca::Config package, the compare subroutine needs be run
+    # in Orca::Config.  Also, since sort cannot be passed a reference
+    # to a sorting subroutine stored in a hash (i.e. sort $a{b} @c),
+    # use a temporary variable.
     @fids = ();
     {
-      local *Orca::Config::fc = $config_groups{$group_name}{filename_compare};
+      package Orca::Config;
+      my $fc = $config_groups{$group_name}{filename_compare};
       foreach my $subgroup (sort keys %tmp_fids_by_subgroup) {
-        push(@fids,
-             sort Orca::Config::fc @{$tmp_fids_by_subgroup{$subgroup}});
+        push(@fids, sort $fc @{$tmp_fids_by_subgroup{$subgroup}});
       }
     }
 


More information about the Orca-users mailing list