Thanks Andreas,

that explains that.

So the warning can be made to go by changing line 183 in lustre-info.pl from

printf(", %s=%5.1f R/s",$type,$stats->{$type}/$slice)

to be

if (exists $stats->{$type})
{ printf(", %s=%5.1f R/s",$type,$stats->{$type}/$slice); }

(patch attached)

Tina

Andreas Dilger wrote:
On 2010-07-29, at 09:08, Frederik Ferner wrote:
Note the 'Use of uninitialized value in division...' errors. Looking at the code it seems the value for 'setattr' is missing from the stats file for some of our OSTs. Looking at the stats file, indeed the setattr line is missing for some OSTs.

Has anyone seen this before? What could have caused this?

The statistics code for OBD devices is generic.  For operations that have never been done on a 
particular target there is no stats value printed.  Otherwise, the "stats" file would be 
60 lines long and mostly be filled with counters that are all "0".

Cheers, Andreas
--
Andreas Dilger
Lustre Technical Lead
Oracle Corporation Canada Inc.

_______________________________________________
Lustre-discuss mailing list
[email protected]
http://lists.lustre.org/mailman/listinfo/lustre-discuss



--
Tina Friedrich, Computer Systems Administrator, Diamond Light Source Ltd
Diamond House, Harwell Science and Innovation Campus - 01235 77 8442
--- lustre-info.pl      2010-07-29 17:45:10.000000000 +0100
+++ lustre-info.pl_new  2010-07-29 17:45:54.000000000 +0100
@@ -180,7 +180,8 @@ sub loop_ost_stats {
                        
                        # Add some 'metadata' info
                        foreach my $type (qw(create destroy setattr preprw)) {
-                               printf(", %s=%5.1f 
R/s",$type,$stats->{$type}/$slice);
+                               if (exists $stats->{$type})
+                                       { printf(", %s=%5.1f 
R/s",$type,$stats->{$type}/$slice); }
                        }
                        print "\n";
                }
_______________________________________________
Lustre-discuss mailing list
[email protected]
http://lists.lustre.org/mailman/listinfo/lustre-discuss

Reply via email to