]> git.ipfire.org Git - thirdparty/collectd.git/commitdiff
src/virt.c: Importing changes from `main`.
authorFlorian Forster <octo@collectd.org>
Tue, 19 Dec 2023 08:51:56 +0000 (09:51 +0100)
committerFlorian Forster <octo@collectd.org>
Mon, 22 Jan 2024 20:22:04 +0000 (21:22 +0100)
Changes:
b4bdc7a8486683533185db34f97fd0f219fdc36b Fix the virt plugin for Openstack wallaby and later use (#4011)
8c781279e9c4789936323670b729f9a979c976db virt: Add hugetlb_ metrics

src/virt.c

index 01c7c7771d2e1a95384f24ae8c30f6c089cefa38..4ba0d07cd697a7be8f2c120b6251613fa803aa6c 100644 (file)
@@ -736,7 +736,7 @@ static void set_field_from_metadata(value_list_t *vl, virDomainPtr dom,
 
   const char *namespace = NULL;
   if (hm_ns == NULL) {
-    namespace = "http://openstack.org/xmlns/libvirt/nova/1.0";
+    namespace = "http://openstack.org/xmlns/libvirt/nova/1.1";
   } // namespace =hm_ns;
   else {
     namespace = hm_ns;
@@ -937,10 +937,11 @@ static void memory_submit(virDomainPtr dom, gauge_t value) {
 
 static void memory_stats_submit(gauge_t value, virDomainPtr dom,
                                 int tag_index) {
-  static const char *tags[] = {"swap_in",        "swap_out",   "major_fault",
-                               "minor_fault",    "unused",     "available",
-                               "actual_balloon", "rss",        "usable",
-                               "last_update",    "disk_caches"};
+  static const char *tags[] = {
+      "swap_in",       "swap_out",    "major_fault",    "minor_fault",
+      "unused",        "available",   "actual_balloon", "rss",
+      "usable",        "last_update", "disk_caches",    "hugetlb_pgalloc",
+      "hugetlb_pgfail"};
 
   if ((tag_index < 0) || (tag_index >= (int)STATIC_ARRAY_SIZE(tags))) {
     ERROR(PLUGIN_NAME " plugin: Array index out of bounds: tag_index = %d",