]> arthur.barton.de Git - netdata.git/blobdiff - src/global_statistics.c
multi-host rrdset and rrdfamily operations
[netdata.git] / src / global_statistics.c
index 62fc766bf1cd5e2d90c4bcb1a11313049afc08bb..ea23b154578fd2aaf44b8300c2bb586874f91d1f 100644 (file)
@@ -129,7 +129,7 @@ void global_statistics_charts(void) {
     getrusage(RUSAGE_THREAD, &thread);
     getrusage(RUSAGE_SELF, &me);
 
-    if (!stcpu_thread) stcpu_thread = rrdset_find("netdata.plugin_proc_cpu");
+    if (!stcpu_thread) stcpu_thread = rrdset_find_localhost("netdata.plugin_proc_cpu");
     if (!stcpu_thread) {
         stcpu_thread = rrdset_create("netdata", "plugin_proc_cpu", NULL, "proc", NULL,
                                      "NetData Proc Plugin CPU usage", "milliseconds/s", 132000, rrd_update_every,
@@ -145,7 +145,7 @@ void global_statistics_charts(void) {
 
     // ----------------------------------------------------------------
 
-    if (!stcpu) stcpu = rrdset_find("netdata.server_cpu");
+    if (!stcpu) stcpu = rrdset_find_localhost("netdata.server_cpu");
     if (!stcpu) {
         stcpu = rrdset_create("netdata", "server_cpu", NULL, "netdata", NULL, "NetData CPU usage", "milliseconds/s",
                               130000, rrd_update_every, RRDSET_TYPE_STACKED);
@@ -160,7 +160,7 @@ void global_statistics_charts(void) {
 
     // ----------------------------------------------------------------
 
-    if (!stclients) stclients = rrdset_find("netdata.clients");
+    if (!stclients) stclients = rrdset_find_localhost("netdata.clients");
     if (!stclients) {
         stclients = rrdset_create("netdata", "clients", NULL, "netdata", NULL, "NetData Web Clients",
                                   "connected clients", 130200, rrd_update_every, RRDSET_TYPE_LINE);
@@ -173,7 +173,7 @@ void global_statistics_charts(void) {
 
     // ----------------------------------------------------------------
 
-    if (!streqs) streqs = rrdset_find("netdata.requests");
+    if (!streqs) streqs = rrdset_find_localhost("netdata.requests");
     if (!streqs) {
         streqs = rrdset_create("netdata", "requests", NULL, "netdata", NULL, "NetData Web Requests", "requests/s",
                                130300, rrd_update_every, RRDSET_TYPE_LINE);
@@ -186,7 +186,7 @@ void global_statistics_charts(void) {
 
     // ----------------------------------------------------------------
 
-    if (!stbytes) stbytes = rrdset_find("netdata.net");
+    if (!stbytes) stbytes = rrdset_find_localhost("netdata.net");
     if (!stbytes) {
         stbytes = rrdset_create("netdata", "net", NULL, "netdata", NULL, "NetData Network Traffic", "kilobits/s",
                                 130000, rrd_update_every, RRDSET_TYPE_AREA);
@@ -201,7 +201,7 @@ void global_statistics_charts(void) {
 
     // ----------------------------------------------------------------
 
-    if (!stduration) stduration = rrdset_find("netdata.response_time");
+    if (!stduration) stduration = rrdset_find_localhost("netdata.response_time");
     if (!stduration) {
         stduration = rrdset_create("netdata", "response_time", NULL, "netdata", NULL, "NetData API Response Time",
                                    "ms/request", 130400, rrd_update_every, RRDSET_TYPE_LINE);
@@ -232,7 +232,7 @@ void global_statistics_charts(void) {
 
     // ----------------------------------------------------------------
 
-    if (!stcompression) stcompression = rrdset_find("netdata.compression_ratio");
+    if (!stcompression) stcompression = rrdset_find_localhost("netdata.compression_ratio");
     if (!stcompression) {
         stcompression = rrdset_create("netdata", "compression_ratio", NULL, "netdata", NULL,
                                       "NetData API Responses Compression Savings Ratio", "percentage", 130500,