Whamcloud - gitweb
LU-5231 hsm: display file size in decimal not hex 78/13678/3
authorFrank Zago <fzago@cray.com>
Fri, 6 Feb 2015 19:55:07 +0000 (13:55 -0600)
committerOleg Drokin <oleg.drokin@intel.com>
Sun, 8 Mar 2015 11:49:53 +0000 (11:49 +0000)
'lfs hsm_action' displays the file sizes in hex:
  somebigfile: ARCHIVE running (0xf1c00000 bytes moved)

This is not user friendly. Use decimal instead.

Remove the last occurences of LPX64 in lfs.

Signed-off-by: frank zago <fzago@cray.com>
Change-Id: Ib964c162b275bc836104cec3500a2f03c73dffeb
Reviewed-on: http://review.whamcloud.com/13678
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Henri Doreau <henri.doreau@cea.fr>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
lustre/utils/lfs.c

index f2668ae..9d51838 100644 (file)
@@ -3750,12 +3750,15 @@ static int lfs_hsm_action(int argc, char **argv)
 
                if ((hps == HPS_RUNNING) &&
                    (hua == HUA_ARCHIVE || hua == HUA_RESTORE))
-                       printf("("LPX64 " bytes moved)\n", he.length);
+                       printf("(%llu bytes moved)\n",
+                              (unsigned long long)he.length);
                else if ((he.offset + he.length) == LUSTRE_EOF)
-                       printf("(from "LPX64 " to EOF)\n", he.offset);
+                       printf("(from %llu to EOF)\n",
+                              (unsigned long long)he.offset);
                else
-                       printf("(from "LPX64 " to "LPX64")\n",
-                              he.offset, he.offset + he.length);
+                       printf("(from %llu to %llu)\n",
+                              (unsigned long long)he.offset,
+                              (unsigned long long)(he.offset + he.length));
 
        } while (++i < argc);