summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Jones <rjones@trick.home.annexia.org>2009-10-05 15:54:49 +0100
committerRichard Jones <rjones@trick.home.annexia.org>2009-10-05 15:54:49 +0100
commit8df5161552e759dc4c9c2e74e3dc480f9f51f077 (patch)
tree391b78607bd75bc780421811b12305c5be8c8807
parent2624e889aa00a2027ebb96d0b12ff1347292e830 (diff)
downloadvirt-top-8df5161552e759dc4c9c2e74e3dc480f9f51f077.zip
virt-top-8df5161552e759dc4c9c2e74e3dc480f9f51f077.tar.gz
virt-top-8df5161552e759dc4c9c2e74e3dc480f9f51f077.tar.xz
Add total hardware memory field (RHBZ#521785)
-rw-r--r--virt-top/virt_top.ml5
1 files changed, 4 insertions, 1 deletions
diff --git a/virt-top/virt_top.ml b/virt-top/virt_top.ml
index 730f1cf..5c7e265 100644
--- a/virt-top/virt_top.ml
+++ b/virt-top/virt_top.ml
@@ -1181,7 +1181,9 @@ let write_csv_header () =
[ "Hostname"; "Time"; "Arch"; "Physical CPUs";
"Count"; "Running"; "Blocked"; "Paused"; "Shutdown";
"Shutoff"; "Crashed"; "Active"; "Inactive";
- "%CPU"; "Total memory (KB)"; "Total guest memory (KB)";
+ "%CPU";
+ "Total hardware memory (KB)";
+ "Total memory (KB)"; "Total guest memory (KB)";
"Total CPU time (ns)" ] @
(* These fields are repeated for each domain: *)
[ "Domain ID"; "Domain name"; ] @
@@ -1212,6 +1214,7 @@ let append_csv
string_of_int paused; string_of_int shutdown; string_of_int shutoff;
string_of_int crashed; string_of_int active; string_of_int inactive;
sprintf "%2.1f" percent_cpu;
+ Int64.to_string node_info.C.memory;
Int64.to_string total_memory; Int64.to_string total_domU_memory;
Int64.to_string (Int64.of_float total_cpu_time)
] in