Hide mem_private_usage on Windows. (#21093)
thiagoftsm committed
Oct 4, 2025 at 00:27 UTC
6b6148d5200bf7a0b59aa252b6d20b3957402d18
1 file changed
+4
src/collectors/apps.plugin/apps_output.c
+4
@@ -138,6 +138,7 @@ void send_collected_data_to_netdata(struct target *root, const char *type, usec_
138
}
139
#endif
140
141
+#ifndef OS_WINDOWS
142
send_BEGIN(type, string2str(w->clean_name), "mem_private_usage", dt);
143
#if (PROCESSES_HAVE_VMSHARED == 1)
144
send_SET("mem", (w->values[PDF_VMRSS] > w->values[PDF_VMSHARED])?(w->values[PDF_VMRSS] - w->values[PDF_VMSHARED]) : 0ULL);
@@ -145,6 +146,7 @@ void send_collected_data_to_netdata(struct target *root, const char *type, usec_
146
send_SET("mem", w->values[PDF_VMRSS]);
147
#endif
148
send_END();
149
+#endif //OS_WINDOWS
150
151
#if (PROCESSES_HAVE_VOLCTX == 1) || (PROCESSES_HAVE_NVOLCTX == 1)
152
send_BEGIN(type, string2str(w->clean_name), "cpu_context_switches", dt);
@@ -312,11 +314,13 @@ void send_charts_updates_to_netdata(struct target *root, const char *type, const
314
}
315
#endif
316
317
+#ifndef OS_WINDOWS
318
fprintf(stdout, "CHART %s.%s_mem_private_usage '' '%s memory usage without shared' 'MiB' mem %s.mem_private_usage area 20050 %d\n",
319
type, string2str(w->clean_name), title, type, update_every);
320
fprintf(stdout, "CLABEL '%s' '%s' 1\n", lbl_name, string2str(w->name));
321
fprintf(stdout, "CLABEL_COMMIT\n");
322
fprintf(stdout, "DIMENSION mem '' absolute %ld %ld\n", 1L, 1024L * 1024L);
323
+#endif //OS_WINDOWS
324
325
#if (PROCESSES_HAVE_VOLCTX == 1) || (PROCESSES_HAVE_NVOLCTX == 1)
326
fprintf(stdout, "CHART %s.%s_cpu_context_switches '' '%s CPU context switches' 'switches/s' cpu %s.cpu_context_switches stacked 20010 %d\n",