Add global configuration option for zero metrics (#6419)
* Add global configuration option for zero metrics * Add the option to the cgroup plugin * Add the option to the proc plugin (diskstats, meminfo, net_dev, netstat, sctp_snmp, snmp, snmp6, sockstat, sockstat6, synproxy, vmstat, system_edac_mc, system_node, btrfs, ksm, zfs) * Add the option to the macos plugin * Add the option to the freebsd plugin (devstat, getifaddrs, getmntinfo, sysctl) * Change the option behaviour with the 'auto' value * Add the option to the tc plugin * Update the documentation
Vladimir Kobal committed
Jul 12, 2019 at 15:45 UTC
e8d6cde97c0bad7c598a3cc04c45603f0c942992
34 files changed
+767
-403
collectors/cgroups.plugin/README.md
+2
@@ -110,6 +110,8 @@ By default, Netdata will enable monitoring metrics only when they are not zero.
110
enable memory (used mem including cache) = yes
111
```
112
113
+You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
114
+
115
### alarms
116
117
CPU and memory limits are watched and used to rise alarms. Memory usage for every cgroup is checked against `ram` and `ram+swap` limits. CPU usage for every cgroup is checked against `cpuset.cpus` and `cpu.cfs_period_us` + `cpu.cfs_quota_us` pair assigned for the cgroup. Configuration for the alarms is available in `health.d/cgroups.conf` file.
collectors/cgroups.plugin/sys_fs_cgroup.c
+17
-11
@@ -575,7 +575,8 @@ static inline void cgroup_read_cpuacct_stat(struct cpuacct_stat *cp) {
575
576
cp->updated = 1;
577
578
- if(unlikely(cp->enabled == CONFIG_BOOLEAN_AUTO && (cp->user || cp->system)))
578
+ if(unlikely(cp->enabled == CONFIG_BOOLEAN_AUTO &&
579
+ (cp->user || cp->system || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
580
cp->enabled = CONFIG_BOOLEAN_YES;
581
}
582
}
@@ -611,7 +612,8 @@ static inline void cgroup2_read_cpuacct_stat(struct cpuacct_stat *cp) {
612
613
cp->updated = 1;
614
614
- if(unlikely(cp->enabled == CONFIG_BOOLEAN_AUTO && (cp->user || cp->system)))
615
+ if(unlikely(cp->enabled == CONFIG_BOOLEAN_AUTO &&
616
+ (cp->user || cp->system || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
617
cp->enabled = CONFIG_BOOLEAN_YES;
618
}
619
}
@@ -668,7 +670,8 @@ static inline void cgroup_read_cpuacct_usage(struct cpuacct_usage *ca) {
670
671
ca->updated = 1;
672
671
- if(unlikely(ca->enabled == CONFIG_BOOLEAN_AUTO && total))
673
+ if(unlikely(ca->enabled == CONFIG_BOOLEAN_AUTO &&
674
+ (total || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
675
ca->enabled = CONFIG_BOOLEAN_YES;
676
}
677
}
@@ -737,7 +740,7 @@ static inline void cgroup_read_blkio(struct blkio *io) {
740
io->updated = 1;
741
742
if(unlikely(io->enabled == CONFIG_BOOLEAN_AUTO)) {
740
- if(unlikely(io->Read || io->Write))
743
+ if(unlikely(io->Read || io->Write || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))
744
io->enabled = CONFIG_BOOLEAN_YES;
745
else
746
io->delay_counter = cgroup_recheck_zero_blkio_every_iterations;
@@ -787,7 +790,7 @@ static inline void cgroup2_read_blkio(struct blkio *io, unsigned int word_offset
790
io->updated = 1;
791
792
if(unlikely(io->enabled == CONFIG_BOOLEAN_AUTO)) {
790
- if(unlikely(io->Read || io->Write))
793
+ if(unlikely(io->Read || io->Write || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))
794
io->enabled = CONFIG_BOOLEAN_YES;
795
else
796
io->delay_counter = cgroup_recheck_zero_blkio_every_iterations;
@@ -881,7 +884,8 @@ static inline void cgroup_read_memory(struct memory *mem, char parent_cg_is_unif
884
if(( (!parent_cg_is_unified) && ( mem->total_cache || mem->total_dirty || mem->total_rss || mem->total_rss_huge || mem->total_mapped_file || mem->total_writeback
885
|| mem->total_swap || mem->total_pgpgin || mem->total_pgpgout || mem->total_pgfault || mem->total_pgmajfault))
886
|| (parent_cg_is_unified && ( mem->anon || mem->total_dirty || mem->kernel_stack || mem->slab || mem->sock || mem->total_writeback
884
- || mem->anon_thp || mem->total_pgfault || mem->total_pgmajfault)))
887
+ || mem->anon_thp || mem->total_pgfault || mem->total_pgmajfault))
888
+ || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)
889
mem->enabled_detailed = CONFIG_BOOLEAN_YES;
890
else
891
mem->delay_counter_detailed = cgroup_recheck_zero_mem_detailed_every_iterations;
@@ -893,14 +897,16 @@ memory_next:
897
// read usage_in_bytes
898
if(likely(mem->filename_usage_in_bytes)) {
899
mem->updated_usage_in_bytes = !read_single_number_file(mem->filename_usage_in_bytes, &mem->usage_in_bytes);
896
- if(unlikely(mem->updated_usage_in_bytes && mem->enabled_usage_in_bytes == CONFIG_BOOLEAN_AUTO && mem->usage_in_bytes))
900
+ if(unlikely(mem->updated_usage_in_bytes && mem->enabled_usage_in_bytes == CONFIG_BOOLEAN_AUTO &&
901
+ (mem->usage_in_bytes || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
902
mem->enabled_usage_in_bytes = CONFIG_BOOLEAN_YES;
903
}
904
905
// read msw_usage_in_bytes
906
if(likely(mem->filename_msw_usage_in_bytes)) {
907
mem->updated_msw_usage_in_bytes = !read_single_number_file(mem->filename_msw_usage_in_bytes, &mem->msw_usage_in_bytes);
903
- if(unlikely(mem->updated_msw_usage_in_bytes && mem->enabled_msw_usage_in_bytes == CONFIG_BOOLEAN_AUTO && mem->msw_usage_in_bytes))
908
+ if(unlikely(mem->updated_msw_usage_in_bytes && mem->enabled_msw_usage_in_bytes == CONFIG_BOOLEAN_AUTO &&
909
+ (mem->msw_usage_in_bytes || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
910
mem->enabled_msw_usage_in_bytes = CONFIG_BOOLEAN_YES;
911
}
912
@@ -913,10 +919,10 @@ memory_next:
919
else {
920
mem->updated_failcnt = !read_single_number_file(mem->filename_failcnt, &mem->failcnt);
921
if(unlikely(mem->updated_failcnt && mem->enabled_failcnt == CONFIG_BOOLEAN_AUTO)) {
916
- if(unlikely(!mem->failcnt))
917
- mem->delay_counter_failcnt = cgroup_recheck_zero_mem_failcnt_every_iterations;
918
- else
922
+ if(unlikely(mem->failcnt || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))
923
mem->enabled_failcnt = CONFIG_BOOLEAN_YES;
924
+ else
925
+ mem->delay_counter_failcnt = cgroup_recheck_zero_mem_failcnt_every_iterations;
926
}
927
}
928
}
collectors/diskspace.plugin/README.md
+1
-1
@@ -10,7 +10,7 @@ Two charts are available for every mount:
10
11
Simple patterns can be used to exclude mounts from showed statistics based on path or filesystem. By default read-only mounts are not displayed. To display them `yes` should be set for a chart instead of `auto`.
12
13
-By default, Netdata will enable monitoring metrics only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Set `yes` for a chart instead of `auto` to enable it permanently.
13
+By default, Netdata will enable monitoring metrics only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Set `yes` for a chart instead of `auto` to enable it permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
14
15
16
```
collectors/diskspace.plugin/plugin_diskspace.c
+6
-2
@@ -249,7 +249,9 @@ static inline void do_disk_space_stats(struct mountinfo *mi, int update_every) {
249
250
int rendered = 0;
251
252
- if(m->do_space == CONFIG_BOOLEAN_YES || (m->do_space == CONFIG_BOOLEAN_AUTO && (bavail || breserved_root || bused))) {
252
+ if(m->do_space == CONFIG_BOOLEAN_YES || (m->do_space == CONFIG_BOOLEAN_AUTO &&
253
+ (bavail || breserved_root || bused ||
254
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
255
if(unlikely(!m->st_space)) {
256
m->do_space = CONFIG_BOOLEAN_YES;
257
m->st_space = rrdset_find_bytype_localhost("disk_space", disk);
@@ -289,7 +291,9 @@ static inline void do_disk_space_stats(struct mountinfo *mi, int update_every) {
291
292
// --------------------------------------------------------------------------
293
292
- if(m->do_inodes == CONFIG_BOOLEAN_YES || (m->do_inodes == CONFIG_BOOLEAN_AUTO && (favail || freserved_root || fused))) {
294
+ if(m->do_inodes == CONFIG_BOOLEAN_YES || (m->do_inodes == CONFIG_BOOLEAN_AUTO &&
295
+ (favail || freserved_root || fused ||
296
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
297
if(unlikely(!m->st_inodes)) {
298
m->do_inodes = CONFIG_BOOLEAN_YES;
299
m->st_inodes = rrdset_find_bytype_localhost("disk_inodes", disk);
collectors/freebsd.plugin/README.md
+2
@@ -2,4 +2,6 @@
2
3
Collects resource usage and performance data on FreeBSD systems
4
5
+By default, Netdata will enable monitoring metrics for disks, memory, and network only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Use `yes` instead of `auto` in plugin configuration sections to enable these charts permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
6
+
7
[]()
collectors/freebsd.plugin/freebsd_devstat.c
+17
-8
@@ -352,7 +352,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
352
if(dm->do_io == CONFIG_BOOLEAN_YES || (dm->do_io == CONFIG_BOOLEAN_AUTO &&
353
(dstat[i].bytes[DEVSTAT_READ] ||
354
dstat[i].bytes[DEVSTAT_WRITE] ||
355
- dstat[i].bytes[DEVSTAT_FREE]))) {
355
+ dstat[i].bytes[DEVSTAT_FREE] ||
356
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
357
if (unlikely(!dm->st_io)) {
358
dm->st_io = rrdset_create_localhost("disk",
359
disk,
@@ -389,7 +390,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
390
(dstat[i].operations[DEVSTAT_READ] ||
391
dstat[i].operations[DEVSTAT_WRITE] ||
392
dstat[i].operations[DEVSTAT_NO_DATA] ||
392
- dstat[i].operations[DEVSTAT_FREE]))) {
393
+ dstat[i].operations[DEVSTAT_FREE] ||
394
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
395
if (unlikely(!dm->st_ops)) {
396
dm->st_ops = rrdset_create_localhost("disk_ops",
397
disk,
@@ -428,7 +430,9 @@ int do_kern_devstat(int update_every, usec_t dt) {
430
// --------------------------------------------------------------------
431
432
if(dm->do_qops == CONFIG_BOOLEAN_YES || (dm->do_qops == CONFIG_BOOLEAN_AUTO &&
431
- (dstat[i].start_count || dstat[i].end_count))) {
433
+ (dstat[i].start_count ||
434
+ dstat[i].end_count ||
435
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
436
if (unlikely(!dm->st_qops)) {
437
dm->st_qops = rrdset_create_localhost("disk_qops",
438
disk,
@@ -457,7 +461,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
461
// --------------------------------------------------------------------
462
463
if(dm->do_util == CONFIG_BOOLEAN_YES || (dm->do_util == CONFIG_BOOLEAN_AUTO &&
460
- cur_dstat.busy_time_ms)) {
464
+ (cur_dstat.busy_time_ms ||
465
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
466
if (unlikely(!dm->st_util)) {
467
dm->st_util = rrdset_create_localhost("disk_util",
468
disk,
@@ -490,7 +495,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
495
(cur_dstat.duration_read_ms ||
496
cur_dstat.duration_write_ms ||
497
cur_dstat.duration_other_ms ||
493
- cur_dstat.duration_free_ms))) {
498
+ cur_dstat.duration_free_ms ||
499
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
500
if (unlikely(!dm->st_iotime)) {
501
dm->st_iotime = rrdset_create_localhost("disk_iotime",
502
disk,
@@ -538,7 +544,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
544
(dstat[i].operations[DEVSTAT_READ] ||
545
dstat[i].operations[DEVSTAT_WRITE] ||
546
dstat[i].operations[DEVSTAT_NO_DATA] ||
541
- dstat[i].operations[DEVSTAT_FREE]))) {
547
+ dstat[i].operations[DEVSTAT_FREE] ||
548
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
549
if (unlikely(!dm->st_await)) {
550
dm->st_await = rrdset_create_localhost("disk_await",
551
disk,
@@ -603,7 +610,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
610
if(dm->do_avagsz == CONFIG_BOOLEAN_YES || (dm->do_avagsz == CONFIG_BOOLEAN_AUTO &&
611
(dstat[i].operations[DEVSTAT_READ] ||
612
dstat[i].operations[DEVSTAT_WRITE] ||
606
- dstat[i].operations[DEVSTAT_FREE]))) {
613
+ dstat[i].operations[DEVSTAT_FREE] ||
614
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
615
if (unlikely(!dm->st_avagsz)) {
616
dm->st_avagsz = rrdset_create_localhost("disk_avgsz",
617
disk,
@@ -660,7 +668,8 @@ int do_kern_devstat(int update_every, usec_t dt) {
668
(dstat[i].operations[DEVSTAT_READ] ||
669
dstat[i].operations[DEVSTAT_WRITE] ||
670
dstat[i].operations[DEVSTAT_NO_DATA] ||
663
- dstat[i].operations[DEVSTAT_FREE]))) {
671
+ dstat[i].operations[DEVSTAT_FREE] ||
672
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
673
if (unlikely(!dm->st_svctm)) {
674
dm->st_svctm = rrdset_create_localhost("disk_svctm",
675
disk,
collectors/freebsd.plugin/freebsd_getifaddrs.c
+17
-8
@@ -440,7 +440,9 @@ int do_getifaddrs(int update_every, usec_t dt) {
440
// --------------------------------------------------------------------
441
442
if (ifm->do_bandwidth == CONFIG_BOOLEAN_YES || (ifm->do_bandwidth == CONFIG_BOOLEAN_AUTO &&
443
- (IFA_DATA(ibytes) || IFA_DATA(obytes)))) {
443
+ (IFA_DATA(ibytes) ||
444
+ IFA_DATA(obytes) ||
445
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
446
if (unlikely(!ifm->st_bandwidth)) {
447
ifm->st_bandwidth = rrdset_create_localhost("net",
448
ifa->ifa_name,
@@ -469,7 +471,11 @@ int do_getifaddrs(int update_every, usec_t dt) {
471
// --------------------------------------------------------------------
472
473
if (ifm->do_packets == CONFIG_BOOLEAN_YES || (ifm->do_packets == CONFIG_BOOLEAN_AUTO &&
472
- (IFA_DATA(ipackets) || IFA_DATA(opackets) || IFA_DATA(imcasts) || IFA_DATA(omcasts)))) {
474
+ (IFA_DATA(ipackets) ||
475
+ IFA_DATA(opackets) ||
476
+ IFA_DATA(imcasts) ||
477
+ IFA_DATA(omcasts) ||
478
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
479
if (unlikely(!ifm->st_packets)) {
480
ifm->st_packets = rrdset_create_localhost("net_packets",
481
ifa->ifa_name,
@@ -508,7 +514,9 @@ int do_getifaddrs(int update_every, usec_t dt) {
514
// --------------------------------------------------------------------
515
516
if (ifm->do_errors == CONFIG_BOOLEAN_YES || (ifm->do_errors == CONFIG_BOOLEAN_AUTO &&
511
- (IFA_DATA(ierrors) || IFA_DATA(oerrors)))) {
517
+ (IFA_DATA(ierrors) ||
518
+ IFA_DATA(oerrors) ||
519
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
520
if (unlikely(!ifm->st_errors)) {
521
ifm->st_errors = rrdset_create_localhost("net_errors",
522
ifa->ifa_name,
@@ -538,11 +546,11 @@ int do_getifaddrs(int update_every, usec_t dt) {
546
// --------------------------------------------------------------------
547
548
if (ifm->do_drops == CONFIG_BOOLEAN_YES || (ifm->do_drops == CONFIG_BOOLEAN_AUTO &&
541
- (IFA_DATA(iqdrops)
549
+ (IFA_DATA(iqdrops) ||
550
#if __FreeBSD__ >= 11
543
- || IFA_DATA(oqdrops)
544
-#endif
545
- ))) {
551
+ IFA_DATA(oqdrops) ||
552
+ #endif
553
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
554
if (unlikely(!ifm->st_drops)) {
555
ifm->st_drops = rrdset_create_localhost("net_drops",
556
ifa->ifa_name,
@@ -577,7 +585,8 @@ int do_getifaddrs(int update_every, usec_t dt) {
585
// --------------------------------------------------------------------
586
587
if (ifm->do_events == CONFIG_BOOLEAN_YES || (ifm->do_events == CONFIG_BOOLEAN_AUTO &&
580
- IFA_DATA(collisions))) {
588
+ (IFA_DATA(collisions) ||
589
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
590
if (unlikely(!ifm->st_events)) {
591
ifm->st_events = rrdset_create_localhost("net_events",
592
ifa->ifa_name,
collectors/freebsd.plugin/freebsd_getmntinfo.c
+6
-2
@@ -216,7 +216,9 @@ int do_getmntinfo(int update_every, usec_t dt) {
216
217
int rendered = 0;
218
219
- if (m->do_space == CONFIG_BOOLEAN_YES || (m->do_space == CONFIG_BOOLEAN_AUTO && (mntbuf[i].f_blocks > 2))) {
219
+ if (m->do_space == CONFIG_BOOLEAN_YES || (m->do_space == CONFIG_BOOLEAN_AUTO &&
220
+ (mntbuf[i].f_blocks > 2 ||
221
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
222
if (unlikely(!m->st_space)) {
223
snprintfz(title, 4096, "Disk Space Usage for %s [%s]",
224
mntbuf[i].f_mntonname, mntbuf[i].f_mntfromname);
@@ -255,7 +257,9 @@ int do_getmntinfo(int update_every, usec_t dt) {
257
258
// --------------------------------------------------------------------------
259
258
- if (m->do_inodes == CONFIG_BOOLEAN_YES || (m->do_inodes == CONFIG_BOOLEAN_AUTO && (mntbuf[i].f_files > 1))) {
260
+ if (m->do_inodes == CONFIG_BOOLEAN_YES || (m->do_inodes == CONFIG_BOOLEAN_AUTO &&
261
+ (mntbuf[i].f_files > 1 ||
262
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
263
if (unlikely(!m->st_inodes)) {
264
snprintfz(title, 4096, "Disk Files (inodes) Usage for %s [%s]",
265
mntbuf[i].f_mntonname, mntbuf[i].f_mntfromname);
collectors/freebsd.plugin/freebsd_sysctl.c
+99
-61
@@ -1941,7 +1941,13 @@ int do_net_inet_tcp_stats(int update_every, usec_t dt) {
1941
1942
// --------------------------------------------------------------------
1943
1944
- if (do_tcpext_connaborts == CONFIG_BOOLEAN_YES || (do_tcpext_connaborts == CONFIG_BOOLEAN_AUTO && (tcpstat.tcps_rcvpackafterwin || tcpstat.tcps_rcvafterclose || tcpstat.tcps_rcvmemdrop || tcpstat.tcps_persistdrop || tcpstat.tcps_finwait2_drops))) {
1944
+ if (do_tcpext_connaborts == CONFIG_BOOLEAN_YES || (do_tcpext_connaborts == CONFIG_BOOLEAN_AUTO &&
1945
+ (tcpstat.tcps_rcvpackafterwin ||
1946
+ tcpstat.tcps_rcvafterclose ||
1947
+ tcpstat.tcps_rcvmemdrop ||
1948
+ tcpstat.tcps_persistdrop ||
1949
+ tcpstat.tcps_finwait2_drops ||
1950
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1951
do_tcpext_connaborts = CONFIG_BOOLEAN_YES;
1952
1953
static RRDSET *st = NULL;
@@ -1982,7 +1988,9 @@ int do_net_inet_tcp_stats(int update_every, usec_t dt) {
1988
1989
// --------------------------------------------------------------------
1990
1985
- if (do_tcpext_ofo == CONFIG_BOOLEAN_YES || (do_tcpext_ofo == CONFIG_BOOLEAN_AUTO && tcpstat.tcps_rcvoopack)) {
1991
+ if (do_tcpext_ofo == CONFIG_BOOLEAN_YES || (do_tcpext_ofo == CONFIG_BOOLEAN_AUTO &&
1992
+ (tcpstat.tcps_rcvoopack ||
1993
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1994
do_tcpext_ofo = CONFIG_BOOLEAN_YES;
1995
1996
static RRDSET *st = NULL;
@@ -2014,7 +2022,11 @@ int do_net_inet_tcp_stats(int update_every, usec_t dt) {
2022
2023
// --------------------------------------------------------------------
2024
2017
- if (do_tcpext_syncookies == CONFIG_BOOLEAN_YES || (do_tcpext_syncookies == CONFIG_BOOLEAN_AUTO && (tcpstat.tcps_sc_sendcookie || tcpstat.tcps_sc_recvcookie || tcpstat.tcps_sc_zonefail))) {
2025
+ if (do_tcpext_syncookies == CONFIG_BOOLEAN_YES || (do_tcpext_syncookies == CONFIG_BOOLEAN_AUTO &&
2026
+ (tcpstat.tcps_sc_sendcookie ||
2027
+ tcpstat.tcps_sc_recvcookie ||
2028
+ tcpstat.tcps_sc_zonefail ||
2029
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2030
do_tcpext_syncookies = CONFIG_BOOLEAN_YES;
2031
2032
static RRDSET *st = NULL;
@@ -2050,7 +2062,9 @@ int do_net_inet_tcp_stats(int update_every, usec_t dt) {
2062
2063
// --------------------------------------------------------------------
2064
2053
- if(do_tcpext_listen == CONFIG_BOOLEAN_YES || (do_tcpext_listen == CONFIG_BOOLEAN_AUTO && tcpstat.tcps_listendrop)) {
2065
+ if(do_tcpext_listen == CONFIG_BOOLEAN_YES || (do_tcpext_listen == CONFIG_BOOLEAN_AUTO &&
2066
+ (tcpstat.tcps_listendrop ||
2067
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2068
do_tcpext_listen = CONFIG_BOOLEAN_YES;
2069
2070
static RRDSET *st_listen = NULL;
@@ -2085,7 +2099,11 @@ int do_net_inet_tcp_stats(int update_every, usec_t dt) {
2099
2100
// --------------------------------------------------------------------
2101
2088
- if (do_ecn == CONFIG_BOOLEAN_YES || (do_ecn == CONFIG_BOOLEAN_AUTO && (tcpstat.tcps_ecn_ce || tcpstat.tcps_ecn_ect0 || tcpstat.tcps_ecn_ect1))) {
2102
+ if (do_ecn == CONFIG_BOOLEAN_YES || (do_ecn == CONFIG_BOOLEAN_AUTO &&
2103
+ (tcpstat.tcps_ecn_ce ||
2104
+ tcpstat.tcps_ecn_ect0 ||
2105
+ tcpstat.tcps_ecn_ect1 ||
2106
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2107
do_ecn = CONFIG_BOOLEAN_YES;
2108
2109
static RRDSET *st = NULL;
@@ -2626,8 +2644,11 @@ int do_net_inet6_ip6_stats(int update_every, usec_t dt) {
2644
// --------------------------------------------------------------------
2645
2646
if (do_ip6_packets == CONFIG_BOOLEAN_YES || (do_ip6_packets == CONFIG_BOOLEAN_AUTO &&
2629
- (ip6stat.ip6s_localout || ip6stat.ip6s_total ||
2630
- ip6stat.ip6s_forward || ip6stat.ip6s_delivered))) {
2647
+ (ip6stat.ip6s_localout ||
2648
+ ip6stat.ip6s_total ||
2649
+ ip6stat.ip6s_forward ||
2650
+ ip6stat.ip6s_delivered ||
2651
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2652
do_ip6_packets = CONFIG_BOOLEAN_YES;
2653
2654
static RRDSET *st = NULL;
@@ -2666,8 +2687,10 @@ int do_net_inet6_ip6_stats(int update_every, usec_t dt) {
2687
// --------------------------------------------------------------------
2688
2689
if (do_ip6_fragsout == CONFIG_BOOLEAN_YES || (do_ip6_fragsout == CONFIG_BOOLEAN_AUTO &&
2669
- (ip6stat.ip6s_fragmented || ip6stat.ip6s_cantfrag ||
2670
- ip6stat.ip6s_ofragments))) {
2690
+ (ip6stat.ip6s_fragmented ||
2691
+ ip6stat.ip6s_cantfrag ||
2692
+ ip6stat.ip6s_ofragments ||
2693
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2694
do_ip6_fragsout = CONFIG_BOOLEAN_YES;
2695
2696
static RRDSET *st = NULL;
@@ -2706,8 +2729,11 @@ int do_net_inet6_ip6_stats(int update_every, usec_t dt) {
2729
// --------------------------------------------------------------------
2730
2731
if (do_ip6_fragsin == CONFIG_BOOLEAN_YES || (do_ip6_fragsin == CONFIG_BOOLEAN_AUTO &&
2709
- (ip6stat.ip6s_reassembled || ip6stat.ip6s_fragdropped ||
2710
- ip6stat.ip6s_fragtimeout || ip6stat.ip6s_fragments))) {
2732
+ (ip6stat.ip6s_reassembled ||
2733
+ ip6stat.ip6s_fragdropped ||
2734
+ ip6stat.ip6s_fragtimeout ||
2735
+ ip6stat.ip6s_fragments ||
2736
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2737
do_ip6_fragsin = CONFIG_BOOLEAN_YES;
2738
2739
static RRDSET *st = NULL;
@@ -2747,16 +2773,17 @@ int do_net_inet6_ip6_stats(int update_every, usec_t dt) {
2773
2774
// --------------------------------------------------------------------
2775
2750
- if (do_ip6_errors == CONFIG_BOOLEAN_YES || (do_ip6_errors == CONFIG_BOOLEAN_AUTO && (
2751
- ip6stat.ip6s_toosmall ||
2752
- ip6stat.ip6s_odropped ||
2753
- ip6stat.ip6s_badoptions ||
2754
- ip6stat.ip6s_badvers ||
2755
- ip6stat.ip6s_exthdrtoolong ||
2756
- ip6stat.ip6s_sources_none ||
2757
- ip6stat.ip6s_tooshort ||
2758
- ip6stat.ip6s_cantforward ||
2759
- ip6stat.ip6s_noroute))) {
2776
+ if (do_ip6_errors == CONFIG_BOOLEAN_YES || (do_ip6_errors == CONFIG_BOOLEAN_AUTO &&
2777
+ (ip6stat.ip6s_toosmall ||
2778
+ ip6stat.ip6s_odropped ||
2779
+ ip6stat.ip6s_badoptions ||
2780
+ ip6stat.ip6s_badvers ||
2781
+ ip6stat.ip6s_exthdrtoolong ||
2782
+ ip6stat.ip6s_sources_none ||
2783
+ ip6stat.ip6s_tooshort ||
2784
+ ip6stat.ip6s_cantforward ||
2785
+ ip6stat.ip6s_noroute ||
2786
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2787
do_ip6_errors = CONFIG_BOOLEAN_YES;
2788
2789
static RRDSET *st = NULL;
@@ -2872,7 +2899,10 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
2899
2900
// --------------------------------------------------------------------
2901
2875
- if (do_icmp6 == CONFIG_BOOLEAN_YES || (do_icmp6 == CONFIG_BOOLEAN_AUTO && (icmp6_total.msgs_in || icmp6_total.msgs_out))) {
2902
+ if (do_icmp6 == CONFIG_BOOLEAN_YES || (do_icmp6 == CONFIG_BOOLEAN_AUTO &&
2903
+ (icmp6_total.msgs_in ||
2904
+ icmp6_total.msgs_out ||
2905
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2906
do_icmp6 = CONFIG_BOOLEAN_YES;
2907
2908
static RRDSET *st = NULL;
@@ -2907,7 +2937,10 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
2937
2938
// --------------------------------------------------------------------
2939
2910
- if (do_icmp6_redir == CONFIG_BOOLEAN_YES || (do_icmp6_redir == CONFIG_BOOLEAN_AUTO && (icmp6stat.icp6s_inhist[ND_REDIRECT] || icmp6stat.icp6s_outhist[ND_REDIRECT]))) {
2940
+ if (do_icmp6_redir == CONFIG_BOOLEAN_YES || (do_icmp6_redir == CONFIG_BOOLEAN_AUTO &&
2941
+ (icmp6stat.icp6s_inhist[ND_REDIRECT] ||
2942
+ icmp6stat.icp6s_outhist[ND_REDIRECT] ||
2943
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2944
do_icmp6_redir = CONFIG_BOOLEAN_YES;
2945
2946
static RRDSET *st = NULL;
@@ -2941,18 +2974,19 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
2974
2975
// --------------------------------------------------------------------
2976
2944
- if (do_icmp6_errors == CONFIG_BOOLEAN_YES || (do_icmp6_errors == CONFIG_BOOLEAN_AUTO && (
2945
- icmp6stat.icp6s_badcode ||
2946
- icmp6stat.icp6s_badlen ||
2947
- icmp6stat.icp6s_checksum ||
2948
- icmp6stat.icp6s_tooshort ||
2949
- icmp6stat.icp6s_error ||
2950
- icmp6stat.icp6s_inhist[ICMP6_DST_UNREACH] ||
2951
- icmp6stat.icp6s_inhist[ICMP6_TIME_EXCEEDED] ||
2952
- icmp6stat.icp6s_inhist[ICMP6_PARAM_PROB] ||
2953
- icmp6stat.icp6s_outhist[ICMP6_DST_UNREACH] ||
2954
- icmp6stat.icp6s_outhist[ICMP6_TIME_EXCEEDED] ||
2955
- icmp6stat.icp6s_outhist[ICMP6_PARAM_PROB]))) {
2977
+ if (do_icmp6_errors == CONFIG_BOOLEAN_YES || (do_icmp6_errors == CONFIG_BOOLEAN_AUTO &&
2978
+ (icmp6stat.icp6s_badcode ||
2979
+ icmp6stat.icp6s_badlen ||
2980
+ icmp6stat.icp6s_checksum ||
2981
+ icmp6stat.icp6s_tooshort ||
2982
+ icmp6stat.icp6s_error ||
2983
+ icmp6stat.icp6s_inhist[ICMP6_DST_UNREACH] ||
2984
+ icmp6stat.icp6s_inhist[ICMP6_TIME_EXCEEDED] ||
2985
+ icmp6stat.icp6s_inhist[ICMP6_PARAM_PROB] ||
2986
+ icmp6stat.icp6s_outhist[ICMP6_DST_UNREACH] ||
2987
+ icmp6stat.icp6s_outhist[ICMP6_TIME_EXCEEDED] ||
2988
+ icmp6stat.icp6s_outhist[ICMP6_PARAM_PROB] ||
2989
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
2990
do_icmp6_errors = CONFIG_BOOLEAN_YES;
2991
2992
static RRDSET *st = NULL;
@@ -3005,11 +3039,12 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
3039
3040
// --------------------------------------------------------------------
3041
3008
- if (do_icmp6_echos == CONFIG_BOOLEAN_YES || (do_icmp6_echos == CONFIG_BOOLEAN_AUTO && (
3009
- icmp6stat.icp6s_inhist[ICMP6_ECHO_REQUEST] ||
3010
- icmp6stat.icp6s_outhist[ICMP6_ECHO_REQUEST] ||
3011
- icmp6stat.icp6s_inhist[ICMP6_ECHO_REPLY] ||
3012
- icmp6stat.icp6s_outhist[ICMP6_ECHO_REPLY]))) {
3042
+ if (do_icmp6_echos == CONFIG_BOOLEAN_YES || (do_icmp6_echos == CONFIG_BOOLEAN_AUTO &&
3043
+ (icmp6stat.icp6s_inhist[ICMP6_ECHO_REQUEST] ||
3044
+ icmp6stat.icp6s_outhist[ICMP6_ECHO_REQUEST] ||
3045
+ icmp6stat.icp6s_inhist[ICMP6_ECHO_REPLY] ||
3046
+ icmp6stat.icp6s_outhist[ICMP6_ECHO_REPLY] ||
3047
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
3048
do_icmp6_echos = CONFIG_BOOLEAN_YES;
3049
3050
static RRDSET *st = NULL;
@@ -3047,11 +3082,12 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
3082
3083
// --------------------------------------------------------------------
3084
3050
- if (do_icmp6_router == CONFIG_BOOLEAN_YES || (do_icmp6_router == CONFIG_BOOLEAN_AUTO && (
3051
- icmp6stat.icp6s_inhist[ND_ROUTER_SOLICIT] ||
3052
- icmp6stat.icp6s_outhist[ND_ROUTER_SOLICIT] ||
3053
- icmp6stat.icp6s_inhist[ND_ROUTER_ADVERT] ||
3054
- icmp6stat.icp6s_outhist[ND_ROUTER_ADVERT]))) {
3085
+ if (do_icmp6_router == CONFIG_BOOLEAN_YES || (do_icmp6_router == CONFIG_BOOLEAN_AUTO &&
3086
+ (icmp6stat.icp6s_inhist[ND_ROUTER_SOLICIT] ||
3087
+ icmp6stat.icp6s_outhist[ND_ROUTER_SOLICIT] ||
3088
+ icmp6stat.icp6s_inhist[ND_ROUTER_ADVERT] ||
3089
+ icmp6stat.icp6s_outhist[ND_ROUTER_ADVERT] ||
3090
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
3091
do_icmp6_router = CONFIG_BOOLEAN_YES;
3092
3093
static RRDSET *st = NULL;
@@ -3090,11 +3126,12 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
3126
3127
// --------------------------------------------------------------------
3128
3093
- if (do_icmp6_neighbor == CONFIG_BOOLEAN_YES || (do_icmp6_neighbor == CONFIG_BOOLEAN_AUTO && (
3094
- icmp6stat.icp6s_inhist[ND_NEIGHBOR_SOLICIT] ||
3095
- icmp6stat.icp6s_outhist[ND_NEIGHBOR_SOLICIT] ||
3096
- icmp6stat.icp6s_inhist[ND_NEIGHBOR_ADVERT] ||
3097
- icmp6stat.icp6s_outhist[ND_NEIGHBOR_ADVERT]))) {
3129
+ if (do_icmp6_neighbor == CONFIG_BOOLEAN_YES || (do_icmp6_neighbor == CONFIG_BOOLEAN_AUTO &&
3130
+ (icmp6stat.icp6s_inhist[ND_NEIGHBOR_SOLICIT] ||
3131
+ icmp6stat.icp6s_outhist[ND_NEIGHBOR_SOLICIT] ||
3132
+ icmp6stat.icp6s_inhist[ND_NEIGHBOR_ADVERT] ||
3133
+ icmp6stat.icp6s_outhist[ND_NEIGHBOR_ADVERT] ||
3134
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
3135
do_icmp6_neighbor = CONFIG_BOOLEAN_YES;
3136
3137
static RRDSET *st = NULL;
@@ -3133,17 +3170,18 @@ int do_net_inet6_icmp6_stats(int update_every, usec_t dt) {
3170
3171
// --------------------------------------------------------------------
3172
3136
- if (do_icmp6_types == CONFIG_BOOLEAN_YES || (do_icmp6_types == CONFIG_BOOLEAN_AUTO && (
3137
- icmp6stat.icp6s_inhist[1] ||
3138
- icmp6stat.icp6s_inhist[128] ||
3139
- icmp6stat.icp6s_inhist[129] ||
3140
- icmp6stat.icp6s_inhist[136] ||
3141
- icmp6stat.icp6s_outhist[1] ||
3142
- icmp6stat.icp6s_outhist[128] ||
3143
- icmp6stat.icp6s_outhist[129] ||
3144
- icmp6stat.icp6s_outhist[133] ||
3145
- icmp6stat.icp6s_outhist[135] ||
3146
- icmp6stat.icp6s_outhist[136]))) {
3173
+ if (do_icmp6_types == CONFIG_BOOLEAN_YES || (do_icmp6_types == CONFIG_BOOLEAN_AUTO &&
3174
+ (icmp6stat.icp6s_inhist[1] ||
3175
+ icmp6stat.icp6s_inhist[128] ||
3176
+ icmp6stat.icp6s_inhist[129] ||
3177
+ icmp6stat.icp6s_inhist[136] ||
3178
+ icmp6stat.icp6s_outhist[1] ||
3179
+ icmp6stat.icp6s_outhist[128] ||
3180
+ icmp6stat.icp6s_outhist[129] ||
3181
+ icmp6stat.icp6s_outhist[133] ||
3182
+ icmp6stat.icp6s_outhist[135] ||
3183
+ icmp6stat.icp6s_outhist[136] ||
3184
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
3185
do_icmp6_types = CONFIG_BOOLEAN_YES;
3186
3187
static RRDSET *st = NULL;
collectors/macos.plugin/README.md
+2
@@ -2,4 +2,6 @@
2
3
Collects resource usage and performance data on MacOS systems
4
5
+By default, Netdata will enable monitoring metrics for disks, memory, and network only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Use `yes` instead of `auto` in plugin configuration sections to enable these charts permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
6
+
7
[]()
collectors/macos.plugin/macos_sysctl.c
+94
-60
@@ -479,7 +479,12 @@ int do_macos_sysctl(int update_every, usec_t dt) {
479
480
// --------------------------------------------------------------------
481
482
- if (do_tcpext_connaborts == CONFIG_BOOLEAN_YES || (do_tcpext_connaborts == CONFIG_BOOLEAN_AUTO && (tcpstat.tcps_rcvpackafterwin || tcpstat.tcps_rcvafterclose || tcpstat.tcps_rcvmemdrop || tcpstat.tcps_persistdrop))) {
482
+ if (do_tcpext_connaborts == CONFIG_BOOLEAN_YES || (do_tcpext_connaborts == CONFIG_BOOLEAN_AUTO &&
483
+ (tcpstat.tcps_rcvpackafterwin ||
484
+ tcpstat.tcps_rcvafterclose ||
485
+ tcpstat.tcps_rcvmemdrop ||
486
+ tcpstat.tcps_persistdrop ||
487
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
488
do_tcpext_connaborts = CONFIG_BOOLEAN_YES;
489
st = rrdset_find_localhost("ipv4.tcpconnaborts");
490
if (unlikely(!st)) {
@@ -514,7 +519,9 @@ int do_macos_sysctl(int update_every, usec_t dt) {
519
520
// --------------------------------------------------------------------
521
517
- if (do_tcpext_ofo == CONFIG_BOOLEAN_YES || (do_tcpext_ofo == CONFIG_BOOLEAN_AUTO && tcpstat.tcps_rcvoopack)) {
522
+ if (do_tcpext_ofo == CONFIG_BOOLEAN_YES || (do_tcpext_ofo == CONFIG_BOOLEAN_AUTO &&
523
+ (tcpstat.tcps_rcvoopack ||
524
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
525
do_tcpext_ofo = CONFIG_BOOLEAN_YES;
526
st = rrdset_find_localhost("ipv4.tcpofo");
527
if (unlikely(!st)) {
@@ -543,7 +550,11 @@ int do_macos_sysctl(int update_every, usec_t dt) {
550
551
// --------------------------------------------------------------------
552
546
- if (do_tcpext_syscookies == CONFIG_BOOLEAN_YES || (do_tcpext_syscookies == CONFIG_BOOLEAN_AUTO && (tcpstat.tcps_sc_sendcookie || tcpstat.tcps_sc_recvcookie || tcpstat.tcps_sc_zonefail))) {
553
+ if (do_tcpext_syscookies == CONFIG_BOOLEAN_YES || (do_tcpext_syscookies == CONFIG_BOOLEAN_AUTO &&
554
+ (tcpstat.tcps_sc_sendcookie ||
555
+ tcpstat.tcps_sc_recvcookie ||
556
+ tcpstat.tcps_sc_zonefail ||
557
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
558
do_tcpext_syscookies = CONFIG_BOOLEAN_YES;
559
560
st = rrdset_find_localhost("ipv4.tcpsyncookies");
@@ -579,7 +590,10 @@ int do_macos_sysctl(int update_every, usec_t dt) {
590
591
592
#if (defined __MAC_OS_X_VERSION_MIN_REQUIRED && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101100)
582
- if (do_ecn == CONFIG_BOOLEAN_YES || (do_ecn == CONFIG_BOOLEAN_AUTO && (tcpstat.tcps_ecn_recv_ce || tcpstat.tcps_ecn_not_supported))) {
593
+ if (do_ecn == CONFIG_BOOLEAN_YES || (do_ecn == CONFIG_BOOLEAN_AUTO &&
594
+ (tcpstat.tcps_ecn_recv_ce ||
595
+ tcpstat.tcps_ecn_not_supported ||
596
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
597
do_ecn = CONFIG_BOOLEAN_YES;
598
st = rrdset_find_localhost("ipv4.ecnpkts");
599
if (unlikely(!st)) {
@@ -980,8 +994,11 @@ int do_macos_sysctl(int update_every, usec_t dt) {
994
error("DISABLED: ipv6.errors");
995
} else {
996
if (do_ip6_packets == CONFIG_BOOLEAN_YES || (do_ip6_packets == CONFIG_BOOLEAN_AUTO &&
983
- (ip6stat.ip6s_localout || ip6stat.ip6s_total ||
984
- ip6stat.ip6s_forward || ip6stat.ip6s_delivered))) {
997
+ (ip6stat.ip6s_localout ||
998
+ ip6stat.ip6s_total ||
999
+ ip6stat.ip6s_forward ||
1000
+ ip6stat.ip6s_delivered ||
1001
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1002
do_ip6_packets = CONFIG_BOOLEAN_YES;
1003
st = rrdset_find_localhost("ipv6.packets");
1004
if (unlikely(!st)) {
@@ -1017,8 +1034,10 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1034
// --------------------------------------------------------------------
1035
1036
if (do_ip6_fragsout == CONFIG_BOOLEAN_YES || (do_ip6_fragsout == CONFIG_BOOLEAN_AUTO &&
1020
- (ip6stat.ip6s_fragmented || ip6stat.ip6s_cantfrag ||
1021
- ip6stat.ip6s_ofragments))) {
1037
+ (ip6stat.ip6s_fragmented ||
1038
+ ip6stat.ip6s_cantfrag ||
1039
+ ip6stat.ip6s_ofragments ||
1040
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1041
do_ip6_fragsout = CONFIG_BOOLEAN_YES;
1042
st = rrdset_find_localhost("ipv6.fragsout");
1043
if (unlikely(!st)) {
@@ -1053,8 +1072,11 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1072
// --------------------------------------------------------------------
1073
1074
if (do_ip6_fragsin == CONFIG_BOOLEAN_YES || (do_ip6_fragsin == CONFIG_BOOLEAN_AUTO &&
1056
- (ip6stat.ip6s_reassembled || ip6stat.ip6s_fragdropped ||
1057
- ip6stat.ip6s_fragtimeout || ip6stat.ip6s_fragments))) {
1075
+ (ip6stat.ip6s_reassembled ||
1076
+ ip6stat.ip6s_fragdropped ||
1077
+ ip6stat.ip6s_fragtimeout ||
1078
+ ip6stat.ip6s_fragments ||
1079
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1080
do_ip6_fragsin = CONFIG_BOOLEAN_YES;
1081
st = rrdset_find_localhost("ipv6.fragsin");
1082
if (unlikely(!st)) {
@@ -1090,16 +1112,17 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1112
1113
// --------------------------------------------------------------------
1114
1093
- if (do_ip6_errors == CONFIG_BOOLEAN_YES || (do_ip6_errors == CONFIG_BOOLEAN_AUTO && (
1094
- ip6stat.ip6s_toosmall ||
1095
- ip6stat.ip6s_odropped ||
1096
- ip6stat.ip6s_badoptions ||
1097
- ip6stat.ip6s_badvers ||
1098
- ip6stat.ip6s_exthdrtoolong ||
1099
- ip6stat.ip6s_sources_none ||
1100
- ip6stat.ip6s_tooshort ||
1101
- ip6stat.ip6s_cantforward ||
1102
- ip6stat.ip6s_noroute))) {
1115
+ if (do_ip6_errors == CONFIG_BOOLEAN_YES || (do_ip6_errors == CONFIG_BOOLEAN_AUTO &&
1116
+ (ip6stat.ip6s_toosmall ||
1117
+ ip6stat.ip6s_odropped ||
1118
+ ip6stat.ip6s_badoptions ||
1119
+ ip6stat.ip6s_badvers ||
1120
+ ip6stat.ip6s_exthdrtoolong ||
1121
+ ip6stat.ip6s_sources_none ||
1122
+ ip6stat.ip6s_tooshort ||
1123
+ ip6stat.ip6s_cantforward ||
1124
+ ip6stat.ip6s_noroute ||
1125
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1126
do_ip6_errors = CONFIG_BOOLEAN_YES;
1127
st = rrdset_find_localhost("ipv6.errors");
1128
if (unlikely(!st)) {
@@ -1158,7 +1181,10 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1181
icmp6_total.msgs_out += icmp6stat.icp6s_outhist[i];
1182
}
1183
icmp6_total.msgs_in += icmp6stat.icp6s_badcode + icmp6stat.icp6s_badlen + icmp6stat.icp6s_checksum + icmp6stat.icp6s_tooshort;
1161
- if (do_icmp6 == CONFIG_BOOLEAN_YES || (do_icmp6 == CONFIG_BOOLEAN_AUTO && (icmp6_total.msgs_in || icmp6_total.msgs_out))) {
1184
+ if (do_icmp6 == CONFIG_BOOLEAN_YES || (do_icmp6 == CONFIG_BOOLEAN_AUTO &&
1185
+ (icmp6_total.msgs_in ||
1186
+ icmp6_total.msgs_out ||
1187
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1188
do_icmp6 = CONFIG_BOOLEAN_YES;
1189
st = rrdset_find_localhost("ipv6.icmp");
1190
if (unlikely(!st)) {
@@ -1189,7 +1215,10 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1215
1216
// --------------------------------------------------------------------
1217
1192
- if (do_icmp6_redir == CONFIG_BOOLEAN_YES || (do_icmp6_redir == CONFIG_BOOLEAN_AUTO && (icmp6stat.icp6s_inhist[ND_REDIRECT] || icmp6stat.icp6s_outhist[ND_REDIRECT]))) {
1218
+ if (do_icmp6_redir == CONFIG_BOOLEAN_YES || (do_icmp6_redir == CONFIG_BOOLEAN_AUTO &&
1219
+ (icmp6stat.icp6s_inhist[ND_REDIRECT] ||
1220
+ icmp6stat.icp6s_outhist[ND_REDIRECT] ||
1221
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1222
do_icmp6_redir = CONFIG_BOOLEAN_YES;
1223
st = rrdset_find_localhost("ipv6.icmpredir");
1224
if (unlikely(!st)) {
@@ -1220,18 +1249,19 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1249
1250
// --------------------------------------------------------------------
1251
1223
- if (do_icmp6_errors == CONFIG_BOOLEAN_YES || (do_icmp6_errors == CONFIG_BOOLEAN_AUTO && (
1224
- icmp6stat.icp6s_badcode ||
1225
- icmp6stat.icp6s_badlen ||
1226
- icmp6stat.icp6s_checksum ||
1227
- icmp6stat.icp6s_tooshort ||
1228
- icmp6stat.icp6s_error ||
1229
- icmp6stat.icp6s_inhist[ICMP6_DST_UNREACH] ||
1230
- icmp6stat.icp6s_inhist[ICMP6_TIME_EXCEEDED] ||
1231
- icmp6stat.icp6s_inhist[ICMP6_PARAM_PROB] ||
1232
- icmp6stat.icp6s_outhist[ICMP6_DST_UNREACH] ||
1233
- icmp6stat.icp6s_outhist[ICMP6_TIME_EXCEEDED] ||
1234
- icmp6stat.icp6s_outhist[ICMP6_PARAM_PROB]))) {
1252
+ if (do_icmp6_errors == CONFIG_BOOLEAN_YES || (do_icmp6_errors == CONFIG_BOOLEAN_AUTO &&
1253
+ (icmp6stat.icp6s_badcode ||
1254
+ icmp6stat.icp6s_badlen ||
1255
+ icmp6stat.icp6s_checksum ||
1256
+ icmp6stat.icp6s_tooshort ||
1257
+ icmp6stat.icp6s_error ||
1258
+ icmp6stat.icp6s_inhist[ICMP6_DST_UNREACH] ||
1259
+ icmp6stat.icp6s_inhist[ICMP6_TIME_EXCEEDED] ||
1260
+ icmp6stat.icp6s_inhist[ICMP6_PARAM_PROB] ||
1261
+ icmp6stat.icp6s_outhist[ICMP6_DST_UNREACH] ||
1262
+ icmp6stat.icp6s_outhist[ICMP6_TIME_EXCEEDED] ||
1263
+ icmp6stat.icp6s_outhist[ICMP6_PARAM_PROB] ||
1264
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1265
do_icmp6_errors = CONFIG_BOOLEAN_YES;
1266
st = rrdset_find_localhost("ipv6.icmperrors");
1267
if (unlikely(!st)) {
@@ -1279,11 +1309,12 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1309
1310
// --------------------------------------------------------------------
1311
1282
- if (do_icmp6_echos == CONFIG_BOOLEAN_YES || (do_icmp6_echos == CONFIG_BOOLEAN_AUTO && (
1283
- icmp6stat.icp6s_inhist[ICMP6_ECHO_REQUEST] ||
1284
- icmp6stat.icp6s_outhist[ICMP6_ECHO_REQUEST] ||
1285
- icmp6stat.icp6s_inhist[ICMP6_ECHO_REPLY] ||
1286
- icmp6stat.icp6s_outhist[ICMP6_ECHO_REPLY]))) {
1312
+ if (do_icmp6_echos == CONFIG_BOOLEAN_YES || (do_icmp6_echos == CONFIG_BOOLEAN_AUTO &&
1313
+ (icmp6stat.icp6s_inhist[ICMP6_ECHO_REQUEST] ||
1314
+ icmp6stat.icp6s_outhist[ICMP6_ECHO_REQUEST] ||
1315
+ icmp6stat.icp6s_inhist[ICMP6_ECHO_REPLY] ||
1316
+ icmp6stat.icp6s_outhist[ICMP6_ECHO_REPLY] ||
1317
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1318
do_icmp6_echos = CONFIG_BOOLEAN_YES;
1319
st = rrdset_find_localhost("ipv6.icmpechos");
1320
if (unlikely(!st)) {
@@ -1318,11 +1349,12 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1349
1350
// --------------------------------------------------------------------
1351
1321
- if (do_icmp6_router == CONFIG_BOOLEAN_YES || (do_icmp6_router == CONFIG_BOOLEAN_AUTO && (
1322
- icmp6stat.icp6s_inhist[ND_ROUTER_SOLICIT] ||
1323
- icmp6stat.icp6s_outhist[ND_ROUTER_SOLICIT] ||
1324
- icmp6stat.icp6s_inhist[ND_ROUTER_ADVERT] ||
1325
- icmp6stat.icp6s_outhist[ND_ROUTER_ADVERT]))) {
1352
+ if (do_icmp6_router == CONFIG_BOOLEAN_YES || (do_icmp6_router == CONFIG_BOOLEAN_AUTO &&
1353
+ (icmp6stat.icp6s_inhist[ND_ROUTER_SOLICIT] ||
1354
+ icmp6stat.icp6s_outhist[ND_ROUTER_SOLICIT] ||
1355
+ icmp6stat.icp6s_inhist[ND_ROUTER_ADVERT] ||
1356
+ icmp6stat.icp6s_outhist[ND_ROUTER_ADVERT] ||
1357
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1358
do_icmp6_router = CONFIG_BOOLEAN_YES;
1359
st = rrdset_find_localhost("ipv6.icmprouter");
1360
if (unlikely(!st)) {
@@ -1357,11 +1389,12 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1389
1390
// --------------------------------------------------------------------
1391
1360
- if (do_icmp6_neighbor == CONFIG_BOOLEAN_YES || (do_icmp6_neighbor == CONFIG_BOOLEAN_AUTO && (
1361
- icmp6stat.icp6s_inhist[ND_NEIGHBOR_SOLICIT] ||
1362
- icmp6stat.icp6s_outhist[ND_NEIGHBOR_SOLICIT] ||
1363
- icmp6stat.icp6s_inhist[ND_NEIGHBOR_ADVERT] ||
1364
- icmp6stat.icp6s_outhist[ND_NEIGHBOR_ADVERT]))) {
1392
+ if (do_icmp6_neighbor == CONFIG_BOOLEAN_YES || (do_icmp6_neighbor == CONFIG_BOOLEAN_AUTO &&
1393
+ (icmp6stat.icp6s_inhist[ND_NEIGHBOR_SOLICIT] ||
1394
+ icmp6stat.icp6s_outhist[ND_NEIGHBOR_SOLICIT] ||
1395
+ icmp6stat.icp6s_inhist[ND_NEIGHBOR_ADVERT] ||
1396
+ icmp6stat.icp6s_outhist[ND_NEIGHBOR_ADVERT] ||
1397
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1398
do_icmp6_neighbor = CONFIG_BOOLEAN_YES;
1399
st = rrdset_find_localhost("ipv6.icmpneighbor");
1400
if (unlikely(!st)) {
@@ -1396,17 +1429,18 @@ int do_macos_sysctl(int update_every, usec_t dt) {
1429
1430
// --------------------------------------------------------------------
1431
1399
- if (do_icmp6_types == CONFIG_BOOLEAN_YES || (do_icmp6_types == CONFIG_BOOLEAN_AUTO && (
1400
- icmp6stat.icp6s_inhist[1] ||
1401
- icmp6stat.icp6s_inhist[128] ||
1402
- icmp6stat.icp6s_inhist[129] ||
1403
- icmp6stat.icp6s_inhist[136] ||
1404
- icmp6stat.icp6s_outhist[1] ||
1405
- icmp6stat.icp6s_outhist[128] ||
1406
- icmp6stat.icp6s_outhist[129] ||
1407
- icmp6stat.icp6s_outhist[133] ||
1408
- icmp6stat.icp6s_outhist[135] ||
1409
- icmp6stat.icp6s_outhist[136]))) {
1432
+ if (do_icmp6_types == CONFIG_BOOLEAN_YES || (do_icmp6_types == CONFIG_BOOLEAN_AUTO &&
1433
+ (icmp6stat.icp6s_inhist[1] ||
1434
+ icmp6stat.icp6s_inhist[128] ||
1435
+ icmp6stat.icp6s_inhist[129] ||
1436
+ icmp6stat.icp6s_inhist[136] ||
1437
+ icmp6stat.icp6s_outhist[1] ||
1438
+ icmp6stat.icp6s_outhist[128] ||
1439
+ icmp6stat.icp6s_outhist[129] ||
1440
+ icmp6stat.icp6s_outhist[133] ||
1441
+ icmp6stat.icp6s_outhist[135] ||
1442
+ icmp6stat.icp6s_outhist[136] ||
1443
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1444
do_icmp6_types = CONFIG_BOOLEAN_YES;
1445
st = rrdset_find_localhost("ipv6.icmptypes");
1446
if (unlikely(!st)) {
collectors/proc.plugin/README.md
+1
-1
@@ -75,7 +75,7 @@ netdata will automatically set the name of disks on the dashboard, from the moun
75
76
### performance metrics
77
78
-By default, Netdata will enable monitoring metrics only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Set `yes` for a chart instead of `auto` to enable it permanently.
78
+By default, Netdata will enable monitoring metrics only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Set `yes` for a chart instead of `auto` to enable it permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
79
80
netdata categorizes all block devices in 3 categories:
81
collectors/proc.plugin/proc_diskstats.c
+43
-16
@@ -973,7 +973,9 @@ int do_proc_diskstats(int update_every, usec_t dt) {
973
// --------------------------------------------------------------------------
974
// Do performance metrics
975
976
- if(d->do_io == CONFIG_BOOLEAN_YES || (d->do_io == CONFIG_BOOLEAN_AUTO && (readsectors || writesectors))) {
976
+ if(d->do_io == CONFIG_BOOLEAN_YES || (d->do_io == CONFIG_BOOLEAN_AUTO &&
977
+ (readsectors || writesectors ||
978
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
979
d->do_io = CONFIG_BOOLEAN_YES;
980
981
if(unlikely(!d->st_io)) {
@@ -1004,7 +1006,8 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1006
1007
// --------------------------------------------------------------------
1008
1007
- if(d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO && (reads || writes))) {
1009
+ if(d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO &&
1010
+ (reads || writes || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1011
d->do_ops = CONFIG_BOOLEAN_YES;
1012
1013
if(unlikely(!d->st_ops)) {
@@ -1037,7 +1040,8 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1040
1041
// --------------------------------------------------------------------
1042
1040
- if(d->do_qops == CONFIG_BOOLEAN_YES || (d->do_qops == CONFIG_BOOLEAN_AUTO && queued_ios)) {
1043
+ if(d->do_qops == CONFIG_BOOLEAN_YES || (d->do_qops == CONFIG_BOOLEAN_AUTO &&
1044
+ (queued_ios || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1045
d->do_qops = CONFIG_BOOLEAN_YES;
1046
1047
if(unlikely(!d->st_qops)) {
@@ -1068,7 +1072,8 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1072
1073
// --------------------------------------------------------------------
1074
1071
- if(d->do_backlog == CONFIG_BOOLEAN_YES || (d->do_backlog == CONFIG_BOOLEAN_AUTO && backlog_ms)) {
1075
+ if(d->do_backlog == CONFIG_BOOLEAN_YES || (d->do_backlog == CONFIG_BOOLEAN_AUTO &&
1076
+ (backlog_ms || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1077
d->do_backlog = CONFIG_BOOLEAN_YES;
1078
1079
if(unlikely(!d->st_backlog)) {
@@ -1099,7 +1104,8 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1104
1105
// --------------------------------------------------------------------
1106
1102
- if(d->do_util == CONFIG_BOOLEAN_YES || (d->do_util == CONFIG_BOOLEAN_AUTO && busy_ms)) {
1107
+ if(d->do_util == CONFIG_BOOLEAN_YES || (d->do_util == CONFIG_BOOLEAN_AUTO &&
1108
+ (busy_ms || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1109
d->do_util = CONFIG_BOOLEAN_YES;
1110
1111
if(unlikely(!d->st_util)) {
@@ -1130,7 +1136,8 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1136
1137
// --------------------------------------------------------------------
1138
1133
- if(d->do_mops == CONFIG_BOOLEAN_YES || (d->do_mops == CONFIG_BOOLEAN_AUTO && (mreads || mwrites))) {
1139
+ if(d->do_mops == CONFIG_BOOLEAN_YES || (d->do_mops == CONFIG_BOOLEAN_AUTO &&
1140
+ (mreads || mwrites || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1141
d->do_mops = CONFIG_BOOLEAN_YES;
1142
1143
if(unlikely(!d->st_mops)) {
@@ -1163,7 +1170,8 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1170
1171
// --------------------------------------------------------------------
1172
1166
- if(d->do_iotime == CONFIG_BOOLEAN_YES || (d->do_iotime == CONFIG_BOOLEAN_AUTO && (readms || writems))) {
1173
+ if(d->do_iotime == CONFIG_BOOLEAN_YES || (d->do_iotime == CONFIG_BOOLEAN_AUTO &&
1174
+ (readms || writems || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1175
d->do_iotime = CONFIG_BOOLEAN_YES;
1176
1177
if(unlikely(!d->st_iotime)) {
@@ -1199,8 +1207,12 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1207
// only if this is not the first time we run
1208
1209
if(likely(dt)) {
1202
- if( (d->do_iotime == CONFIG_BOOLEAN_YES || (d->do_iotime == CONFIG_BOOLEAN_AUTO && (readms || writems))) &&
1203
- (d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO && (reads || writes)))) {
1210
+ if( (d->do_iotime == CONFIG_BOOLEAN_YES || (d->do_iotime == CONFIG_BOOLEAN_AUTO &&
1211
+ (readms || writems ||
1212
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) &&
1213
+ (d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO &&
1214
+ (reads || writes ||
1215
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))) {
1216
1217
if(unlikely(!d->st_await)) {
1218
d->st_await = rrdset_create_localhost(
@@ -1230,8 +1242,10 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1242
rrdset_done(d->st_await);
1243
}
1244
1233
- if( (d->do_io == CONFIG_BOOLEAN_YES || (d->do_io == CONFIG_BOOLEAN_AUTO && (readsectors || writesectors))) &&
1234
- (d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO && (reads || writes)))) {
1245
+ if( (d->do_io == CONFIG_BOOLEAN_YES || (d->do_io == CONFIG_BOOLEAN_AUTO &&
1246
+ (readsectors || writesectors || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) &&
1247
+ (d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO &&
1248
+ (reads || writes || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))) {
1249
1250
if(unlikely(!d->st_avgsz)) {
1251
d->st_avgsz = rrdset_create_localhost(
@@ -1261,8 +1275,12 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1275
rrdset_done(d->st_avgsz);
1276
}
1277
1264
- if( (d->do_util == CONFIG_BOOLEAN_YES || (d->do_util == CONFIG_BOOLEAN_AUTO && busy_ms)) &&
1265
- (d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO && (reads || writes)))) {
1278
+ if( (d->do_util == CONFIG_BOOLEAN_YES || (d->do_util == CONFIG_BOOLEAN_AUTO &&
1279
+ (busy_ms ||
1280
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) &&
1281
+ (d->do_ops == CONFIG_BOOLEAN_YES || (d->do_ops == CONFIG_BOOLEAN_AUTO &&
1282
+ (reads || writes ||
1283
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))) {
1284
1285
if(unlikely(!d->st_svctm)) {
1286
d->st_svctm = rrdset_create_localhost(
@@ -1505,7 +1523,11 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1523
rrdset_done(d->st_bcache_cache_read_races);
1524
}
1525
1508
- if(d->do_bcache == CONFIG_BOOLEAN_YES || (d->do_bcache == CONFIG_BOOLEAN_AUTO && (stats_total_cache_hits != 0 || stats_total_cache_misses != 0 || stats_total_cache_miss_collisions != 0))) {
1526
+ if(d->do_bcache == CONFIG_BOOLEAN_YES || (d->do_bcache == CONFIG_BOOLEAN_AUTO &&
1527
+ (stats_total_cache_hits ||
1528
+ stats_total_cache_misses ||
1529
+ stats_total_cache_miss_collisions ||
1530
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1531
1532
if(unlikely(!d->st_bcache)) {
1533
d->st_bcache = rrdset_create_localhost(
@@ -1539,7 +1561,10 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1561
rrdset_done(d->st_bcache);
1562
}
1563
1542
- if(d->do_bcache == CONFIG_BOOLEAN_YES || (d->do_bcache == CONFIG_BOOLEAN_AUTO && (stats_total_cache_bypass_hits != 0 || stats_total_cache_bypass_misses != 0))) {
1564
+ if(d->do_bcache == CONFIG_BOOLEAN_YES || (d->do_bcache == CONFIG_BOOLEAN_AUTO &&
1565
+ (stats_total_cache_bypass_hits ||
1566
+ stats_total_cache_bypass_misses ||
1567
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1568
1569
if(unlikely(!d->st_bcache_bypass)) {
1570
d->st_bcache_bypass = rrdset_create_localhost(
@@ -1575,7 +1600,9 @@ int do_proc_diskstats(int update_every, usec_t dt) {
1600
// ------------------------------------------------------------------------
1601
// update the system total I/O
1602
1578
- if(global_do_io == CONFIG_BOOLEAN_YES || (global_do_io == CONFIG_BOOLEAN_AUTO && (system_read_kb || system_write_kb))) {
1603
+ if(global_do_io == CONFIG_BOOLEAN_YES || (global_do_io == CONFIG_BOOLEAN_AUTO &&
1604
+ (system_read_kb || system_write_kb ||
1605
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1606
static RRDSET *st_io = NULL;
1607
static RRDDIM *rd_in = NULL, *rd_out = NULL;
1608
collectors/proc.plugin/proc_meminfo.c
+14
-4
@@ -219,7 +219,9 @@ int do_proc_meminfo(int update_every, usec_t dt) {
219
220
unsigned long long SwapUsed = SwapTotal - SwapFree;
221
222
- if(do_swap == CONFIG_BOOLEAN_YES || SwapTotal || SwapUsed || SwapFree) {
222
+ if(do_swap == CONFIG_BOOLEAN_YES || (do_swap == CONFIG_BOOLEAN_AUTO &&
223
+ (SwapTotal || SwapUsed || SwapFree ||
224
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
225
do_swap = CONFIG_BOOLEAN_YES;
226
227
static RRDSET *st_system_swap = NULL;
@@ -256,7 +258,10 @@ int do_proc_meminfo(int update_every, usec_t dt) {
258
259
// --------------------------------------------------------------------
260
259
- if(arl_hwcorrupted->flags & ARL_ENTRY_FLAG_FOUND && (do_hwcorrupt == CONFIG_BOOLEAN_YES || (do_hwcorrupt == CONFIG_BOOLEAN_AUTO && HardwareCorrupted > 0))) {
261
+ if(arl_hwcorrupted->flags & ARL_ENTRY_FLAG_FOUND &&
262
+ (do_hwcorrupt == CONFIG_BOOLEAN_YES || (do_hwcorrupt == CONFIG_BOOLEAN_AUTO &&
263
+ (HardwareCorrupted > 0 ||
264
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))) {
265
do_hwcorrupt = CONFIG_BOOLEAN_YES;
266
267
static RRDSET *st_mem_hwcorrupt = NULL;
@@ -438,7 +443,9 @@ int do_proc_meminfo(int update_every, usec_t dt) {
443
444
// --------------------------------------------------------------------
445
441
- if(do_hugepages == CONFIG_BOOLEAN_YES || (do_hugepages == CONFIG_BOOLEAN_AUTO && Hugepagesize != 0 && HugePages_Total != 0)) {
446
+ if(do_hugepages == CONFIG_BOOLEAN_YES || (do_hugepages == CONFIG_BOOLEAN_AUTO &&
447
+ ((Hugepagesize && HugePages_Total) ||
448
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
449
do_hugepages = CONFIG_BOOLEAN_YES;
450
451
static RRDSET *st_mem_hugepages = NULL;
@@ -479,7 +486,10 @@ int do_proc_meminfo(int update_every, usec_t dt) {
486
487
// --------------------------------------------------------------------
488
482
- if(do_transparent_hugepages == CONFIG_BOOLEAN_YES || (do_transparent_hugepages == CONFIG_BOOLEAN_AUTO && (AnonHugePages != 0 || ShmemHugePages != 0))) {
489
+ if(do_transparent_hugepages == CONFIG_BOOLEAN_YES || (do_transparent_hugepages == CONFIG_BOOLEAN_AUTO &&
490
+ (AnonHugePages ||
491
+ ShmemHugePages ||
492
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
493
do_transparent_hugepages = CONFIG_BOOLEAN_YES;
494
495
static RRDSET *st_mem_transparent_hugepages = NULL;
collectors/proc.plugin/proc_net_dev.c
+17
-8
@@ -601,7 +601,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
601
602
// --------------------------------------------------------------------
603
604
- if(unlikely((d->do_bandwidth == CONFIG_BOOLEAN_AUTO && (d->rbytes || d->tbytes))))
604
+ if(unlikely(d->do_bandwidth == CONFIG_BOOLEAN_AUTO &&
605
+ (d->rbytes || d->tbytes || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
606
d->do_bandwidth = CONFIG_BOOLEAN_YES;
607
608
if(d->do_bandwidth == CONFIG_BOOLEAN_YES) {
@@ -671,7 +672,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
672
673
// --------------------------------------------------------------------
674
674
- if(unlikely((d->do_packets == CONFIG_BOOLEAN_AUTO && (d->rpackets || d->tpackets || d->rmulticast))))
675
+ if(unlikely(d->do_packets == CONFIG_BOOLEAN_AUTO &&
676
+ (d->rpackets || d->tpackets || d->rmulticast || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
677
d->do_packets = CONFIG_BOOLEAN_YES;
678
679
if(d->do_packets == CONFIG_BOOLEAN_YES) {
@@ -716,7 +718,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
718
719
// --------------------------------------------------------------------
720
719
- if(unlikely((d->do_errors == CONFIG_BOOLEAN_AUTO && (d->rerrors || d->terrors))))
721
+ if(unlikely(d->do_errors == CONFIG_BOOLEAN_AUTO &&
722
+ (d->rerrors || d->terrors || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
723
d->do_errors = CONFIG_BOOLEAN_YES;
724
725
if(d->do_errors == CONFIG_BOOLEAN_YES) {
@@ -759,7 +762,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
762
763
// --------------------------------------------------------------------
764
762
- if(unlikely((d->do_drops == CONFIG_BOOLEAN_AUTO && (d->rdrops || d->tdrops))))
765
+ if(unlikely(d->do_drops == CONFIG_BOOLEAN_AUTO &&
766
+ (d->rdrops || d->tdrops || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
767
d->do_drops = CONFIG_BOOLEAN_YES;
768
769
if(d->do_drops == CONFIG_BOOLEAN_YES) {
@@ -802,7 +806,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
806
807
// --------------------------------------------------------------------
808
805
- if(unlikely((d->do_fifo == CONFIG_BOOLEAN_AUTO && (d->rfifo || d->tfifo))))
809
+ if(unlikely(d->do_fifo == CONFIG_BOOLEAN_AUTO &&
810
+ (d->rfifo || d->tfifo || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
811
d->do_fifo = CONFIG_BOOLEAN_YES;
812
813
if(d->do_fifo == CONFIG_BOOLEAN_YES) {
@@ -845,7 +850,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
850
851
// --------------------------------------------------------------------
852
848
- if(unlikely((d->do_compressed == CONFIG_BOOLEAN_AUTO && (d->rcompressed || d->tcompressed))))
853
+ if(unlikely(d->do_compressed == CONFIG_BOOLEAN_AUTO &&
854
+ (d->rcompressed || d->tcompressed || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
855
d->do_compressed = CONFIG_BOOLEAN_YES;
856
857
if(d->do_compressed == CONFIG_BOOLEAN_YES) {
@@ -888,7 +894,8 @@ int do_proc_net_dev(int update_every, usec_t dt) {
894
895
// --------------------------------------------------------------------
896
891
- if(unlikely((d->do_events == CONFIG_BOOLEAN_AUTO && (d->rframe || d->tcollisions || d->tcarrier))))
897
+ if(unlikely(d->do_events == CONFIG_BOOLEAN_AUTO &&
898
+ (d->rframe || d->tcollisions || d->tcarrier || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)))
899
d->do_events = CONFIG_BOOLEAN_YES;
900
901
if(d->do_events == CONFIG_BOOLEAN_YES) {
@@ -924,7 +931,9 @@ int do_proc_net_dev(int update_every, usec_t dt) {
931
}
932
}
933
927
- if(do_bandwidth == CONFIG_BOOLEAN_YES || (do_bandwidth == CONFIG_BOOLEAN_AUTO && (system_rbytes || system_tbytes))) {
934
+ if(do_bandwidth == CONFIG_BOOLEAN_YES || (do_bandwidth == CONFIG_BOOLEAN_AUTO &&
935
+ (system_rbytes || system_tbytes ||
936
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
937
do_bandwidth = CONFIG_BOOLEAN_YES;
938
static RRDSET *st_system_net = NULL;
939
static RRDDIM *rd_in = NULL, *rd_out = NULL;
collectors/proc.plugin/proc_net_netstat.c
+65
-14
@@ -262,7 +262,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
262
263
// --------------------------------------------------------------------
264
265
- if(do_bandwidth == CONFIG_BOOLEAN_YES || (do_bandwidth == CONFIG_BOOLEAN_AUTO && (ipext_InOctets || ipext_OutOctets))) {
265
+ if(do_bandwidth == CONFIG_BOOLEAN_YES || (do_bandwidth == CONFIG_BOOLEAN_AUTO &&
266
+ (ipext_InOctets ||
267
+ ipext_OutOctets ||
268
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
269
do_bandwidth = CONFIG_BOOLEAN_YES;
270
static RRDSET *st_system_ip = NULL;
271
static RRDDIM *rd_in = NULL, *rd_out = NULL;
@@ -297,7 +300,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
300
301
// --------------------------------------------------------------------
302
300
- if(do_inerrors == CONFIG_BOOLEAN_YES || (do_inerrors == CONFIG_BOOLEAN_AUTO && (ipext_InNoRoutes || ipext_InTruncatedPkts))) {
303
+ if(do_inerrors == CONFIG_BOOLEAN_YES || (do_inerrors == CONFIG_BOOLEAN_AUTO &&
304
+ (ipext_InNoRoutes ||
305
+ ipext_InTruncatedPkts ||
306
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
307
do_inerrors = CONFIG_BOOLEAN_YES;
308
static RRDSET *st_ip_inerrors = NULL;
309
static RRDDIM *rd_noroutes = NULL, *rd_truncated = NULL, *rd_checksum = NULL;
@@ -336,7 +342,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
342
343
// --------------------------------------------------------------------
344
339
- if(do_mcast == CONFIG_BOOLEAN_YES || (do_mcast == CONFIG_BOOLEAN_AUTO && (ipext_InMcastOctets || ipext_OutMcastOctets))) {
345
+ if(do_mcast == CONFIG_BOOLEAN_YES || (do_mcast == CONFIG_BOOLEAN_AUTO &&
346
+ (ipext_InMcastOctets ||
347
+ ipext_OutMcastOctets ||
348
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
349
do_mcast = CONFIG_BOOLEAN_YES;
350
static RRDSET *st_ip_mcast = NULL;
351
static RRDDIM *rd_in = NULL, *rd_out = NULL;
@@ -373,7 +382,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
382
383
// --------------------------------------------------------------------
384
376
- if(do_bcast == CONFIG_BOOLEAN_YES || (do_bcast == CONFIG_BOOLEAN_AUTO && (ipext_InBcastOctets || ipext_OutBcastOctets))) {
385
+ if(do_bcast == CONFIG_BOOLEAN_YES || (do_bcast == CONFIG_BOOLEAN_AUTO &&
386
+ (ipext_InBcastOctets ||
387
+ ipext_OutBcastOctets ||
388
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
389
do_bcast = CONFIG_BOOLEAN_YES;
390
391
static RRDSET *st_ip_bcast = NULL;
@@ -411,7 +423,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
423
424
// --------------------------------------------------------------------
425
414
- if(do_mcast_p == CONFIG_BOOLEAN_YES || (do_mcast_p == CONFIG_BOOLEAN_AUTO && (ipext_InMcastPkts || ipext_OutMcastPkts))) {
426
+ if(do_mcast_p == CONFIG_BOOLEAN_YES || (do_mcast_p == CONFIG_BOOLEAN_AUTO &&
427
+ (ipext_InMcastPkts ||
428
+ ipext_OutMcastPkts ||
429
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
430
do_mcast_p = CONFIG_BOOLEAN_YES;
431
432
static RRDSET *st_ip_mcastpkts = NULL;
@@ -448,7 +463,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
463
464
// --------------------------------------------------------------------
465
451
- if(do_bcast_p == CONFIG_BOOLEAN_YES || (do_bcast_p == CONFIG_BOOLEAN_AUTO && (ipext_InBcastPkts || ipext_OutBcastPkts))) {
466
+ if(do_bcast_p == CONFIG_BOOLEAN_YES || (do_bcast_p == CONFIG_BOOLEAN_AUTO &&
467
+ (ipext_InBcastPkts ||
468
+ ipext_OutBcastPkts ||
469
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
470
do_bcast_p = CONFIG_BOOLEAN_YES;
471
472
static RRDSET *st_ip_bcastpkts = NULL;
@@ -486,7 +504,12 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
504
505
// --------------------------------------------------------------------
506
489
- if(do_ecn == CONFIG_BOOLEAN_YES || (do_ecn == CONFIG_BOOLEAN_AUTO && (ipext_InCEPkts || ipext_InECT0Pkts || ipext_InECT1Pkts || ipext_InNoECTPkts))) {
507
+ if(do_ecn == CONFIG_BOOLEAN_YES || (do_ecn == CONFIG_BOOLEAN_AUTO &&
508
+ (ipext_InCEPkts ||
509
+ ipext_InECT0Pkts ||
510
+ ipext_InECT1Pkts ||
511
+ ipext_InNoECTPkts ||
512
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
513
do_ecn = CONFIG_BOOLEAN_YES;
514
515
static RRDSET *st_ecnpkts = NULL;
@@ -538,7 +561,9 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
561
562
// --------------------------------------------------------------------
563
541
- if(do_tcpext_memory == CONFIG_BOOLEAN_YES || (do_tcpext_memory == CONFIG_BOOLEAN_AUTO && (tcpext_TCPMemoryPressures))) {
564
+ if(do_tcpext_memory == CONFIG_BOOLEAN_YES || (do_tcpext_memory == CONFIG_BOOLEAN_AUTO &&
565
+ (tcpext_TCPMemoryPressures ||
566
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
567
do_tcpext_memory = CONFIG_BOOLEAN_YES;
568
569
static RRDSET *st_tcpmemorypressures = NULL;
@@ -572,7 +597,14 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
597
598
// --------------------------------------------------------------------
599
575
- if(do_tcpext_connaborts == CONFIG_BOOLEAN_YES || (do_tcpext_connaborts == CONFIG_BOOLEAN_AUTO && (tcpext_TCPAbortOnData || tcpext_TCPAbortOnClose || tcpext_TCPAbortOnMemory || tcpext_TCPAbortOnTimeout || tcpext_TCPAbortOnLinger || tcpext_TCPAbortFailed))) {
600
+ if(do_tcpext_connaborts == CONFIG_BOOLEAN_YES || (do_tcpext_connaborts == CONFIG_BOOLEAN_AUTO &&
601
+ (tcpext_TCPAbortOnData ||
602
+ tcpext_TCPAbortOnClose ||
603
+ tcpext_TCPAbortOnMemory ||
604
+ tcpext_TCPAbortOnTimeout ||
605
+ tcpext_TCPAbortOnLinger ||
606
+ tcpext_TCPAbortFailed ||
607
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
608
do_tcpext_connaborts = CONFIG_BOOLEAN_YES;
609
610
static RRDSET *st_tcpconnaborts = NULL;
@@ -616,7 +648,12 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
648
649
// --------------------------------------------------------------------
650
619
- if(do_tcpext_reorder == CONFIG_BOOLEAN_YES || (do_tcpext_reorder == CONFIG_BOOLEAN_AUTO && (tcpext_TCPRenoReorder || tcpext_TCPFACKReorder || tcpext_TCPSACKReorder || tcpext_TCPTSReorder))) {
651
+ if(do_tcpext_reorder == CONFIG_BOOLEAN_YES || (do_tcpext_reorder == CONFIG_BOOLEAN_AUTO &&
652
+ (tcpext_TCPRenoReorder ||
653
+ tcpext_TCPFACKReorder ||
654
+ tcpext_TCPSACKReorder ||
655
+ tcpext_TCPTSReorder ||
656
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
657
do_tcpext_reorder = CONFIG_BOOLEAN_YES;
658
659
static RRDSET *st_tcpreorders = NULL;
@@ -656,7 +693,11 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
693
694
// --------------------------------------------------------------------
695
659
- if(do_tcpext_ofo == CONFIG_BOOLEAN_YES || (do_tcpext_ofo == CONFIG_BOOLEAN_AUTO && (tcpext_TCPOFOQueue || tcpext_TCPOFODrop || tcpext_TCPOFOMerge))) {
696
+ if(do_tcpext_ofo == CONFIG_BOOLEAN_YES || (do_tcpext_ofo == CONFIG_BOOLEAN_AUTO &&
697
+ (tcpext_TCPOFOQueue ||
698
+ tcpext_TCPOFODrop ||
699
+ tcpext_TCPOFOMerge ||
700
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
701
do_tcpext_ofo = CONFIG_BOOLEAN_YES;
702
703
static RRDSET *st_ip_tcpofo = NULL;
@@ -697,7 +738,11 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
738
739
// --------------------------------------------------------------------
740
700
- if(do_tcpext_syscookies == CONFIG_BOOLEAN_YES || (do_tcpext_syscookies == CONFIG_BOOLEAN_AUTO && (tcpext_SyncookiesSent || tcpext_SyncookiesRecv || tcpext_SyncookiesFailed))) {
741
+ if(do_tcpext_syscookies == CONFIG_BOOLEAN_YES || (do_tcpext_syscookies == CONFIG_BOOLEAN_AUTO &&
742
+ (tcpext_SyncookiesSent ||
743
+ tcpext_SyncookiesRecv ||
744
+ tcpext_SyncookiesFailed ||
745
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
746
do_tcpext_syscookies = CONFIG_BOOLEAN_YES;
747
748
static RRDSET *st_syncookies = NULL;
@@ -736,7 +781,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
781
782
// --------------------------------------------------------------------
783
739
- if(do_tcpext_syn_queue == CONFIG_BOOLEAN_YES || (do_tcpext_syn_queue == CONFIG_BOOLEAN_AUTO && (tcpext_TCPReqQFullDrop || tcpext_TCPReqQFullDoCookies))) {
784
+ if(do_tcpext_syn_queue == CONFIG_BOOLEAN_YES || (do_tcpext_syn_queue == CONFIG_BOOLEAN_AUTO &&
785
+ (tcpext_TCPReqQFullDrop ||
786
+ tcpext_TCPReqQFullDoCookies ||
787
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
788
do_tcpext_syn_queue = CONFIG_BOOLEAN_YES;
789
790
static RRDSET *st_syn_queue = NULL;
@@ -775,7 +823,10 @@ int do_proc_net_netstat(int update_every, usec_t dt) {
823
824
// --------------------------------------------------------------------
825
778
- if(do_tcpext_accept_queue == CONFIG_BOOLEAN_YES || (do_tcpext_accept_queue == CONFIG_BOOLEAN_AUTO && (tcpext_ListenOverflows || tcpext_ListenDrops))) {
826
+ if(do_tcpext_accept_queue == CONFIG_BOOLEAN_YES || (do_tcpext_accept_queue == CONFIG_BOOLEAN_AUTO &&
827
+ (tcpext_ListenOverflows ||
828
+ tcpext_ListenDrops ||
829
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
830
do_tcpext_accept_queue = CONFIG_BOOLEAN_YES;
831
832
static RRDSET *st_accept_queue = NULL;
collectors/proc.plugin/proc_net_sctp_snmp.c
+28
-7
@@ -124,7 +124,8 @@ int do_proc_net_sctp_snmp(int update_every, usec_t dt) {
124
125
// --------------------------------------------------------------------
126
127
- if(do_associations == CONFIG_BOOLEAN_YES || (do_associations == CONFIG_BOOLEAN_AUTO && SctpCurrEstab)) {
127
+ if(do_associations == CONFIG_BOOLEAN_YES || (do_associations == CONFIG_BOOLEAN_AUTO &&
128
+ (SctpCurrEstab || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
129
do_associations = CONFIG_BOOLEAN_YES;
130
static RRDSET *st = NULL;
131
static RRDDIM *rd_established = NULL;
@@ -155,7 +156,12 @@ int do_proc_net_sctp_snmp(int update_every, usec_t dt) {
156
157
// --------------------------------------------------------------------
158
158
- if(do_transitions == CONFIG_BOOLEAN_YES || (do_transitions == CONFIG_BOOLEAN_AUTO && (SctpActiveEstabs || SctpPassiveEstabs || SctpAborteds || SctpShutdowns))) {
159
+ if(do_transitions == CONFIG_BOOLEAN_YES || (do_transitions == CONFIG_BOOLEAN_AUTO &&
160
+ (SctpActiveEstabs ||
161
+ SctpPassiveEstabs ||
162
+ SctpAborteds ||
163
+ SctpShutdowns ||
164
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
165
do_transitions = CONFIG_BOOLEAN_YES;
166
static RRDSET *st = NULL;
167
static RRDDIM *rd_active = NULL,
@@ -195,7 +201,10 @@ int do_proc_net_sctp_snmp(int update_every, usec_t dt) {
201
202
// --------------------------------------------------------------------
203
198
- if(do_packets == CONFIG_BOOLEAN_YES || (do_packets == CONFIG_BOOLEAN_AUTO && (SctpInSCTPPacks || SctpOutSCTPPacks))) {
204
+ if(do_packets == CONFIG_BOOLEAN_YES || (do_packets == CONFIG_BOOLEAN_AUTO &&
205
+ (SctpInSCTPPacks ||
206
+ SctpOutSCTPPacks ||
207
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
208
do_packets = CONFIG_BOOLEAN_YES;
209
static RRDSET *st = NULL;
210
static RRDDIM *rd_received = NULL,
@@ -230,7 +239,10 @@ int do_proc_net_sctp_snmp(int update_every, usec_t dt) {
239
240
// --------------------------------------------------------------------
241
233
- if(do_packet_errors == CONFIG_BOOLEAN_YES || (do_packet_errors == CONFIG_BOOLEAN_AUTO && (SctpOutOfBlues || SctpChecksumErrors))) {
242
+ if(do_packet_errors == CONFIG_BOOLEAN_YES || (do_packet_errors == CONFIG_BOOLEAN_AUTO &&
243
+ (SctpOutOfBlues ||
244
+ SctpChecksumErrors ||
245
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
246
do_packet_errors = CONFIG_BOOLEAN_YES;
247
static RRDSET *st = NULL;
248
static RRDDIM *rd_invalid = NULL,
@@ -265,7 +277,10 @@ int do_proc_net_sctp_snmp(int update_every, usec_t dt) {
277
278
// --------------------------------------------------------------------
279
268
- if(do_fragmentation == CONFIG_BOOLEAN_YES || (do_fragmentation == CONFIG_BOOLEAN_AUTO && (SctpFragUsrMsgs || SctpReasmUsrMsgs))) {
280
+ if(do_fragmentation == CONFIG_BOOLEAN_YES || (do_fragmentation == CONFIG_BOOLEAN_AUTO &&
281
+ (SctpFragUsrMsgs ||
282
+ SctpReasmUsrMsgs ||
283
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
284
do_fragmentation = CONFIG_BOOLEAN_YES;
285
286
static RRDSET *st = NULL;
@@ -300,8 +315,14 @@ int do_proc_net_sctp_snmp(int update_every, usec_t dt) {
315
316
// --------------------------------------------------------------------
317
303
- if(do_chunk_types == CONFIG_BOOLEAN_YES || (do_chunk_types == CONFIG_BOOLEAN_AUTO
304
- && (SctpInCtrlChunks || SctpInOrderChunks || SctpInUnorderChunks || SctpOutCtrlChunks || SctpOutOrderChunks || SctpOutUnorderChunks))) {
318
+ if(do_chunk_types == CONFIG_BOOLEAN_YES || (do_chunk_types == CONFIG_BOOLEAN_AUTO &&
319
+ (SctpInCtrlChunks ||
320
+ SctpInOrderChunks ||
321
+ SctpInUnorderChunks ||
322
+ SctpOutCtrlChunks ||
323
+ SctpOutOrderChunks ||
324
+ SctpOutUnorderChunks ||
325
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
326
do_chunk_types = CONFIG_BOOLEAN_YES;
327
static RRDSET *st = NULL;
328
static RRDDIM
collectors/proc.plugin/proc_net_snmp.c
+96
-51
@@ -258,7 +258,12 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
258
259
// --------------------------------------------------------------------
260
261
- if(do_ip_packets == CONFIG_BOOLEAN_YES || (do_ip_packets == CONFIG_BOOLEAN_AUTO && (snmp_root.ip_OutRequests || snmp_root.ip_InReceives || snmp_root.ip_ForwDatagrams || snmp_root.ip_InDelivers))) {
261
+ if(do_ip_packets == CONFIG_BOOLEAN_YES || (do_ip_packets == CONFIG_BOOLEAN_AUTO &&
262
+ (snmp_root.ip_OutRequests ||
263
+ snmp_root.ip_InReceives ||
264
+ snmp_root.ip_ForwDatagrams ||
265
+ snmp_root.ip_InDelivers ||
266
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
267
do_ip_packets = CONFIG_BOOLEAN_YES;
268
269
static RRDSET *st = NULL;
@@ -299,7 +304,11 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
304
305
// --------------------------------------------------------------------
306
302
- if(do_ip_fragsout == CONFIG_BOOLEAN_YES || (do_ip_fragsout == CONFIG_BOOLEAN_AUTO && (snmp_root.ip_FragOKs || snmp_root.ip_FragFails || snmp_root.ip_FragCreates))) {
307
+ if(do_ip_fragsout == CONFIG_BOOLEAN_YES || (do_ip_fragsout == CONFIG_BOOLEAN_AUTO &&
308
+ (snmp_root.ip_FragOKs ||
309
+ snmp_root.ip_FragFails ||
310
+ snmp_root.ip_FragCreates ||
311
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
312
do_ip_fragsout = CONFIG_BOOLEAN_YES;
313
314
static RRDSET *st = NULL;
@@ -338,7 +347,11 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
347
348
// --------------------------------------------------------------------
349
341
- if(do_ip_fragsin == CONFIG_BOOLEAN_YES || (do_ip_fragsin == CONFIG_BOOLEAN_AUTO && (snmp_root.ip_ReasmOKs || snmp_root.ip_ReasmFails || snmp_root.ip_ReasmReqds))) {
350
+ if(do_ip_fragsin == CONFIG_BOOLEAN_YES || (do_ip_fragsin == CONFIG_BOOLEAN_AUTO &&
351
+ (snmp_root.ip_ReasmOKs ||
352
+ snmp_root.ip_ReasmFails ||
353
+ snmp_root.ip_ReasmReqds ||
354
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
355
do_ip_fragsin = CONFIG_BOOLEAN_YES;
356
357
static RRDSET *st = NULL;
@@ -377,7 +390,14 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
390
391
// --------------------------------------------------------------------
392
380
- if(do_ip_errors == CONFIG_BOOLEAN_YES || (do_ip_errors == CONFIG_BOOLEAN_AUTO && (snmp_root.ip_InDiscards || snmp_root.ip_OutDiscards || snmp_root.ip_InHdrErrors || snmp_root.ip_InAddrErrors || snmp_root.ip_InUnknownProtos || snmp_root.ip_OutNoRoutes))) {
393
+ if(do_ip_errors == CONFIG_BOOLEAN_YES || (do_ip_errors == CONFIG_BOOLEAN_AUTO &&
394
+ (snmp_root.ip_InDiscards ||
395
+ snmp_root.ip_OutDiscards ||
396
+ snmp_root.ip_InHdrErrors ||
397
+ snmp_root.ip_InAddrErrors ||
398
+ snmp_root.ip_InUnknownProtos ||
399
+ snmp_root.ip_OutNoRoutes ||
400
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
401
do_ip_errors = CONFIG_BOOLEAN_YES;
402
403
static RRDSET *st = NULL;
@@ -447,7 +467,13 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
467
468
// --------------------------------------------------------------------
469
450
- if(do_icmp_packets == CONFIG_BOOLEAN_YES || (do_icmp_packets == CONFIG_BOOLEAN_AUTO && (snmp_root.icmp_InMsgs || snmp_root.icmp_OutMsgs || snmp_root.icmp_InErrors || snmp_root.icmp_OutErrors || snmp_root.icmp_InCsumErrors))) {
470
+ if(do_icmp_packets == CONFIG_BOOLEAN_YES || (do_icmp_packets == CONFIG_BOOLEAN_AUTO &&
471
+ (snmp_root.icmp_InMsgs ||
472
+ snmp_root.icmp_OutMsgs ||
473
+ snmp_root.icmp_InErrors ||
474
+ snmp_root.icmp_OutErrors ||
475
+ snmp_root.icmp_InCsumErrors ||
476
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
477
do_icmp_packets = CONFIG_BOOLEAN_YES;
478
479
{
@@ -540,28 +566,28 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
566
567
// --------------------------------------------------------------------
568
543
- if(do_icmpmsg == CONFIG_BOOLEAN_YES || (do_icmpmsg == CONFIG_BOOLEAN_AUTO && (
544
- snmp_root.icmpmsg_InEchoReps
545
- || snmp_root.icmpmsg_OutEchoReps
546
- || snmp_root.icmpmsg_InDestUnreachs
547
- || snmp_root.icmpmsg_OutDestUnreachs
548
- || snmp_root.icmpmsg_InRedirects
549
- || snmp_root.icmpmsg_OutRedirects
550
- || snmp_root.icmpmsg_InEchos
551
- || snmp_root.icmpmsg_OutEchos
552
- || snmp_root.icmpmsg_InRouterAdvert
553
- || snmp_root.icmpmsg_OutRouterAdvert
554
- || snmp_root.icmpmsg_InRouterSelect
555
- || snmp_root.icmpmsg_OutRouterSelect
556
- || snmp_root.icmpmsg_InTimeExcds
557
- || snmp_root.icmpmsg_OutTimeExcds
558
- || snmp_root.icmpmsg_InParmProbs
559
- || snmp_root.icmpmsg_OutParmProbs
560
- || snmp_root.icmpmsg_InTimestamps
561
- || snmp_root.icmpmsg_OutTimestamps
562
- || snmp_root.icmpmsg_InTimestampReps
563
- || snmp_root.icmpmsg_OutTimestampReps
564
- ))) {
569
+ if(do_icmpmsg == CONFIG_BOOLEAN_YES || (do_icmpmsg == CONFIG_BOOLEAN_AUTO &&
570
+ (snmp_root.icmpmsg_InEchoReps ||
571
+ snmp_root.icmpmsg_OutEchoReps ||
572
+ snmp_root.icmpmsg_InDestUnreachs ||
573
+ snmp_root.icmpmsg_OutDestUnreachs ||
574
+ snmp_root.icmpmsg_InRedirects ||
575
+ snmp_root.icmpmsg_OutRedirects ||
576
+ snmp_root.icmpmsg_InEchos ||
577
+ snmp_root.icmpmsg_OutEchos ||
578
+ snmp_root.icmpmsg_InRouterAdvert ||
579
+ snmp_root.icmpmsg_OutRouterAdvert ||
580
+ snmp_root.icmpmsg_InRouterSelect ||
581
+ snmp_root.icmpmsg_OutRouterSelect ||
582
+ snmp_root.icmpmsg_InTimeExcds ||
583
+ snmp_root.icmpmsg_OutTimeExcds ||
584
+ snmp_root.icmpmsg_InParmProbs ||
585
+ snmp_root.icmpmsg_OutParmProbs ||
586
+ snmp_root.icmpmsg_InTimestamps ||
587
+ snmp_root.icmpmsg_OutTimestamps ||
588
+ snmp_root.icmpmsg_InTimestampReps ||
589
+ snmp_root.icmpmsg_OutTimestampReps ||
590
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
591
do_icmpmsg = CONFIG_BOOLEAN_YES;
592
593
static RRDSET *st = NULL;
@@ -677,7 +703,9 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
703
// --------------------------------------------------------------------
704
705
// see http://net-snmp.sourceforge.net/docs/mibs/tcp.html
680
- if(do_tcp_sockets == CONFIG_BOOLEAN_YES || (do_tcp_sockets == CONFIG_BOOLEAN_AUTO && snmp_root.tcp_CurrEstab)) {
706
+ if(do_tcp_sockets == CONFIG_BOOLEAN_YES || (do_tcp_sockets == CONFIG_BOOLEAN_AUTO &&
707
+ (snmp_root.tcp_CurrEstab ||
708
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
709
do_tcp_sockets = CONFIG_BOOLEAN_YES;
710
711
static RRDSET *st = NULL;
@@ -709,7 +737,10 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
737
738
// --------------------------------------------------------------------
739
712
- if(do_tcp_packets == CONFIG_BOOLEAN_YES || (do_tcp_packets == CONFIG_BOOLEAN_AUTO && (snmp_root.tcp_InSegs || snmp_root.tcp_OutSegs))) {
740
+ if(do_tcp_packets == CONFIG_BOOLEAN_YES || (do_tcp_packets == CONFIG_BOOLEAN_AUTO &&
741
+ (snmp_root.tcp_InSegs ||
742
+ snmp_root.tcp_OutSegs ||
743
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
744
do_tcp_packets = CONFIG_BOOLEAN_YES;
745
746
static RRDSET *st = NULL;
@@ -744,7 +775,11 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
775
776
// --------------------------------------------------------------------
777
747
- if(do_tcp_errors == CONFIG_BOOLEAN_YES || (do_tcp_errors == CONFIG_BOOLEAN_AUTO && (snmp_root.tcp_InErrs || snmp_root.tcp_InCsumErrors || snmp_root.tcp_RetransSegs))) {
778
+ if(do_tcp_errors == CONFIG_BOOLEAN_YES || (do_tcp_errors == CONFIG_BOOLEAN_AUTO &&
779
+ (snmp_root.tcp_InErrs ||
780
+ snmp_root.tcp_InCsumErrors ||
781
+ snmp_root.tcp_RetransSegs ||
782
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
783
do_tcp_errors = CONFIG_BOOLEAN_YES;
784
785
static RRDSET *st = NULL;
@@ -783,7 +818,10 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
818
819
// --------------------------------------------------------------------
820
786
- if(do_tcp_opens == CONFIG_BOOLEAN_YES || (do_tcp_opens == CONFIG_BOOLEAN_AUTO && (snmp_root.tcp_ActiveOpens || snmp_root.tcp_PassiveOpens))) {
821
+ if(do_tcp_opens == CONFIG_BOOLEAN_YES || (do_tcp_opens == CONFIG_BOOLEAN_AUTO &&
822
+ (snmp_root.tcp_ActiveOpens ||
823
+ snmp_root.tcp_PassiveOpens ||
824
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
825
do_tcp_opens = CONFIG_BOOLEAN_YES;
826
827
static RRDSET *st = NULL;
@@ -819,7 +857,11 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
857
858
// --------------------------------------------------------------------
859
822
- if(do_tcp_handshake == CONFIG_BOOLEAN_YES || (do_tcp_handshake == CONFIG_BOOLEAN_AUTO && (snmp_root.tcp_EstabResets || snmp_root.tcp_OutRsts || snmp_root.tcp_AttemptFails))) {
860
+ if(do_tcp_handshake == CONFIG_BOOLEAN_YES || (do_tcp_handshake == CONFIG_BOOLEAN_AUTO &&
861
+ (snmp_root.tcp_EstabResets ||
862
+ snmp_root.tcp_OutRsts ||
863
+ snmp_root.tcp_AttemptFails ||
864
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
865
do_tcp_handshake = CONFIG_BOOLEAN_YES;
866
867
static RRDSET *st = NULL;
@@ -882,7 +924,10 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
924
// --------------------------------------------------------------------
925
926
// see http://net-snmp.sourceforge.net/docs/mibs/udp.html
885
- if(do_udp_packets == CONFIG_BOOLEAN_YES || (do_udp_packets == CONFIG_BOOLEAN_AUTO && (snmp_root.udp_InDatagrams || snmp_root.udp_OutDatagrams))) {
927
+ if(do_udp_packets == CONFIG_BOOLEAN_YES || (do_udp_packets == CONFIG_BOOLEAN_AUTO &&
928
+ (snmp_root.udp_InDatagrams ||
929
+ snmp_root.udp_OutDatagrams ||
930
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
931
do_udp_packets = CONFIG_BOOLEAN_YES;
932
933
static RRDSET *st = NULL;
@@ -917,14 +962,14 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
962
963
// --------------------------------------------------------------------
964
920
- if(do_udp_errors == CONFIG_BOOLEAN_YES || (do_udp_errors == CONFIG_BOOLEAN_AUTO && (
921
- snmp_root.udp_InErrors
922
- || snmp_root.udp_NoPorts
923
- || snmp_root.udp_RcvbufErrors
924
- || snmp_root.udp_SndbufErrors
925
- || snmp_root.udp_InCsumErrors
926
- || snmp_root.udp_IgnoredMulti
927
- ))) {
965
+ if(do_udp_errors == CONFIG_BOOLEAN_YES || (do_udp_errors == CONFIG_BOOLEAN_AUTO &&
966
+ (snmp_root.udp_InErrors ||
967
+ snmp_root.udp_NoPorts ||
968
+ snmp_root.udp_RcvbufErrors ||
969
+ snmp_root.udp_SndbufErrors ||
970
+ snmp_root.udp_InCsumErrors ||
971
+ snmp_root.udp_IgnoredMulti ||
972
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
973
do_udp_errors = CONFIG_BOOLEAN_YES;
974
975
static RRDSET *st = NULL;
@@ -992,16 +1037,16 @@ int do_proc_net_snmp(int update_every, usec_t dt) {
1037
1038
// --------------------------------------------------------------------
1039
995
- if(do_udplite_packets == CONFIG_BOOLEAN_YES || (do_udplite_packets == CONFIG_BOOLEAN_AUTO && (
996
- snmp_root.udplite_InDatagrams
997
- || snmp_root.udplite_OutDatagrams
998
- || snmp_root.udplite_NoPorts
999
- || snmp_root.udplite_InErrors
1000
- || snmp_root.udplite_InCsumErrors
1001
- || snmp_root.udplite_RcvbufErrors
1002
- || snmp_root.udplite_SndbufErrors
1003
- || snmp_root.udplite_IgnoredMulti
1004
- ))) {
1040
+ if(do_udplite_packets == CONFIG_BOOLEAN_YES || (do_udplite_packets == CONFIG_BOOLEAN_AUTO &&
1041
+ (snmp_root.udplite_InDatagrams ||
1042
+ snmp_root.udplite_OutDatagrams ||
1043
+ snmp_root.udplite_NoPorts ||
1044
+ snmp_root.udplite_InErrors ||
1045
+ snmp_root.udplite_InCsumErrors ||
1046
+ snmp_root.udplite_RcvbufErrors ||
1047
+ snmp_root.udplite_SndbufErrors ||
1048
+ snmp_root.udplite_IgnoredMulti ||
1049
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1050
do_udplite_packets = CONFIG_BOOLEAN_YES;
1051
1052
{
collectors/proc.plugin/proc_net_snmp6.c
+136
-111
@@ -277,7 +277,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
277
278
// --------------------------------------------------------------------
279
280
- if(do_bandwidth == CONFIG_BOOLEAN_YES || (do_bandwidth == CONFIG_BOOLEAN_AUTO && (Ip6InOctets || Ip6OutOctets))) {
280
+ if(do_bandwidth == CONFIG_BOOLEAN_YES || (do_bandwidth == CONFIG_BOOLEAN_AUTO &&
281
+ (Ip6InOctets ||
282
+ Ip6OutOctets ||
283
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
284
do_bandwidth = CONFIG_BOOLEAN_YES;
285
static RRDSET *st = NULL;
286
static RRDDIM *rd_received = NULL,
@@ -311,7 +314,12 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
314
315
// --------------------------------------------------------------------
316
314
- if(do_ip_packets == CONFIG_BOOLEAN_YES || (do_ip_packets == CONFIG_BOOLEAN_AUTO && (Ip6InReceives || Ip6OutRequests || Ip6InDelivers || Ip6OutForwDatagrams))) {
317
+ if(do_ip_packets == CONFIG_BOOLEAN_YES || (do_ip_packets == CONFIG_BOOLEAN_AUTO &&
318
+ (Ip6InReceives ||
319
+ Ip6OutRequests ||
320
+ Ip6InDelivers ||
321
+ Ip6OutForwDatagrams ||
322
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
323
do_ip_packets = CONFIG_BOOLEAN_YES;
324
static RRDSET *st = NULL;
325
static RRDDIM *rd_received = NULL,
@@ -351,7 +359,11 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
359
360
// --------------------------------------------------------------------
361
354
- if(do_ip_fragsout == CONFIG_BOOLEAN_YES || (do_ip_fragsout == CONFIG_BOOLEAN_AUTO && (Ip6FragOKs || Ip6FragFails || Ip6FragCreates))) {
362
+ if(do_ip_fragsout == CONFIG_BOOLEAN_YES || (do_ip_fragsout == CONFIG_BOOLEAN_AUTO &&
363
+ (Ip6FragOKs ||
364
+ Ip6FragFails ||
365
+ Ip6FragCreates ||
366
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
367
do_ip_fragsout = CONFIG_BOOLEAN_YES;
368
static RRDSET *st = NULL;
369
static RRDDIM *rd_ok = NULL,
@@ -389,13 +401,12 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
401
402
// --------------------------------------------------------------------
403
392
- if(do_ip_fragsin == CONFIG_BOOLEAN_YES || (do_ip_fragsin == CONFIG_BOOLEAN_AUTO
393
- && (
394
- Ip6ReasmOKs
395
- || Ip6ReasmFails
396
- || Ip6ReasmTimeout
397
- || Ip6ReasmReqds
398
- ))) {
404
+ if(do_ip_fragsin == CONFIG_BOOLEAN_YES || (do_ip_fragsin == CONFIG_BOOLEAN_AUTO &&
405
+ (Ip6ReasmOKs ||
406
+ Ip6ReasmFails ||
407
+ Ip6ReasmTimeout ||
408
+ Ip6ReasmReqds ||
409
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
410
do_ip_fragsin = CONFIG_BOOLEAN_YES;
411
412
static RRDSET *st = NULL;
@@ -436,17 +447,16 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
447
448
// --------------------------------------------------------------------
449
439
- if(do_ip_errors == CONFIG_BOOLEAN_YES || (do_ip_errors == CONFIG_BOOLEAN_AUTO
440
- && (
441
- Ip6InDiscards
442
- || Ip6OutDiscards
443
- || Ip6InHdrErrors
444
- || Ip6InAddrErrors
445
- || Ip6InUnknownProtos
446
- || Ip6InTooBigErrors
447
- || Ip6InTruncatedPkts
448
- || Ip6InNoRoutes
449
- ))) {
450
+ if(do_ip_errors == CONFIG_BOOLEAN_YES || (do_ip_errors == CONFIG_BOOLEAN_AUTO &&
451
+ (Ip6InDiscards ||
452
+ Ip6OutDiscards ||
453
+ Ip6InHdrErrors ||
454
+ Ip6InAddrErrors ||
455
+ Ip6InUnknownProtos ||
456
+ Ip6InTooBigErrors ||
457
+ Ip6InTruncatedPkts ||
458
+ Ip6InNoRoutes ||
459
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
460
do_ip_errors = CONFIG_BOOLEAN_YES;
461
static RRDSET *st = NULL;
462
static RRDDIM *rd_InDiscards = NULL,
@@ -502,7 +512,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
512
513
// --------------------------------------------------------------------
514
505
- if(do_udp_packets == CONFIG_BOOLEAN_YES || (do_udp_packets == CONFIG_BOOLEAN_AUTO && (Udp6InDatagrams || Udp6OutDatagrams))) {
515
+ if(do_udp_packets == CONFIG_BOOLEAN_YES || (do_udp_packets == CONFIG_BOOLEAN_AUTO &&
516
+ (Udp6InDatagrams ||
517
+ Udp6OutDatagrams ||
518
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
519
do_udp_packets = CONFIG_BOOLEAN_YES;
520
static RRDSET *st = NULL;
521
static RRDDIM *rd_received = NULL,
@@ -536,15 +549,14 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
549
550
// --------------------------------------------------------------------
551
539
- if(do_udp_errors == CONFIG_BOOLEAN_YES || (do_udp_errors == CONFIG_BOOLEAN_AUTO
540
- && (
541
- Udp6InErrors
542
- || Udp6NoPorts
543
- || Udp6RcvbufErrors
544
- || Udp6SndbufErrors
545
- || Udp6InCsumErrors
546
- || Udp6IgnoredMulti
547
- ))) {
552
+ if(do_udp_errors == CONFIG_BOOLEAN_YES || (do_udp_errors == CONFIG_BOOLEAN_AUTO &&
553
+ (Udp6InErrors ||
554
+ Udp6NoPorts ||
555
+ Udp6RcvbufErrors ||
556
+ Udp6SndbufErrors ||
557
+ Udp6InCsumErrors ||
558
+ Udp6IgnoredMulti ||
559
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
560
do_udp_errors = CONFIG_BOOLEAN_YES;
561
static RRDSET *st = NULL;
562
static RRDDIM *rd_RcvbufErrors = NULL,
@@ -591,7 +603,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
603
604
// --------------------------------------------------------------------
605
594
- if(do_udplite_packets == CONFIG_BOOLEAN_YES || (do_udplite_packets == CONFIG_BOOLEAN_AUTO && (UdpLite6InDatagrams || UdpLite6OutDatagrams))) {
606
+ if(do_udplite_packets == CONFIG_BOOLEAN_YES || (do_udplite_packets == CONFIG_BOOLEAN_AUTO &&
607
+ (UdpLite6InDatagrams ||
608
+ UdpLite6OutDatagrams ||
609
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
610
do_udplite_packets = CONFIG_BOOLEAN_YES;
611
static RRDSET *st = NULL;
612
static RRDDIM *rd_received = NULL,
@@ -625,15 +640,14 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
640
641
// --------------------------------------------------------------------
642
628
- if(do_udplite_errors == CONFIG_BOOLEAN_YES || (do_udplite_errors == CONFIG_BOOLEAN_AUTO
629
- && (
630
- UdpLite6InErrors
631
- || UdpLite6NoPorts
632
- || UdpLite6RcvbufErrors
633
- || UdpLite6SndbufErrors
634
- || Udp6InCsumErrors
635
- || UdpLite6InCsumErrors
636
- ))) {
643
+ if(do_udplite_errors == CONFIG_BOOLEAN_YES || (do_udplite_errors == CONFIG_BOOLEAN_AUTO &&
644
+ (UdpLite6InErrors ||
645
+ UdpLite6NoPorts ||
646
+ UdpLite6RcvbufErrors ||
647
+ UdpLite6SndbufErrors ||
648
+ Udp6InCsumErrors ||
649
+ UdpLite6InCsumErrors ||
650
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
651
do_udplite_errors = CONFIG_BOOLEAN_YES;
652
static RRDSET *st = NULL;
653
static RRDDIM *rd_RcvbufErrors = NULL,
@@ -677,7 +691,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
691
692
// --------------------------------------------------------------------
693
680
- if(do_mcast == CONFIG_BOOLEAN_YES || (do_mcast == CONFIG_BOOLEAN_AUTO && (Ip6OutMcastOctets || Ip6InMcastOctets))) {
694
+ if(do_mcast == CONFIG_BOOLEAN_YES || (do_mcast == CONFIG_BOOLEAN_AUTO &&
695
+ (Ip6OutMcastOctets ||
696
+ Ip6InMcastOctets ||
697
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
698
do_mcast = CONFIG_BOOLEAN_YES;
699
static RRDSET *st = NULL;
700
static RRDDIM *rd_Ip6InMcastOctets = NULL,
@@ -712,7 +729,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
729
730
// --------------------------------------------------------------------
731
715
- if(do_bcast == CONFIG_BOOLEAN_YES || (do_bcast == CONFIG_BOOLEAN_AUTO && (Ip6OutBcastOctets || Ip6InBcastOctets))) {
732
+ if(do_bcast == CONFIG_BOOLEAN_YES || (do_bcast == CONFIG_BOOLEAN_AUTO &&
733
+ (Ip6OutBcastOctets ||
734
+ Ip6InBcastOctets ||
735
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
736
do_bcast = CONFIG_BOOLEAN_YES;
737
static RRDSET *st = NULL;
738
static RRDDIM *rd_Ip6InBcastOctets = NULL,
@@ -747,7 +767,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
767
768
// --------------------------------------------------------------------
769
750
- if(do_mcast_p == CONFIG_BOOLEAN_YES || (do_mcast_p == CONFIG_BOOLEAN_AUTO && (Ip6OutMcastPkts || Ip6InMcastPkts))) {
770
+ if(do_mcast_p == CONFIG_BOOLEAN_YES || (do_mcast_p == CONFIG_BOOLEAN_AUTO &&
771
+ (Ip6OutMcastPkts ||
772
+ Ip6InMcastPkts ||
773
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
774
do_mcast_p = CONFIG_BOOLEAN_YES;
775
static RRDSET *st = NULL;
776
static RRDDIM *rd_Ip6InMcastPkts = NULL,
@@ -782,7 +805,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
805
806
// --------------------------------------------------------------------
807
785
- if(do_icmp == CONFIG_BOOLEAN_YES || (do_icmp == CONFIG_BOOLEAN_AUTO && (Icmp6InMsgs || Icmp6OutMsgs))) {
808
+ if(do_icmp == CONFIG_BOOLEAN_YES || (do_icmp == CONFIG_BOOLEAN_AUTO &&
809
+ (Icmp6InMsgs ||
810
+ Icmp6OutMsgs ||
811
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
812
do_icmp = CONFIG_BOOLEAN_YES;
813
static RRDSET *st = NULL;
814
static RRDDIM *rd_Icmp6InMsgs = NULL,
@@ -816,7 +842,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
842
843
// --------------------------------------------------------------------
844
819
- if(do_icmp_redir == CONFIG_BOOLEAN_YES || (do_icmp_redir == CONFIG_BOOLEAN_AUTO && (Icmp6InRedirects || Icmp6OutRedirects))) {
845
+ if(do_icmp_redir == CONFIG_BOOLEAN_YES || (do_icmp_redir == CONFIG_BOOLEAN_AUTO &&
846
+ (Icmp6InRedirects ||
847
+ Icmp6OutRedirects ||
848
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
849
do_icmp_redir = CONFIG_BOOLEAN_YES;
850
static RRDSET *st = NULL;
851
static RRDDIM *rd_Icmp6InRedirects = NULL,
@@ -850,20 +879,19 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
879
880
// --------------------------------------------------------------------
881
853
- if(do_icmp_errors == CONFIG_BOOLEAN_YES || (do_icmp_errors == CONFIG_BOOLEAN_AUTO
854
- && (
855
- Icmp6InErrors
856
- || Icmp6OutErrors
857
- || Icmp6InCsumErrors
858
- || Icmp6InDestUnreachs
859
- || Icmp6InPktTooBigs
860
- || Icmp6InTimeExcds
861
- || Icmp6InParmProblems
862
- || Icmp6OutDestUnreachs
863
- || Icmp6OutPktTooBigs
864
- || Icmp6OutTimeExcds
865
- || Icmp6OutParmProblems
866
- ))) {
882
+ if(do_icmp_errors == CONFIG_BOOLEAN_YES || (do_icmp_errors == CONFIG_BOOLEAN_AUTO &&
883
+ (Icmp6InErrors ||
884
+ Icmp6OutErrors ||
885
+ Icmp6InCsumErrors ||
886
+ Icmp6InDestUnreachs ||
887
+ Icmp6InPktTooBigs ||
888
+ Icmp6InTimeExcds ||
889
+ Icmp6InParmProblems ||
890
+ Icmp6OutDestUnreachs ||
891
+ Icmp6OutPktTooBigs ||
892
+ Icmp6OutTimeExcds ||
893
+ Icmp6OutParmProblems ||
894
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
895
do_icmp_errors = CONFIG_BOOLEAN_YES;
896
static RRDSET *st = NULL;
897
static RRDDIM *rd_InErrors = NULL,
@@ -924,13 +952,12 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
952
953
// --------------------------------------------------------------------
954
927
- if(do_icmp_echos == CONFIG_BOOLEAN_YES || (do_icmp_echos == CONFIG_BOOLEAN_AUTO
928
- && (
929
- Icmp6InEchos
930
- || Icmp6OutEchos
931
- || Icmp6InEchoReplies
932
- || Icmp6OutEchoReplies
933
- ))) {
955
+ if(do_icmp_echos == CONFIG_BOOLEAN_YES || (do_icmp_echos == CONFIG_BOOLEAN_AUTO &&
956
+ (Icmp6InEchos ||
957
+ Icmp6OutEchos ||
958
+ Icmp6InEchoReplies ||
959
+ Icmp6OutEchoReplies ||
960
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
961
do_icmp_echos = CONFIG_BOOLEAN_YES;
962
static RRDSET *st = NULL;
963
static RRDDIM *rd_InEchos = NULL,
@@ -970,15 +997,14 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
997
998
// --------------------------------------------------------------------
999
973
- if(do_icmp_groupmemb == CONFIG_BOOLEAN_YES || (do_icmp_groupmemb == CONFIG_BOOLEAN_AUTO
974
- && (
975
- Icmp6InGroupMembQueries
976
- || Icmp6OutGroupMembQueries
977
- || Icmp6InGroupMembResponses
978
- || Icmp6OutGroupMembResponses
979
- || Icmp6InGroupMembReductions
980
- || Icmp6OutGroupMembReductions
981
- ))) {
1000
+ if(do_icmp_groupmemb == CONFIG_BOOLEAN_YES || (do_icmp_groupmemb == CONFIG_BOOLEAN_AUTO &&
1001
+ (Icmp6InGroupMembQueries ||
1002
+ Icmp6OutGroupMembQueries ||
1003
+ Icmp6InGroupMembResponses ||
1004
+ Icmp6OutGroupMembResponses ||
1005
+ Icmp6InGroupMembReductions ||
1006
+ Icmp6OutGroupMembReductions ||
1007
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1008
do_icmp_groupmemb = CONFIG_BOOLEAN_YES;
1009
static RRDSET *st = NULL;
1010
static RRDDIM *rd_InQueries = NULL,
@@ -1023,13 +1049,12 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
1049
1050
// --------------------------------------------------------------------
1051
1026
- if(do_icmp_router == CONFIG_BOOLEAN_YES || (do_icmp_router == CONFIG_BOOLEAN_AUTO
1027
- && (
1028
- Icmp6InRouterSolicits
1029
- || Icmp6OutRouterSolicits
1030
- || Icmp6InRouterAdvertisements
1031
- || Icmp6OutRouterAdvertisements
1032
- ))) {
1052
+ if(do_icmp_router == CONFIG_BOOLEAN_YES || (do_icmp_router == CONFIG_BOOLEAN_AUTO &&
1053
+ (Icmp6InRouterSolicits ||
1054
+ Icmp6OutRouterSolicits ||
1055
+ Icmp6InRouterAdvertisements ||
1056
+ Icmp6OutRouterAdvertisements ||
1057
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1058
do_icmp_router = CONFIG_BOOLEAN_YES;
1059
static RRDSET *st = NULL;
1060
static RRDDIM *rd_InSolicits = NULL,
@@ -1069,13 +1094,12 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
1094
1095
// --------------------------------------------------------------------
1096
1072
- if(do_icmp_neighbor == CONFIG_BOOLEAN_YES || (do_icmp_neighbor == CONFIG_BOOLEAN_AUTO
1073
- && (
1074
- Icmp6InNeighborSolicits
1075
- || Icmp6OutNeighborSolicits
1076
- || Icmp6InNeighborAdvertisements
1077
- || Icmp6OutNeighborAdvertisements
1078
- ))) {
1097
+ if(do_icmp_neighbor == CONFIG_BOOLEAN_YES || (do_icmp_neighbor == CONFIG_BOOLEAN_AUTO &&
1098
+ (Icmp6InNeighborSolicits ||
1099
+ Icmp6OutNeighborSolicits ||
1100
+ Icmp6InNeighborAdvertisements ||
1101
+ Icmp6OutNeighborAdvertisements ||
1102
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1103
do_icmp_neighbor = CONFIG_BOOLEAN_YES;
1104
static RRDSET *st = NULL;
1105
static RRDDIM *rd_InSolicits = NULL,
@@ -1115,7 +1139,10 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
1139
1140
// --------------------------------------------------------------------
1141
1118
- if(do_icmp_mldv2 == CONFIG_BOOLEAN_YES || (do_icmp_mldv2 == CONFIG_BOOLEAN_AUTO && (Icmp6InMLDv2Reports || Icmp6OutMLDv2Reports))) {
1142
+ if(do_icmp_mldv2 == CONFIG_BOOLEAN_YES || (do_icmp_mldv2 == CONFIG_BOOLEAN_AUTO &&
1143
+ (Icmp6InMLDv2Reports ||
1144
+ Icmp6OutMLDv2Reports ||
1145
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1146
do_icmp_mldv2 = CONFIG_BOOLEAN_YES;
1147
static RRDSET *st = NULL;
1148
static RRDDIM *rd_InMLDv2Reports = NULL,
@@ -1149,19 +1176,18 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
1176
1177
// --------------------------------------------------------------------
1178
1152
- if(do_icmp_types == CONFIG_BOOLEAN_YES || (do_icmp_types == CONFIG_BOOLEAN_AUTO
1153
- && (
1154
- Icmp6InType1
1155
- || Icmp6InType128
1156
- || Icmp6InType129
1157
- || Icmp6InType136
1158
- || Icmp6OutType1
1159
- || Icmp6OutType128
1160
- || Icmp6OutType129
1161
- || Icmp6OutType133
1162
- || Icmp6OutType135
1163
- || Icmp6OutType143
1164
- ))) {
1179
+ if(do_icmp_types == CONFIG_BOOLEAN_YES || (do_icmp_types == CONFIG_BOOLEAN_AUTO &&
1180
+ (Icmp6InType1 ||
1181
+ Icmp6InType128 ||
1182
+ Icmp6InType129 ||
1183
+ Icmp6InType136 ||
1184
+ Icmp6OutType1 ||
1185
+ Icmp6OutType128 ||
1186
+ Icmp6OutType129 ||
1187
+ Icmp6OutType133 ||
1188
+ Icmp6OutType135 ||
1189
+ Icmp6OutType143 ||
1190
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1191
do_icmp_types = CONFIG_BOOLEAN_YES;
1192
static RRDSET *st = NULL;
1193
static RRDDIM *rd_InType1 = NULL,
@@ -1219,13 +1245,12 @@ int do_proc_net_snmp6(int update_every, usec_t dt) {
1245
1246
// --------------------------------------------------------------------
1247
1222
- if(do_ect == CONFIG_BOOLEAN_YES || (do_ect == CONFIG_BOOLEAN_AUTO
1223
- && (
1224
- Ip6InNoECTPkts
1225
- || Ip6InECT1Pkts
1226
- || Ip6InECT0Pkts
1227
- || Ip6InCEPkts
1228
- ))) {
1248
+ if(do_ect == CONFIG_BOOLEAN_YES || (do_ect == CONFIG_BOOLEAN_AUTO &&
1249
+ (Ip6InNoECTPkts ||
1250
+ Ip6InECT1Pkts ||
1251
+ Ip6InECT0Pkts ||
1252
+ Ip6InCEPkts ||
1253
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
1254
do_ect = CONFIG_BOOLEAN_YES;
1255
static RRDSET *st = NULL;
1256
static RRDDIM *rd_InNoECTPkts = NULL,
collectors/proc.plugin/proc_net_sockstat.c
+29
-9
@@ -218,7 +218,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
218
219
// ------------------------------------------------------------------------
220
221
- if(do_sockets == CONFIG_BOOLEAN_YES || (do_sockets == CONFIG_BOOLEAN_AUTO && sockstat_root.sockets_used)) {
221
+ if(do_sockets == CONFIG_BOOLEAN_YES || (do_sockets == CONFIG_BOOLEAN_AUTO &&
222
+ (sockstat_root.sockets_used ||
223
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
224
do_sockets = CONFIG_BOOLEAN_YES;
225
226
static RRDSET *st = NULL;
@@ -250,7 +252,12 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
252
253
// ------------------------------------------------------------------------
254
253
- if(do_tcp_sockets == CONFIG_BOOLEAN_YES || (do_tcp_sockets == CONFIG_BOOLEAN_AUTO && (sockstat_root.tcp_inuse || sockstat_root.tcp_orphan || sockstat_root.tcp_tw || sockstat_root.tcp_alloc))) {
255
+ if(do_tcp_sockets == CONFIG_BOOLEAN_YES || (do_tcp_sockets == CONFIG_BOOLEAN_AUTO &&
256
+ (sockstat_root.tcp_inuse ||
257
+ sockstat_root.tcp_orphan ||
258
+ sockstat_root.tcp_tw ||
259
+ sockstat_root.tcp_alloc ||
260
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
261
do_tcp_sockets = CONFIG_BOOLEAN_YES;
262
263
static RRDSET *st = NULL;
@@ -291,7 +298,8 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
298
299
// ------------------------------------------------------------------------
300
294
- if(do_tcp_mem == CONFIG_BOOLEAN_YES || (do_tcp_mem == CONFIG_BOOLEAN_AUTO && sockstat_root.tcp_mem)) {
301
+ if(do_tcp_mem == CONFIG_BOOLEAN_YES || (do_tcp_mem == CONFIG_BOOLEAN_AUTO &&
302
+ (sockstat_root.tcp_mem || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
303
do_tcp_mem = CONFIG_BOOLEAN_YES;
304
305
static RRDSET *st = NULL;
@@ -323,7 +331,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
331
332
// ------------------------------------------------------------------------
333
326
- if(do_udp_sockets == CONFIG_BOOLEAN_YES || (do_udp_sockets == CONFIG_BOOLEAN_AUTO && sockstat_root.udp_inuse)) {
334
+ if(do_udp_sockets == CONFIG_BOOLEAN_YES || (do_udp_sockets == CONFIG_BOOLEAN_AUTO &&
335
+ (sockstat_root.udp_inuse ||
336
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
337
do_udp_sockets = CONFIG_BOOLEAN_YES;
338
339
static RRDSET *st = NULL;
@@ -355,7 +365,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
365
366
// ------------------------------------------------------------------------
367
358
- if(do_udp_mem == CONFIG_BOOLEAN_YES || (do_udp_mem == CONFIG_BOOLEAN_AUTO && sockstat_root.udp_mem)) {
368
+ if(do_udp_mem == CONFIG_BOOLEAN_YES || (do_udp_mem == CONFIG_BOOLEAN_AUTO &&
369
+ (sockstat_root.udp_mem ||
370
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
371
do_udp_mem = CONFIG_BOOLEAN_YES;
372
373
static RRDSET *st = NULL;
@@ -387,7 +399,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
399
400
// ------------------------------------------------------------------------
401
390
- if(do_udplite_sockets == CONFIG_BOOLEAN_YES || (do_udplite_sockets == CONFIG_BOOLEAN_AUTO && sockstat_root.udplite_inuse)) {
402
+ if(do_udplite_sockets == CONFIG_BOOLEAN_YES || (do_udplite_sockets == CONFIG_BOOLEAN_AUTO &&
403
+ (sockstat_root.udplite_inuse ||
404
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
405
do_udplite_sockets = CONFIG_BOOLEAN_YES;
406
407
static RRDSET *st = NULL;
@@ -419,7 +433,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
433
434
// ------------------------------------------------------------------------
435
422
- if(do_raw_sockets == CONFIG_BOOLEAN_YES || (do_raw_sockets == CONFIG_BOOLEAN_AUTO && sockstat_root.raw_inuse)) {
436
+ if(do_raw_sockets == CONFIG_BOOLEAN_YES || (do_raw_sockets == CONFIG_BOOLEAN_AUTO &&
437
+ (sockstat_root.raw_inuse ||
438
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
439
do_raw_sockets = CONFIG_BOOLEAN_YES;
440
441
static RRDSET *st = NULL;
@@ -451,7 +467,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
467
468
// ------------------------------------------------------------------------
469
454
- if(do_frag_sockets == CONFIG_BOOLEAN_YES || (do_frag_sockets == CONFIG_BOOLEAN_AUTO && sockstat_root.frag_inuse)) {
470
+ if(do_frag_sockets == CONFIG_BOOLEAN_YES || (do_frag_sockets == CONFIG_BOOLEAN_AUTO &&
471
+ (sockstat_root.frag_inuse ||
472
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
473
do_frag_sockets = CONFIG_BOOLEAN_YES;
474
475
static RRDSET *st = NULL;
@@ -483,7 +501,9 @@ int do_proc_net_sockstat(int update_every, usec_t dt) {
501
502
// ------------------------------------------------------------------------
503
486
- if(do_frag_mem == CONFIG_BOOLEAN_YES || (do_frag_mem == CONFIG_BOOLEAN_AUTO && sockstat_root.frag_memory)) {
504
+ if(do_frag_mem == CONFIG_BOOLEAN_YES || (do_frag_mem == CONFIG_BOOLEAN_AUTO &&
505
+ (sockstat_root.frag_memory ||
506
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
507
do_frag_mem = CONFIG_BOOLEAN_YES;
508
509
static RRDSET *st = NULL;
collectors/proc.plugin/proc_net_sockstat6.c
+15
-5
@@ -111,7 +111,9 @@ int do_proc_net_sockstat6(int update_every, usec_t dt) {
111
112
// ------------------------------------------------------------------------
113
114
- if(do_tcp_sockets == CONFIG_BOOLEAN_YES || (do_tcp_sockets == CONFIG_BOOLEAN_AUTO && (sockstat6_root.tcp6_inuse))) {
114
+ if(do_tcp_sockets == CONFIG_BOOLEAN_YES || (do_tcp_sockets == CONFIG_BOOLEAN_AUTO &&
115
+ (sockstat6_root.tcp6_inuse ||
116
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
117
do_tcp_sockets = CONFIG_BOOLEAN_YES;
118
119
static RRDSET *st = NULL;
@@ -143,7 +145,9 @@ int do_proc_net_sockstat6(int update_every, usec_t dt) {
145
146
// ------------------------------------------------------------------------
147
146
- if(do_udp_sockets == CONFIG_BOOLEAN_YES || (do_udp_sockets == CONFIG_BOOLEAN_AUTO && sockstat6_root.udp6_inuse)) {
148
+ if(do_udp_sockets == CONFIG_BOOLEAN_YES || (do_udp_sockets == CONFIG_BOOLEAN_AUTO &&
149
+ (sockstat6_root.udp6_inuse ||
150
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
151
do_udp_sockets = CONFIG_BOOLEAN_YES;
152
153
static RRDSET *st = NULL;
@@ -175,7 +179,9 @@ int do_proc_net_sockstat6(int update_every, usec_t dt) {
179
180
// ------------------------------------------------------------------------
181
178
- if(do_udplite_sockets == CONFIG_BOOLEAN_YES || (do_udplite_sockets == CONFIG_BOOLEAN_AUTO && sockstat6_root.udplite6_inuse)) {
182
+ if(do_udplite_sockets == CONFIG_BOOLEAN_YES || (do_udplite_sockets == CONFIG_BOOLEAN_AUTO &&
183
+ (sockstat6_root.udplite6_inuse ||
184
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
185
do_udplite_sockets = CONFIG_BOOLEAN_YES;
186
187
static RRDSET *st = NULL;
@@ -207,7 +213,9 @@ int do_proc_net_sockstat6(int update_every, usec_t dt) {
213
214
// ------------------------------------------------------------------------
215
210
- if(do_raw_sockets == CONFIG_BOOLEAN_YES || (do_raw_sockets == CONFIG_BOOLEAN_AUTO && sockstat6_root.raw6_inuse)) {
216
+ if(do_raw_sockets == CONFIG_BOOLEAN_YES || (do_raw_sockets == CONFIG_BOOLEAN_AUTO &&
217
+ (sockstat6_root.raw6_inuse ||
218
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
219
do_raw_sockets = CONFIG_BOOLEAN_YES;
220
221
static RRDSET *st = NULL;
@@ -239,7 +247,9 @@ int do_proc_net_sockstat6(int update_every, usec_t dt) {
247
248
// ------------------------------------------------------------------------
249
242
- if(do_frag_sockets == CONFIG_BOOLEAN_YES || (do_frag_sockets == CONFIG_BOOLEAN_AUTO && sockstat6_root.frag6_inuse)) {
250
+ if(do_frag_sockets == CONFIG_BOOLEAN_YES || (do_frag_sockets == CONFIG_BOOLEAN_AUTO &&
251
+ (sockstat6_root.frag6_inuse ||
252
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
253
do_frag_sockets = CONFIG_BOOLEAN_YES;
254
255
static RRDSET *st = NULL;
collectors/proc.plugin/proc_net_stat_synproxy.c
+8
-4
@@ -59,7 +59,8 @@ int do_proc_net_stat_synproxy(int update_every, usec_t dt) {
59
60
// --------------------------------------------------------------------
61
62
- if((do_entries == CONFIG_BOOLEAN_AUTO && events) || do_entries == CONFIG_BOOLEAN_YES) {
62
+ if(do_entries == CONFIG_BOOLEAN_YES || (do_entries == CONFIG_BOOLEAN_AUTO &&
63
+ (events || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
64
do_entries = CONFIG_BOOLEAN_YES;
65
66
static RRDSET *st = NULL;
@@ -89,7 +90,8 @@ int do_proc_net_stat_synproxy(int update_every, usec_t dt) {
90
91
// --------------------------------------------------------------------
92
92
- if((do_syns == CONFIG_BOOLEAN_AUTO && events) || do_syns == CONFIG_BOOLEAN_YES) {
93
+ if(do_syns == CONFIG_BOOLEAN_YES || (do_syns == CONFIG_BOOLEAN_AUTO &&
94
+ (events || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
95
do_syns = CONFIG_BOOLEAN_YES;
96
97
static RRDSET *st = NULL;
@@ -119,7 +121,8 @@ int do_proc_net_stat_synproxy(int update_every, usec_t dt) {
121
122
// --------------------------------------------------------------------
123
122
- if((do_reopened == CONFIG_BOOLEAN_AUTO && events) || do_reopened == CONFIG_BOOLEAN_YES) {
124
+ if(do_reopened == CONFIG_BOOLEAN_YES || (do_reopened == CONFIG_BOOLEAN_AUTO &&
125
+ (events || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
126
do_reopened = CONFIG_BOOLEAN_YES;
127
128
static RRDSET *st = NULL;
@@ -149,7 +152,8 @@ int do_proc_net_stat_synproxy(int update_every, usec_t dt) {
152
153
// --------------------------------------------------------------------
154
152
- if((do_cookies == CONFIG_BOOLEAN_AUTO && events) || do_cookies == CONFIG_BOOLEAN_YES) {
155
+ if(do_cookies == CONFIG_BOOLEAN_YES || (do_cookies == CONFIG_BOOLEAN_AUTO &&
156
+ (events || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
157
do_cookies = CONFIG_BOOLEAN_YES;
158
159
static RRDSET *st = NULL;
collectors/proc.plugin/proc_spl_kstat_zfs.c
+2
@@ -124,6 +124,8 @@ int do_proc_spl_kstat_zfs_arcstats(int update_every, usec_t dt) {
124
dirname = config_get("plugin:proc:" ZFS_PROC_ARCSTATS, "directory to monitor", filename);
125
126
show_zero_charts = config_get_boolean_ondemand("plugin:proc:" ZFS_PROC_ARCSTATS, "show zero charts", CONFIG_BOOLEAN_NO);
127
+ if(show_zero_charts == CONFIG_BOOLEAN_AUTO && netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES)
128
+ show_zero_charts = CONFIG_BOOLEAN_YES;
129
if(unlikely(show_zero_charts == CONFIG_BOOLEAN_YES))
130
do_zfs_stats = 1;
131
}
collectors/proc.plugin/proc_vmstat.c
+6
-2
@@ -43,7 +43,9 @@ int do_proc_vmstat(int update_every, usec_t dt) {
43
arl_expect(arl_base, "pswpin", &pswpin);
44
arl_expect(arl_base, "pswpout", &pswpout);
45
46
- if(do_numa == CONFIG_BOOLEAN_YES || (do_numa == CONFIG_BOOLEAN_AUTO && get_numa_node_count() >= 2)) {
46
+ if(do_numa == CONFIG_BOOLEAN_YES || (do_numa == CONFIG_BOOLEAN_AUTO &&
47
+ (get_numa_node_count() >= 2 ||
48
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
49
arl_expect(arl_base, "numa_foreign", &numa_foreign);
50
arl_expect(arl_base, "numa_hint_faults_local", &numa_hint_faults_local);
51
arl_expect(arl_base, "numa_hint_faults", &numa_hint_faults);
@@ -91,7 +93,9 @@ int do_proc_vmstat(int update_every, usec_t dt) {
93
94
// --------------------------------------------------------------------
95
94
- if(pswpin || pswpout || do_swapio == CONFIG_BOOLEAN_YES) {
96
+ if(do_swapio == CONFIG_BOOLEAN_YES || (do_swapio == CONFIG_BOOLEAN_AUTO &&
97
+ (pswpin || pswpout ||
98
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
99
do_swapio = CONFIG_BOOLEAN_YES;
100
101
static RRDSET *st_swapio = NULL;
collectors/proc.plugin/sys_devices_system_edac_mc.c
+4
-2
@@ -128,7 +128,8 @@ int do_proc_sys_devices_system_edac_mc(int update_every, usec_t dt) {
128
129
// --------------------------------------------------------------------
130
131
- if(do_ce == CONFIG_BOOLEAN_YES || (do_ce == CONFIG_BOOLEAN_AUTO && ce_sum > 0)) {
131
+ if(do_ce == CONFIG_BOOLEAN_YES || (do_ce == CONFIG_BOOLEAN_AUTO &&
132
+ (ce_sum > 0 || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
133
do_ce = CONFIG_BOOLEAN_YES;
134
135
static RRDSET *ce_st = NULL;
@@ -166,7 +167,8 @@ int do_proc_sys_devices_system_edac_mc(int update_every, usec_t dt) {
167
168
// --------------------------------------------------------------------
169
169
- if(do_ue == CONFIG_BOOLEAN_YES || (do_ue == CONFIG_BOOLEAN_AUTO && ue_sum > 0)) {
170
+ if(do_ue == CONFIG_BOOLEAN_YES || (do_ue == CONFIG_BOOLEAN_AUTO &&
171
+ (ue_sum > 0 || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
172
do_ue = CONFIG_BOOLEAN_YES;
173
174
static RRDSET *ue_st = NULL;
collectors/proc.plugin/sys_devices_system_node.c
+2
-1
@@ -83,7 +83,8 @@ int do_proc_sys_devices_system_node(int update_every, usec_t dt) {
83
hash_numa_miss = simple_hash("numa_miss");
84
}
85
86
- if(do_numastat == CONFIG_BOOLEAN_YES || (do_numastat == CONFIG_BOOLEAN_AUTO && numa_node_count >= 2)) {
86
+ if(do_numastat == CONFIG_BOOLEAN_YES || (do_numastat == CONFIG_BOOLEAN_AUTO &&
87
+ (numa_node_count >= 2 || netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
88
for(m = numa_root; m; m = m->next) {
89
if(m->numastat_filename) {
90
collectors/proc.plugin/sys_fs_btrfs.c
+12
-4
@@ -542,7 +542,9 @@ int do_sys_fs_btrfs(int update_every, usec_t dt) {
542
// --------------------------------------------------------------------
543
// allocation/disks
544
545
- if(do_allocation_disks == CONFIG_BOOLEAN_YES || (do_allocation_disks == CONFIG_BOOLEAN_AUTO && node->all_disks_total && node->allocation_data_disk_total)) {
545
+ if(do_allocation_disks == CONFIG_BOOLEAN_YES || (do_allocation_disks == CONFIG_BOOLEAN_AUTO &&
546
+ ((node->all_disks_total && node->allocation_data_disk_total) ||
547
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
548
do_allocation_disks = CONFIG_BOOLEAN_YES;
549
550
if(unlikely(!node->st_allocation_disks)) {
@@ -598,7 +600,9 @@ int do_sys_fs_btrfs(int update_every, usec_t dt) {
600
// --------------------------------------------------------------------
601
// allocation/data
602
601
- if(do_allocation_data == CONFIG_BOOLEAN_YES || (do_allocation_data == CONFIG_BOOLEAN_AUTO && node->allocation_data_total_bytes)) {
603
+ if(do_allocation_data == CONFIG_BOOLEAN_YES || (do_allocation_data == CONFIG_BOOLEAN_AUTO &&
604
+ (node->allocation_data_total_bytes ||
605
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
606
do_allocation_data = CONFIG_BOOLEAN_YES;
607
608
if(unlikely(!node->st_allocation_data)) {
@@ -639,7 +643,9 @@ int do_sys_fs_btrfs(int update_every, usec_t dt) {
643
// --------------------------------------------------------------------
644
// allocation/metadata
645
642
- if(do_allocation_metadata == CONFIG_BOOLEAN_YES || (do_allocation_metadata == CONFIG_BOOLEAN_AUTO && node->allocation_metadata_total_bytes)) {
646
+ if(do_allocation_metadata == CONFIG_BOOLEAN_YES || (do_allocation_metadata == CONFIG_BOOLEAN_AUTO &&
647
+ (node->allocation_metadata_total_bytes ||
648
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
649
do_allocation_metadata = CONFIG_BOOLEAN_YES;
650
651
if(unlikely(!node->st_allocation_metadata)) {
@@ -682,7 +688,9 @@ int do_sys_fs_btrfs(int update_every, usec_t dt) {
688
// --------------------------------------------------------------------
689
// allocation/system
690
685
- if(do_allocation_system == CONFIG_BOOLEAN_YES || (do_allocation_system == CONFIG_BOOLEAN_AUTO && node->allocation_system_total_bytes)) {
691
+ if(do_allocation_system == CONFIG_BOOLEAN_YES || (do_allocation_system == CONFIG_BOOLEAN_AUTO &&
692
+ (node->allocation_system_total_bytes ||
693
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
694
do_allocation_system = CONFIG_BOOLEAN_YES;
695
696
if(unlikely(!node->st_allocation_system)) {
collectors/proc.plugin/sys_kernel_mm_ksm.c
+2
-2
@@ -89,7 +89,7 @@ int do_sys_kernel_mm_ksm(int update_every, usec_t dt) {
89
offered = pages_sharing + pages_shared + pages_unshared + pages_volatile;
90
saved = pages_sharing;
91
92
- if(unlikely(!offered /*|| !pages_to_scan*/)) return 0;
92
+ if(unlikely(!offered /*|| !pages_to_scan*/ && netdata_zero_metrics_enabled == CONFIG_BOOLEAN_NO)) return 0;
93
94
// --------------------------------------------------------------------
95
@@ -192,7 +192,7 @@ int do_sys_kernel_mm_ksm(int update_every, usec_t dt) {
192
else
193
rrdset_next(st_mem_ksm_ratios);
194
195
- rrddim_set_by_pointer(st_mem_ksm_ratios, rd_savings, (saved * 1000000) / offered);
195
+ rrddim_set_by_pointer(st_mem_ksm_ratios, rd_savings, offered ? (saved * 1000000) / offered : 0);
196
197
rrdset_done(st_mem_ksm_ratios);
198
}
collectors/tc.plugin/README.md
+1
-1
@@ -191,7 +191,7 @@ Add the following configuration option in `/etc/netdata.conf`:
191
Finally, create `/etc/netdata/tc-qos-helper.conf` with this content:
192
```tc_show="class"```
193
194
-Please note, that by default Netdata will enable monitoring metrics only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Set `yes` for a chart instead of `auto` to enable it permanently.
194
+Please note, that by default Netdata will enable monitoring metrics only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Set `yes` for a chart instead of `auto` to enable it permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
195
196
197
[]()
collectors/tc.plugin/plugin_tc.c
+15
-5
@@ -382,7 +382,9 @@ static inline void tc_device_commit(struct tc_device *d) {
382
// --------------------------------------------------------------------
383
// bytes
384
385
- if(d->enabled_bytes == CONFIG_BOOLEAN_YES || (d->enabled_bytes == CONFIG_BOOLEAN_AUTO && bytes_sum)) {
385
+ if(d->enabled_bytes == CONFIG_BOOLEAN_YES || (d->enabled_bytes == CONFIG_BOOLEAN_AUTO &&
386
+ (bytes_sum ||
387
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
388
d->enabled_bytes = CONFIG_BOOLEAN_YES;
389
390
if(unlikely(!d->st_bytes))
@@ -425,7 +427,9 @@ static inline void tc_device_commit(struct tc_device *d) {
427
// --------------------------------------------------------------------
428
// packets
429
428
- if(d->enabled_packets == CONFIG_BOOLEAN_YES || (d->enabled_packets == CONFIG_BOOLEAN_AUTO && packets_sum)) {
430
+ if(d->enabled_packets == CONFIG_BOOLEAN_YES || (d->enabled_packets == CONFIG_BOOLEAN_AUTO &&
431
+ (packets_sum ||
432
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
433
d->enabled_packets = CONFIG_BOOLEAN_YES;
434
435
if(unlikely(!d->st_packets)) {
@@ -478,7 +482,9 @@ static inline void tc_device_commit(struct tc_device *d) {
482
// --------------------------------------------------------------------
483
// dropped
484
481
- if(d->enabled_dropped == CONFIG_BOOLEAN_YES || (d->enabled_dropped == CONFIG_BOOLEAN_AUTO && dropped_sum)) {
485
+ if(d->enabled_dropped == CONFIG_BOOLEAN_YES || (d->enabled_dropped == CONFIG_BOOLEAN_AUTO &&
486
+ (dropped_sum ||
487
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
488
d->enabled_dropped = CONFIG_BOOLEAN_YES;
489
490
if(unlikely(!d->st_dropped)) {
@@ -531,7 +537,9 @@ static inline void tc_device_commit(struct tc_device *d) {
537
// --------------------------------------------------------------------
538
// tokens
539
534
- if(d->enabled_tokens == CONFIG_BOOLEAN_YES || (d->enabled_tokens == CONFIG_BOOLEAN_AUTO && tokens_sum)) {
540
+ if(d->enabled_tokens == CONFIG_BOOLEAN_YES || (d->enabled_tokens == CONFIG_BOOLEAN_AUTO &&
541
+ (tokens_sum ||
542
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
543
d->enabled_tokens = CONFIG_BOOLEAN_YES;
544
545
if(unlikely(!d->st_tokens)) {
@@ -585,7 +593,9 @@ static inline void tc_device_commit(struct tc_device *d) {
593
// --------------------------------------------------------------------
594
// ctokens
595
588
- if(d->enabled_ctokens == CONFIG_BOOLEAN_YES || (d->enabled_ctokens == CONFIG_BOOLEAN_AUTO && ctokens_sum)) {
596
+ if(d->enabled_ctokens == CONFIG_BOOLEAN_YES || (d->enabled_ctokens == CONFIG_BOOLEAN_AUTO &&
597
+ (ctokens_sum ||
598
+ netdata_zero_metrics_enabled == CONFIG_BOOLEAN_YES))) {
599
d->enabled_ctokens = CONFIG_BOOLEAN_YES;
600
601
if(unlikely(!d->st_ctokens)) {
daemon/common.h
+1
@@ -78,6 +78,7 @@ extern char *netdata_configured_varlib_dir;
78
extern char *netdata_configured_home_dir;
79
extern char *netdata_configured_host_prefix;
80
extern char *netdata_configured_timezone;
81
+extern int netdata_zero_metrics_enabled;
82
extern int netdata_anonymous_statistics_enabled;
83
84
int netdata_ready;
daemon/config/README.md
+2
-1
@@ -74,6 +74,7 @@ gap when lost iterations above | `1` |
74
cleanup orphan hosts after seconds | `3600` | How long to wait until automatically removing from the DB a remote netdata host (slave) that is no longer sending data.
75
delete obsolete charts files | `yes` | See [monitoring ephemeral containers](../../collectors/cgroups.plugin/#monitoring-ephemeral-containers), also affects the deletion of files for obsolete dimensions
76
delete orphan hosts files | `yes` | Set to `no` to disable non-responsive host removal.
77
+enable zero metrics | `no` | Set to `yes` to show charts when all their metrics are zero.
78
79
### [web] section options
80
@@ -128,7 +129,7 @@ The configuration options for plugins appear in sections following the pattern `
129
130
Most internal plugins will provide additional options. Check [Internal Plugins](../../collectors/) for more information.
131
131
-Please note, that by default Netdata will enable monitoring metrics for disks, memory, and network only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Use `yes` instead of `auto` in plugin configuration sections to enable these charts permanently.
132
+Please note, that by default Netdata will enable monitoring metrics for disks, memory, and network only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Use `yes` instead of `auto` in plugin configuration sections to enable these charts permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
133
134
#### External plugins
135
daemon/main.c
+4
-1
@@ -2,6 +2,7 @@
2
3
#include "common.h"
4
5
+int netdata_zero_metrics_enabled;
6
int netdata_anonymous_statistics_enabled;
7
8
struct config netdata_config = {
@@ -1214,6 +1215,8 @@ int main(int argc, char **argv) {
1215
1216
web_server_config_options();
1217
1218
+ netdata_zero_metrics_enabled = config_get_boolean_ondemand(CONFIG_SECTION_GLOBAL, "enable zero metrics", CONFIG_BOOLEAN_NO);
1219
+
1220
for (i = 0; static_threads[i].name != NULL ; i++) {
1221
struct netdata_static_thread *st = &static_threads[i];
1222
@@ -1227,7 +1230,7 @@ int main(int argc, char **argv) {
1230
1231
info("netdata initialization completed. Enjoy real-time performance monitoring!");
1232
netdata_ready = 1;
1230
-
1233
+
1234
send_statistics("START", "-", "-");
1235
1236
// ------------------------------------------------------------------------
docs/configuration-guide.md
+1
-1
@@ -59,7 +59,7 @@ Entire plugins can be turned off from the [netdata.conf [plugins]](../daemon/con
59
60
##### Show charts with zero metrics
61
62
-By default, Netdata will enable monitoring metrics for disks, memory, and network only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Use `yes` instead of `auto` in plugin configuration sections to enable these charts permanently.
62
+By default, Netdata will enable monitoring metrics for disks, memory, and network only when they are not zero. If they are constantly zero they are ignored. Metrics that will start having values, after netdata is started, will be detected and charts will be automatically added to the dashboard (a refresh of the dashboard is needed for them to appear though). Use `yes` instead of `auto` in plugin configuration sections to enable these charts permanently. You can also set the `enable zero metrics` option to `yes` in the `[global]` section which enables charts with zero metrics for all internal Netdata plugins.
63
64
### Modify alarms and notifications
65