vl.values_len = 1;
sstrncpy (vl.type, "memory", sizeof (vl.type));
+ sstrncpy (vl.type_instance, "total", sizeof (vl.type_instance));
plugin_dispatch_values (&vl);
}
continue;
}
+ if (info.state != VIR_DOMAIN_RUNNING)
+ {
+ /* only gather stats for running domains */
+ continue;
+ }
+
cpu_submit (info.cpuTime, domains[i], "virt_cpu_total");
memory_submit ((gauge_t) info.memory * 1024, domains[i]);