]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
cephfs-top: display latency in milliseconds
authorVenky Shankar <vshankar@redhat.com>
Wed, 19 May 2021 05:29:15 +0000 (01:29 -0400)
committerNeeraj Pratap Singh <neesingh@redhat.com>
Mon, 5 Sep 2022 13:48:09 +0000 (19:18 +0530)
Signed-off-by: Venky Shankar <vshankar@redhat.com>
(cherry picked from commit bf261f2a07111361ec8db36a7a4b13b54ff5d891)

src/tools/cephfs/top/cephfs-top

index 4921a894adbf2ac588bb77abed10910fa1bada76..4d359211f246f2f124970a9ceb840d354f072332 100755 (executable)
@@ -108,7 +108,7 @@ def calc_perc(c):
 
 
 def calc_lat(c):
-    return round(c[0] + c[1] / 1000000000, 2)
+    return round(c[0] * 1000 + c[1] / 1000000, 2)
 
 
 def calc_stdev(c):
@@ -268,7 +268,7 @@ class FSTop(object):
         if typ == MetricType.METRIC_TYPE_PERCENTAGE:
             return "(%)"
         elif typ == MetricType.METRIC_TYPE_LATENCY:
-            return "(s)"
+            return "(ms)"
         elif typ == MetricType.METRIC_TYPE_SIZE:
             return "(MB)"
         elif typ == MetricType.METRIC_TYPE_STDEV: