pkgsrc-WIP-changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
collectd: Update to 5.11.00
Module Name: pkgsrc-wip
Committed By: Edgar Fuß <ef%math.uni-bonn.de@localhost>
Pushed By: ef
Date: Mon Jul 20 17:22:32 2020 +0200
Changeset: 24f60eb964837cf37a90dbf1d61509e7a4115a76
Modified Files:
collectd-yajl/DESCR
collectd-yajl/Makefile
collectd/Makefile
collectd/Makefile.common
collectd/PLIST
collectd/distinfo
collectd/patches/patch-Makefile.am
collectd/patches/patch-configure.ac
collectd/patches/patch-src_bind.c
collectd/patches/patch-src_collectd.conf.in
collectd/patches/patch-src_cpu.c
collectd/patches/patch-src_df.c
collectd/patches/patch-src_entropy.c
collectd/patches/patch-src_irq.c
collectd/patches/patch-src_libcollectclient_network__buffer.c
collectd/patches/patch-src_memory.c
collectd/patches/patch-src_netstat__udp.c
collectd/patches/patch-src_nfs.c
collectd/patches/patch-src_processes.c
collectd/patches/patch-src_swap.c
collectd/patches/patch-src_tcpconns.c
collectd/patches/patch-src_utils_dns_dns.c
collectd/patches/patch-src_utils_format__kairosdb_format__kairosdb.c
Log Message:
collectd: Update to 5.11.00
Update collectd to 5.11.00 (upstream chnagelog at end of message)
New DEFAULT_PLUGINS: check_uptime logparser write_influxdb_udp write_syslog
Dropped from COLLECTD_LIBS: lvm2app
New to COLLECTD_LIBS: jansson pqos qpid-proton ssl slurm
New in CONFIGURE_ARGS: --with-cuda=no
New plugin: sysevent (in collectd-yail package)
Adaption to patches (list gives file patched, not patch name):
Makefile.am: modify cpkglocalstatedir instead of -DPKGLOCALSTATEDIR/$(mkinstalldirs) argument
configure.ac: adapted comment
src/memory.c: adapted pagesize/getpagesize() handling in NetBSD implementation to upstream re-work
multiple: new context (including #include paths, _Bool->bool, indentation), line numbers
Obsolete patches (or parts thereof), now included upstream:
Makefile.am: $< mis-use
configure.ac: broken tokyotyrant/libsupsclient detection, plugin_nfs=yes
src/daemon/collectd.c
src/daemon/common.h
src/disk.c
src/lua.c
src/nfs.c (but see below)
src/write_kafka.c
New patch content:
src/nfs.c: remove use of undefined supress_warning in NetBSD implementation
Still missing:
libssl handling
ipstats (FreeBSD implementation may be portable)
write_stackdriver (needs libssl and libcurl/yajl, could be integrated into collectd-yajl)
Upstream Changes:
2020-03-15, Version 5.11.0
* collectd: A Code of Conduct has been added. Thanks to Florian Forster.
#3401
* text protocol: Support for meta_data in PUTVAL has been added. Thanks
to Rafael Marinheiro, Dagobert Michelsen. #3381, #2726
* utils_cache: Internal API has changed - exposed meta_data_toc
function. Thanks to Javier Kohen. #3339
* filter_chain: Auto load matches and targets if AutoLoadPlugin option
is set. Thanks to Manuel Luis Sanmartín Rozada. #1034
* AMQP plugin: TLS support has been added. Thanks to Märt Bakhoff.
#3391
* Battery plugin: Read from Linux sysfs charge files has been added.
Thanks to Nimrod Maclomhair. #3190
* Buddyinfo plugin: New plugin for memory fragmentation info has been
added. Thanks to Asaf Kahlon. #3303
* capabilities plugin: New plugin to read static platform data has been
added. Thanks to Kamil Wiatrowski, Dagobert Michelsen. #3384, #3292
* DCPMM plugin: New plugin for Intel Optane DC Presistent Memory (DCPMM)
has been added. Thanks to Hari TG. #3274
* DF plugin: LogOnce option has been added. Thanks to themylogin. #2910
* DPDK Telemetry plugin: New plugin to fetch DPDK metrics (with intent
to replace dpdk_stat) has been added. Thanks to Reshma Pattan. #3273
* Disk plugin: A native (sysctl-based) implementation for NetBSD has
been added. Thanks to Edgar Fuß, Dagobert Michelsen. #3379, #3334
* GPU_Nvidia plugin: Configurable plugin instance by GPU name
and/or GPU index has been added. Thanks to Robert Dietrich. #3264
* Intel_PMU plugin: Support for uncore multi pmu has been added. Thanks
to Kamil Wiatrowski. #3388
* Ipstats plugin: New plugin to count incoming, outgoing, forwarded
packets on FreeBSD has been added. Thanks to Marco van Tol. #3187
* Java plugin: Support boolean input has been added. Thanks to Caden.
#3044
* Logparser plugin: New plugin for filtering and parsing log messages
has been added. Thanks to Kamil Wiatrowski, Krzysztof Matczak, Marcin
Możejko, Adrian Boczkowski, Radosław Jabłonski. #3045
* Network plugin: New metadata "network:ip_address" has been added.
Thanks to Takuro Ashie. #3191
* NFS plugin: An implementation for NetBSD (using sysctl) has been
added. Thanks to Edgar Fuß, Dagobert Michelsen. #3377, #3333
* NUT plugin: Support for the "output.realpower" value from the ups code
has been added. Thanks to Michael Poetters. #2528
* Redfish plugin: New read plugin to collect out-of-band sensor data
from Redfish endpoints has been added. Thanks to Marcin Możejko,
Adrian Boczkowski, Michal Kobyliński, Krzysztof Kepka, Man Singh,
Zoltan Szabo. #2926
* Slurm plugin: The new SLURM plugin gathers metrics from the SLURM
workload manager has been added. Thanks to Pablo Llopis. #3037
* Tail_CSV plugin: FieldSeparator option has been added. Thanks to
Dheeraj Gupta. #3394
* UBI plugin: The new "ubifs" plugin reports block state for flash
memory devices with UBIFS filesystem has been added. Thanks to Pierre
Lebleu. #3204
* Write_HTTP plugin: Ability to configure cURL statistics has been
added. Thanks to Nelson. #3265
* Write_Influxdb_UDP plugin: New plugin to send values to InfluxDB using
line protocol via udp has been added. Thanks to Carlos Peón Costa.
#3162
* Zookeeper plugin: 'quorum' stat has been added. Thanks to Chris Brown.
#2991
* collectd: Missing package in specfile has been fixed. Thanks to Fabien
Wernli. #3399
* collectd: Factored out read_text_file_contents for reading text files
and used it to fix a potential unterminated string in the thermal
plugin. Thanks to Igor Peshansky. #3359
* collectd: Error/warning messages has been extended with more
information. Thanks to Dagobert Michelsen. #3386
* collectd: Regression caused by #3217 has been fixed. Thanks to Pavel
Rochnyak. #3349
* build: version-gen.sh has been cleaned up. Thanks to William Pursell.
#2635
* build: Linking with Python 3.8 has been fixed. Thanks to Alexander
Meshcheryakov. #3344
* build: Avoid $< (implied source) in non-inference rules / Building
grpc with non-GNU make has been fixed. Thanks to Edgar Fuß, Dagobert
Michelsen. #3376, #3330
* filter_chain: Constant for max plugin name length introduced in #1034
has been fixed. Thanks to Dagobert Michelsen. #3385
* ignorelist: Coding style has been fixed. Thanks to Dagobert Michelsen.
#3397
* match_regex: Accept all data types of meta data. Thanks to Takuro
Ashie. #3231
* perl unixsock: Made the module robust against socket errors and
disconnects. Thanks to Guillem Jover. #3083
* tree-wide: Race condition when setting thread names has been fixed.
Thanks to Michael Kaufmann. #2762
* types.db: ping_droprate range spec has been fixed. Thanks to Yousong
Zhou. #3244
* utils/format_graphite: Comma sign has been added to the list of
prohibited characters. Thanks to Marat Salimzianov. #2998
* Aggregation plugin: Unreachable clause where both tmp_plugin and
tmp_plugin_instance are non-empty has been fixed. Thanks to Ling
Huang. #3350
* AMQP1 plugin: Leaks on error paths has been fixed. Thanks to Ryan
McCabe. #3352
* Apache plugin: BusyWorkers/IdleWorkers update has been fixed. Thanks
to Christian W. Zuckschwerdt. #3131
* CPU plugin, Memory plugin, Swap plugin, UUID plugin: Contain use of
sysctl / sysctrlbyname to BSD variants, as deprecated on Linux. Thanks
to Zebity Spring. #3342
* Exec plugin: Select has been replaced with poll to allow more then
1024 open file descriptors. Thanks to Kamil Wiatrowski. #3363
* GPU_Nvidia plugin: Build issues has been fixed. Thanks to Ruben
Kerkhof. #3393
* Interface plugin: Reorder so that Linux-specific code is actually
executed. Thanks to Dagobert Michelsen. #3378
* NFS plugin: Condition on existence of libkstat has been fixed. Thanks
to Dagobert Michelsen. #3382
* Network plugin: Memory leak has been fixed. Thanks to Ryan McCabe.
#3352
* Processes plugin: Number of running processes has been fixed. Thanks
to Bart De Vos. #3243
* Write_Riemann plugin: Memory leak has been fixed. Thanks to Fabien
Wernli. #3351
* Write_Stackdriver plugin: NaN value handing with gauge metrics has
been fixed. Thanks to Jaroslaw Przybylowicz. #3226
2019-10-17, Version 5.10.0
* turbostat plugin: Power metrics update for recent server CPUs. Thanks
to Chris MacNamara. #3276
* turbostat plugin: Fix warnings generated by the turbostat plugin.
Thanks to Ryan Mccabe. #3340
* ZFS ARC plugin: New cache values are now read on Linux. Thanks to
Jan-Philipp Litza. #3247, #2843
* connectivity plugin: monitor the network interface up/down status via
the netlink library. Thanks to Andrew Bays. #2622
* sysevent plugin: A new plugin that monitors rsyslog for system events.
Thanks to Andrew Bays. #2624
* procevent plugin: A new plugin that monitors process starts/stops via
netlink library. Thanks to Andrew Bays. #2623
* daemon: Check if plugin actually loaded before reporting configuration
issues. Thanks to Pavel Rochnyak. #3217
* daemon: Recover setlocale() call in src/daemon/collectd.c do_init().
Thanks to Pavel Rochnyak. #3181, #3214
* Build System: Only include <sys/sysctl.h> when needed. Thanks to Ruben
Kerkhof. #3298
* Build System: Link to libnsl.so if needed for inet_ntop(). Thanks to
Dagobert Michelsen. #3291
* Build System: Remove double "without" added by commit b781871. Thanks
to Fabrice Fontaine. #3261
* Build System: fix compile time issues. Thanks to Matthias Runge.
#3179, #3242, #3245
* Build System: Fix activation of snmp_agent. Thanks to Fabrice
Fontaine. #3241
* Build System: Fix bug that leads to CPPFLAGS gets overridden with
CFLAGS when libxmms is enabled. Thanks to Dagobert Michelsen. #3207
* perl module: Collectd::Plugins::Openvz: Fix indentation of some
closing curlies. Thanks to Christian Bartolomäus. #3239
* tree-wide: Fix a few issues found with LGTM. Thanks to Ruben Kerkhof.
#3252
* tree-wide: fix ssnprintf wrapper. Thanks to Fabien Wernli.
#3237, #3232, #3235, #3236
* tree-wide: Fix make check. Thanks to Ruben Kerkhof. #3306
* CI System: Travis: switch to Bionic. Thanks to Ruben Kerkhof. #3307
* CI System: Travis improvements for MacOS. Thanks to Ruben Kerkhof.
#3308
* MySQL plugin: Minor documentation improvements. Thanks to Christian
Bartolomäus. #3288
* Java plugin: Fix typo in an error message. Thanks to Matthias Runge.
#3285, #3286
* sysevent plugin: Add a few missing calloc result checks in the
sysevent_init function. Thanks to Andrew Bays. #3282
* ZFS ARC plugin: A bug that caused the first to values to be skipped
was fixed. Thanks to Jan-Philipp Litza. #3246
* SysLog plugin: restore previous behaviour: fallback to info for
unsupported level. Thanks to Fabien Wernli. #3236, #3238
* virt plugin: Fix memory leak with libvirt MetadataXPath enabled.
Thanks to Pavel Rochnyak. #3225, #3228
* GPU NVidia plugin: Fix build of the plugin. Thanks to Ruben Kerkhof.
#3320
2019-10-01, Version 5.9.2
* syslog plugin: Don't fail if syslog loglevel doesn't match. Thanks to
Fabien Wernli. #3236 #3238
* collectd: Fix ssnprintf wrapper. Thanks to Fabien Wernli. #3237
* rdt plugin: Fix compile time issues. Thanks to Matthias Runge. #3245
2019-07-24, Version 5.9.1
* collectd: redhat spec: fix build due to new upstream plugins. Thanks
to Fabien Wernli. #3175
* collectd: regex match: Fix unexpected match with empty meta data .
Thanks to Takuro Ashie. #3178
* collectd: Fix return value or loglevel for several plugins. Thanks to
Fabien Wernli. #3182
* collectd: Add standard include early or _FILE_OFFSET_BITS will have
definition … . Thanks to Dagobert Michelsen. #3193
* collectd: Use GCC-specific flags only when compiling with GCC. Thanks
to Dagobert Michelsen. #3195
* Use test_utils_proc_pids only when compiling the plugin that uses it.
Thanks to Dagobert Michelsen. #3197
* DNS plugin: Do not use headers from glibc. Thanks to Pavel Rochnyak.
#3156, #3145
* collectd: Add missing definitions for libnetsnmpagent. Thanks to
Dagobert Michelsen. #3203
* collectd: Move Makefile rules for pid_test inside conditional for
code. Thanks to Dagobert Michelsen. #3206
* collectd: Recover setlocale() call in src/daemon/collectd.c do_init().
Thanks to Pavel Rochnyak. #3214, #3181
* collectd: Add snprintf wrapper for GCC 8.2/3. Thanks to zebity. #3153,
#2895, #3038
* collectd: Fix bug that leads to CPPFLAGS gets overridden with CFLAGS
when libxmms is enabled. Thanks to Dagobert Michelsen. #3207
* Write_Riemann plugin: Copy MetaData to Riemann events in
write_riemann. Thanks to Romain Tartière. #3158
* virt plugin: Fix memory leak with libvirt MetadataXPath enabled.
Thanks to Pavel Rochnyak. #3225, #3230
2019-06-13, Version 5.9.0
* Build System: configure.ac: option "--with-libxml2" has been added.
Thanks to Dimitrios Apostolou, Pavel Rochnyak. #2864
* Build System: configure.ac: run dpdk build tests only if pkgconfig
fails. Thanks to Luca Boccassi, Pavel Rochnyak. #3015
* Build System: The "df" plugin is now built when "getmntent_r()" is
available. Thanks to Florian Forster. #3095
* Build System: The ability to turn on collectd "debug" feature in RPMs
has been added. Thanks to dehotot. #2755
* collectd: A new "UNKNOWN" state as the initial state of metrics has
been added. Thanks to Luis Fernández Álvarez, Florian Forster. #2976
* collectd: Base port to Windows. Thanks to Sean Campbell. #2810
* collectd: Code ownership of five plugins has been handed out to folks
from Intel. Thanks to Florian Forster. #3053
* collectd: config parser: Improved error reporting on global options.
Thanks to Pavel Rochnyak. #2813
* collectd: daemon: make plugin_dispatch_multivalue() obey write queue
limits. Thanks to Adam Romanek. #2898
* collectd: Macros "STRERROR" and "STRERRNO" have been added. Thanks to
Florian Forster. #2519
* collectd: Plugin name field has been added to plugin context to
improve error reporting. Thanks to Pavel Rochnyak. #2821
* collectd-tg: Use "CLOCK_REALTIME" for collectd-tg times. Thanks to
Andrew Bays. #2837
* tree-wide: Don't initialize static pointers to NULL, use "bool" from
"stdbool.h" (instead of "_Bool"). Thanks to Ruben Kerkhof. #2771,
#2772
* tree-wide: Replace zu with "PRIsz" and llu with "PRIu64". Thanks to
Sean Campbell. #2512
* tree-wide: Use interval value from plugin context, do not set
"vl->interval" in plugins more. Thanks to Pavel Rochnyak. #2847
* tree-wide: Utilities and libraries have been moved to "src/utils/".
Thanks to Florian Forster. #2961
* AMPQ1 plugin: A new plugin to write to amqp1 protocol. Thanks to Andy
Smith. #2618
* Chrony plugin: Ignoring late responses has been added. Thanks to
Miroslav Lichvar, Pavel Rochnyak. #2896
* CPUFreq plugin: Read number of p-state transitions and time spent in
each p-state. Thanks to Sexton Rory. #2803
* cURL, cURL-XML plugins: Option "Interval" has been added. Thanks to
Pavel Rochnyak. #2847
* Disk plugin: Report number of in progress disk IO requests on FreeBSD.
Thanks to Nathan Huff. #2878
* Exec plugin: Dynamic allocation of grname buffer has been added.
Thanks to sreedi, Florian Forster. #2937
* GPU NVML plugin: New plugin to collect NVIDIA GPU stats. Thanks to
Evgeny Naumov. #2923
* gRPC plugin: The "VerifyPeer" option for servers has been added.
Thanks to Florian Forster. #2593
* Intel RDT plugin: Support for groups of PIDs has been added. Thanks to
Wojciech Andralojc, Mateusz Starzyk, Michal Aleksinski. #2891
* IPMI plugin: Config options "SELSensor" and "SELIgnoreSelected" have
been added. Thanks to Mariusz Szafranski. #2796
* Modbus plugin: Support for 64 bit vals has been added, support for
CDAB endian 32-bit modbus polls has been added. Thanks to Anthony
Vickers, PJ Bostley. #2670, #2660
* Modbus plugin: The "Scale" and "Shift" metrics have been added. Thanks
to cekstam. #2729
* Netlink plugin: Handle new counter from Linux kernel version 4.6+.
Thanks to Pavel Rochnyak. #2767
* Network plugin: Option "BindAddress" has been added. Thanks to Ofir
Hermesh. #2831
* Ping plugin: An "AddressFamily" configuration option has been added.
Thanks to 依云 lilydjwg. #2961
* OVS Stats plugin: Extended metrics "ovs-dpdk" have been added. Thanks
to Matteo Croce, Ryan McCabe. #3000
* OVS Stats plugin: Support of bond interface and a "InterfaceStats"
config option have been added. Thanks to Andrew Bays. #2880
* PCIe Errors plugin: New plugin to read "PCIe" errors. Thanks to Kamil
Wiatrowski. #2733
* Processes plugin: Support for Linux Delay Accounting has been added.
Thanks to Florian Forster. #2598
* Redis plugin: Keyspace "hitratio" metric has been added, metric
"operations_per_second" has been removed, an option for connecting via
UNIX socket has been added. Thanks to Pavel Rochnyak. #2838, #2845,
#2904
* RouterOS plugin: Support for temperature and voltage data has been
added, use MAC-address when Radio-name is missing. Thanks to Pavel
Rochnyak. #2851, #2854
* RRDCacheD plugin: Time resolution has been improved to microseconds.
Thanks to Brian T. O'Neill. #3065
* Sensors plugin: Checks for upper limit of "SENSORS_API_VERSION" have
been removed, support for libsensors older than 3.0.0 has been
dropped. Thanks to Pavel Rochnyak. #3013, #3014
* SNMP plugin: New options "PluginInstance", "TypeInstance",
"TypeInstanceOID", "PluginInstanceOID", "FilterOID", "FilterValues"
and "FilterIgnoreSelected" have been added. Thanks to Pavel Rochnyak.
#2817, #2819
* SNMP Agent plugin: Multiple key indexes to snmp table and other new
features have been added, refactoring, coverity scan issues have been
fixed. Thanks to Marcin Mozejko. #2702, #2844
* Swap plugin: Support for Linux 2.4 has been dropped. Thanks to Pavel
Rochnyak. #2979
* Turbostat plugin: Configuration option "RestoreAffinityPolicy" has
been added. Thanks to Pablo Llopis. #2627
* Turbostat plugin: New metrics "P-states", "Turboboost", "Platform
TDP", "Uncore bus ratio" have been added. Thanks to Sexton Rory. #2806
* Turbostat plugin: Support of reporting GPU power on SKL has been
added. Thanks to Gordon Kelly. #2605
* virt plugin: Allow read "Hostname" from libvirt metadata. Thanks to
Mehdi ABAAKOUK. #2807
* virt plugin: Block info statistics for disk devices have been added.
Thanks to Radoslaw Jablonski. #2874
* Wireless plugin: A "bitrate" metric has been added. Thanks to Florian
Forster. #2950
* Write Graphite, Write Kafka plugins: Support for Graphite 1.1+ tag has
been added. Thanks to Dan Cech. #2631
* Write Prometheus plugin: Option "Host" has been added. Thanks to Pavel
Rochnyak. #2969
* Write Stackdriver plugin: New plugin to write to Google Stackdriver
Monitoring. Thanks to Florian Forster. #2472
* Write Syslog plugin: "write_syslog" plugin writes values lists as
syslog messages. Thanks to Shirly Radco. #3019
* Build System: A warning that pkgdatadir and pkglibdir were previously
defined has been fixed, additional plugins have been enabled,
GNULIB_DIR has been added to LDFLAGS in configure.ac on Windows.
Thanks to Sean Campbell. #2907, #2885, #2882
* Build System: Including "utils/mount/mount.h" has been fixed. Thanks
to Florian Forster. #3097
* Build System: The amount of output from ./configure has been reduced,
rendering of collectd-lua(5) manpage has been fixed, don't hide errors
when creating manpage. Thanks to Ruben Kerkhof. #3086, #3088, #3092
* collectd: A bug in "c_avl_iterator_prev" has been fixed. Thanks to
volth. #2917
* collectd: A stringop compiler warning has been fixed. Thanks to Ruben
Kerkhof, Juan Osorio Robles. #3021
* collectd: An invalid memory access in the "strjoin()" function has
been fixed. Thanks to Florian Forster. #3063
* collectd: collectd binary has been refactored. Thanks to Sean
Campbell, Sebastian Harl. #2745
* collectd: collectdmon cannot exit command line options parse loop has
been fixed. Thanks to takahashi-tsc. #2774
* collectd: Endianness checks for AIX have been added, gcc issue on Mac
byteorder has been fixed, fallback for endianness conversion has been
added. Thanks to Dagobert Michelsen. #2761, #2741, #2717
* collectd: Handle failure of simple config callbacks. Thanks to Ruben
Kerkhof. #3085
* collectd: Include "kstat.h" if available to provide "kstat_ctl_t",
include "kstat.h" when available. Thanks to Dagobert Michelsen. #2716,
#2711
* collectd: Parsing option for avoiding making BaseDir has been fixed.
Thanks to Mariusz Białończyk. #2856
* collectd: Remove empty "cmd_listval_t" data structure and related
no-op code. Thanks to Pavel Rochnyak. #2779
* collectd: src/daemon/plugin.c: Refactor plugin_load_file(),
src/utils_format_json.c: Remove chatty debug messages. Thanks to
Florian Forster. #2558, #2938
* collectd: Stop poisoning function in debug mode. Thanks to Ruben
Kerkhof. #2804
* collectd: The number of allocations when parsing types.db has been
reduced. Thanks to Ruben Kerkhof. #3091
* collectd: The organization of the source repository has been improved.
Thanks to Florian Forster. #2961
* collectd: Typos have been fixed. Thanks to Florian Forster, Jakub
Jankowski, William Pursell. #2944, #2692, #2643
* tree-wide: cleanup: cf_util_get* instead of local copy in plugins,
prefixed error reporting. Thanks to Pavel Rochnyak. #2833
* tree-wide: Some style issues have been fixed. Thanks to Ruben Kerkhof.
#3022
* tree-wide: "sstrerror()" has been replaced with "STRERRNO". Thanks to
Pavel Rochnyak. #2735
* AMQP1 plugin: Potential memory leaks found via scan-build have been
fixed, a typo in error log message has been fixed, cleanups. Thanks to
Andy Smith, Andrew Bays, Ruben Kerkhof. #2802, #2876, #2797
* Barometer plugin: Support to "libi2c-4.0" has been added. Thanks to
Pavel Rochnyak. #2783
* DBI, Oracle, PostgreSQL plugins: Fixes and improvements. Thanks to
Pavel Rochnyak. #1705
* Disk plugin: "HAVE_UDEV_H" has been changed to "HAVE_LIBUDEV_H".
Thanks to Dylan Stephano-Shachter. #2668
* Disk plugin: In linux, reset the disk when it disappears from
"/proc/diskstats". Thanks to Nikita Kozlov, Pavel Rochnyak. #2551
* DPDK Events, DPDK Stats plugins: Buffer size for parsing lcores has
been increased, a deprecation warning has been fixed, runtime config
file path has been fixed. Thanks to Kevin Laatz. #2722, #2840, #2924
* DPDK Stats plugin: A compilation issue has been fixed. Thanks to
Volodymyr Mytnyk. #2524
* GPS plugin: Build with gpsd version 3.18 has been fixed. Thanks to
Baruch Siach. #2947
* Intel RDT plugin: Compiler warnings have been fixed. Thanks to Ruben
Kerkhof. #3104
* Log Logstash plugin: Non-portable struct initialization with "{}" has
been fixed. Thanks to Florian Forster. #2988
* LUA plugin: A memory leak has been fixed. Thanks to Ruben Kerkhof.
#3090
* MySQL plugin: Properly cleanup dropped MySQL connections. Thanks to
Dhrupad Bhardwaj. #2704
* Netlink plugin: Truncation warnings have been fixed. Thanks to Ruben
Kerkhof. #2777
* NFS plugin: Message "Unexpected number of fields for NFSv4 server
statistics: 62" has been fixed. Thanks to Yedidyah Bar David. #2076
* NFS plugin: Number of fields for "NFSv4" has been fixed. Thanks to
Jan-Philipp Litza. #2915
* Notify Email plugin: All notification parameters have been included
into email. Thanks to Pavel Rochnyak. #2834
* NTPd plugin: Don't treat normal peers as refclocks, skip "0.0.0.0"
hosts in ntpd plugin. Thanks to Pavel Rochnyak, Ivan Kurnosov. #2822,
#2376
* OAuth plugin: src/utils_oauth.c: Renew OAuth tokens 30 seconds before
they expire. Thanks to Florian Forster. #2970
* OVS Stats plugin: A macro to populate counters list has been added,
value of "OpenFlow" has been corrected. Thanks to Matteo Croce. #2966,
#2963
* OVS Stats plugin: Code style, cleanup and improvements. Thanks to
Pavel Rochnyak. #3011, #3012
* OVS Stats, OVS Events plugins: utils_ovs: Avoid potential access of
freed memory, fixes. Thanks to Ciara Loftus, Mark Kavanagh. #2801,
#2731
* Processes plugin: Compilation has been fixed when ps_delay() is not
used. Thanks to Pavel Rochnyak. #2610
* Python plugin: A compilation warning with Python 3.7 has been fixed.
Thanks to Manoj Srivastava. #3042
* Redis plugin: Bugfixes, extended error reporting, persistent
connections and parallel polling, ability to select db for queries has
been fixed. Thanks to Pavel Rochnyak, skob. #2826, #2789
* Router OS plugin: Unset radio-name showing up as "(null)" has been
fixed. Thanks to melak. #2740
* RRDCacheD plugin: Cleanup rrdcached plugin a bit. Thanks to Pavel
Rochnyak. #3080
* RRDTool plugin: Error reporting has been extended. Thanks to Pavel
Rochnyak. #2825
* Sensors plugin: Support for humidity sensors has been added. Thanks to
Sarah Fischmann. #2913
* Sensu, OVS Stat, Turbostat, virt, OAuth, Write Prometheus, Intel RDT
plugins: Compiler warnings have been fixed. Thanks to Ruben Kerkhof.
#3093, #3098, #3099, #3100, #3102, #3103, #3104
* virt plugin: Code "do {} while(0)" around macro has been removed.
Thanks to Florian Forster. #2579
* virt plugin: Compiler warnings, a segfault in libvirt, typo in error
messages have been fixed. Thanks to Antoine Naud, Ruben Kerkhof, sarah
niuxu18. #2808, #2919, #2957
* virt plugin: Optional "virDomainGetCPUStats()" has been removed from
main flow, cleanup. Thanks to Pavel Rochnyak. #2972, #2978
* virt plugin: Tracking of VM state changes has been fixed. Thanks to
Radoslaw Jablonski. #2701
* Write MongoDB plugin: Plugin dependencies have been fixed. Thanks to
Pavel Rochnyak. #3010
* Write Prometheus plugin: A compilation issue on Mac OS X has been
fixed. Thanks to Florian Forster. #3059
* Write Redis plugin: Bug ""max_set_duration" deletes unexpected data"
has been fixed. Thanks to takahashi-tsc. #2773
* Write Stackdriver plugin: Potential NULL dereference and error
reporting have been fixed. Thanks to Florian Forster. #2960
* collectd.conf(5): a typo has been fixed, the tail plugin's
documentation has been improved. Thanks to Ruben Kerkhof, Florian
Forster. #3087, #2994
* collectd.conf.pod: virt: "Instances" option has been documented, a
clarifying example has been added. Thanks to Pavel Rochnyak, Fabien
Wernli. #2990, #2903
* collectd-python: "Import" configuration option has been documented.
Thanks to Tyler Harper. #2985
* collectd-snmp.pod: Document thread usage correctly. Thanks to Nathan
Ward. #3078
* CONTRIBUTING.md: Improve wording around ChangeLog; fix example,
document the new change log requirement / behavior. Thanks to Florian
Forster. #3061, #3054
* docs/review_comments.md: document with frequent review comments has
been started. Thanks to Florian Forster. #2964
* README: Include compiler defenses suggestion, do not point users to
non-existing file. Thanks to Kevin Laatz, Ruben Kerkhof. #2721, #2045
2018-10-23, Version 5.8.1
* collectd: Fix "BaseDir" option. Thanks to Mariusz Białończyk and
Pavel Rochnyak. #2857
* collectd: improve error handling, check return values. Thanks to
Florian Forster.
* Build System: use "kstat.h", when available. Thanks to Dagobert
Michelsen and Pavel Rochnyak. #2784
* Build System: Fix distcheck on MacOS. Thanks to Ruben Kerkhof.
* Build System: add missing include of ""collectd.h"" to fix builds on
Solaris. Thanks to Pavel Rochnyak.
* Build System: add endianess checks for AIX, fix GCC issue on Mac
byteorder, fix byteorder on Solaris, add fallback for endianess
conversion. Thanks to Dagobert Michelsen (multiple cherry picks from
master).
* Build System: Out-of-tree builds have been fixed. Thanks to Florian
Forster. #2602
* Configuration: Error handling in the config parsing code has been
improved. Thanks to Florian Forster.
* Documentation: Fix typo in collectd.conf(5). Thanks to Pavel Rochnyak.
#2760
* Documentation: update note on dpdkstat. Thanks to Maryam Tahhan. #2613
* Various plugins: Errors found by the static code analysis tool
Coverity were fixed. Thanks to Florian Forster. #2559, #2560, #2561,
#2562, #2563, #2565, #2568, #2575, #2579, #2580, #2588, #2589
* Ceph plugin: A segfault has been fixed. Thanks to Aleksei Zakharov and
Matthias Runge. #2572
* DF plugin: fix memory leak in error case. Thanks to Takahashi tsc.
* Exec plugin: check return value of "plugin_thread_create()". Thanks to
Florian Forster.
* Exec plugin: Handling of large groups has been fixed. Thanks to
Sridhar Mallem. #2696
* Exec plugin: Incorrect use of *putenv(3)* has been fixed. Thanks to
Daniel Vrátil.
* Exec plugin: A deadlock related to setting environment variables after
*fork()* has been fixed. Thanks to Daniel Vrátil.
* Intel PMU plugin: add core groups feature. Thanks to Kamil Wiatrowski.
#2681
* Intel PMU plugin: fix compatibility issue with collectd 5.8. Thanks to
Kamil Wiatrowski.
* Intel PMU plugin: fix possible "NULL" pointer dereference. Thanks to
Kamil Wiatrowski. #2676
* IPMI plugin: A segfault caused by a wrong data type has been fixed.
Thanks to Mariusz Szafrański. #2742
* IPMI plugin: The sensor configuration option has been fixed. Thanks to
Pavel Rochnyak. #2629
* memcached plugin: A deadlock situation has been fixed. Thanks to Pavel
Rochnyak. #2612
* NFS plugin: Support for NFSv4 has been fixed. Thanks to Jan-Philipp
Litza. #2076
* NTPd plugin: A memory leak in the error handling path has been fixed.
Thanks to Ruben Kerkhof. #2942
* OVS Stats plugin: A deadlock situation has been fixed. Thanks to
Volodymyr Mytnyk. #2590
* OVS Stats plugin: Fix reconnect after thread terminated. Thanks to
Volodymyr Mytnyk and Maram Tahhan. #2574
* Perl plugin: A compilation failure has been fixed. Thanks to Pavel
Rochnyak. #2732
* Perl plugin: Fix exporting notification meta data. Thanks to Florian
Forster.
* RRDtool plugin: Handling of very large "GAUGE" metrics has been fixed.
Thanks to Miroslav Lichvar. #2566
* Tail plugin: Several regressions have been fixed. Thanks to Pavel
Rochnyak. #2535, #2587, #2611
* turbostat plugin: A potential segfault due to an incorrect *free()*
has been fixed. Thanks to Ruben Kerkhof. #2948
* UUID plugin: Fix hostname setting. Thanks to Pavel Rochnyak. #2723
* virt plugin: A segfault during error handling has been fixed. Thanks
to Ruben Kerkhof. {{Issue|2919]}
* Write Kafka plugin: A build failure due to a deprecated API call has
been fixed. Thanks to Pavel Rochnyak. #2607, #2628, #2640
* Write Prometheus plugin: Fix "MHD_USE_INTERNAL_POLLING_THREAD" flag in
newer libmicrohttpd. Thanks to Pavel Rochnyak. #2849
* Write Prometheus plugin: set "SO_REUSEADDRESS" on listening socket.
Thanks to Pavel Rochnyak. #2570, #2673
* Write Syslog plugin: The new "write_syslog" plugin writes value
lists as syslog messages. Thanks to Shirly Radco. #3019
To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=24f60eb964837cf37a90dbf1d61509e7a4115a76
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
diffstat:
collectd-yajl/DESCR | 2 +-
collectd-yajl/Makefile | 2 +-
collectd/Makefile | 4 +-
collectd/Makefile.common | 12 +--
collectd/PLIST | 4 +
collectd/distinfo | 42 +++++-----
collectd/patches/patch-Makefile.am | 51 +++---------
collectd/patches/patch-configure.ac | 58 +++++--------
collectd/patches/patch-src_bind.c | 4 +-
collectd/patches/patch-src_collectd.conf.in | 19 ++---
collectd/patches/patch-src_cpu.c | 26 ++++--
collectd/patches/patch-src_df.c | 8 +-
collectd/patches/patch-src_entropy.c | 6 +-
collectd/patches/patch-src_irq.c | 16 ++--
.../patch-src_libcollectclient_network__buffer.c | 8 +-
collectd/patches/patch-src_memory.c | 74 ++++++-----------
collectd/patches/patch-src_netstat__udp.c | 2 +-
collectd/patches/patch-src_nfs.c | 94 ++++++----------------
collectd/patches/patch-src_processes.c | 23 +++---
collectd/patches/patch-src_swap.c | 26 +++---
collectd/patches/patch-src_tcpconns.c | 8 +-
collectd/patches/patch-src_utils_dns_dns.c | 6 +-
...h-src_utils_format__kairosdb_format__kairosdb.c | 4 +-
23 files changed, 195 insertions(+), 304 deletions(-)
diffs:
diff --git a/collectd-yajl/DESCR b/collectd-yajl/DESCR
index 08313713ae..862021d530 100644
--- a/collectd-yajl/DESCR
+++ b/collectd-yajl/DESCR
@@ -1,2 +1,2 @@
-YAJL-based plugins for collectd (ceph, log_logstash).
+YAJL-based plugins for collectd (ceph, log_logstash, sysevent).
Plugins that also depend on CURL are in the collectd-curl package.
diff --git a/collectd-yajl/Makefile b/collectd-yajl/Makefile
index cb86adfbc7..7742b0247e 100644
--- a/collectd-yajl/Makefile
+++ b/collectd-yajl/Makefile
@@ -1,7 +1,7 @@
# $NetBSD: Makefile,v $
COLLECTD_PACKAGE= yajl
-COLLECTD_PLUGINS= ceph log_logstash
+COLLECTD_PLUGINS= ceph log_logstash sysevent
COMMENT= Statistics collection daemon - YAJL-based plugins
diff --git a/collectd/Makefile b/collectd/Makefile
index 9ecdf2c777..650b41755c 100644
--- a/collectd/Makefile
+++ b/collectd/Makefile
@@ -2,8 +2,6 @@
.include "../../wip/collectd/Makefile.common"
-PKGREVISION= 4
-
COMMENT= Statistics collection daemon base
RCD_SCRIPTS= collectd
@@ -19,7 +17,7 @@ DEFAULT_PLUGINS+= aggregation apcups csv email exec filecount \
target_scale target_set target_v5upgrade \
teamspeak2 threshold unixsock uuid write_graphite
-DEFAULT_PLUGINS+= chrony memcached notify_nagios write_log write_sensu write_tsdb zookeeper
+DEFAULT_PLUGINS+= check_uptime chrony logparser memcached notify_nagios write_influxdb_udp write_log write_sensu write_syslog write_tsdb zookeeper
.for option in ${DEFAULT_PLUGINS}
CONFIGURE_ARGS+= --enable-${option}
diff --git a/collectd/Makefile.common b/collectd/Makefile.common
index c3ff20766a..4e8144ff14 100644
--- a/collectd/Makefile.common
+++ b/collectd/Makefile.common
@@ -34,7 +34,7 @@
# used by wip/p5-collectd/Makefile
# used by wip/py-collectd/Makefile
-DISTNAME= collectd-5.8.0
+DISTNAME= collectd-5.11.0
MASTER_SITES= http://collectd.org/files/
CATEGORIES= sysutils
EXTRACT_SUFX= .tar.bz2
@@ -73,14 +73,14 @@ BUILD_DEFS+= VARBASE
# special case for grpc++ below
COLLECTD_LIBS= aquaero5 hiredis curl dbi esmtp ganglia gcrypt \
- iptc lvm2app memcached mnl modbus mongoc mysql \
- netsnmp oping owcapi pcap perl pq python \
+ iptc memcached mnl modbus mongoc mysql \
+ netsnmp oping owcapi pcap perl pq python \
rabbitmq routeros rrd sensors statgrab \
tokyotyrant upsclient varnish xmms yajl
-COLLECTD_LIBS+= atasmart dpdk gps iptc jevents ldap microhttpd mosquitto netapp netsnmpagent pqos protobuf protobuf-c rdkafka udev xenctrl
+COLLECTD_LIBS+= atasmart dpdk gps iptc jansson jevents ldap microhttpd mosquitto netapp netsnmpagent pqos protobuf protobuf-c qpid-proton rdkafka ssl slurm udev xenctrl
-CONFIGURE_ARGS+= --with-java=no --with-mic=no --with-oracle=no \
- --with-perl-bindings=no \
+CONFIGURE_ARGS+= --with-cuda=no --with-java=no --with-mic=no --with-oracle=no \
+ --with-perl-bindings=no \
--disable-all-plugins
.for lib in ${COLLECTD_LIBS}
diff --git a/collectd/PLIST b/collectd/PLIST
index 304a335b6d..fc45e33e37 100644
--- a/collectd/PLIST
+++ b/collectd/PLIST
@@ -13,6 +13,7 @@ lib/collectd/aggregation.la
lib/collectd/apcups.la
${PLIST.apple-sensors}lib/collectd/apple_sensors.la
${PLIST.battery}lib/collectd/battery.la
+lib/collectd/check_uptime.la
lib/collectd/chrony.la
${PLIST.contextswitch}lib/collectd/contextswitch.la
${PLIST.cpu}lib/collectd/cpu.la
@@ -28,6 +29,7 @@ ${PLIST.interface}lib/collectd/interface.la
${PLIST.irq}lib/collectd/irq.la
${PLIST.load}lib/collectd/load.la
lib/collectd/logfile.la
+lib/collectd/logparser.la
lib/collectd/match_empty_counter.la
lib/collectd/match_hashed.la
lib/collectd/match_regex.la
@@ -66,8 +68,10 @@ ${PLIST.uptime}lib/collectd/uptime.la
${PLIST.users}lib/collectd/users.la
lib/collectd/uuid.la
lib/collectd/write_graphite.la
+lib/collectd/write_influxdb_udp.la
lib/collectd/write_log.la
lib/collectd/write_sensu.la
+lib/collectd/write_syslog.la
lib/collectd/write_tsdb.la
${PLIST.zfs-arc}lib/collectd/zfs_arc.la
${PLIST.zone}lib/collectd/zone.la
diff --git a/collectd/distinfo b/collectd/distinfo
index c816a0b90f..aa51d74a0d 100644
--- a/collectd/distinfo
+++ b/collectd/distinfo
@@ -1,29 +1,29 @@
$NetBSD: distinfo,v 1.45 2020/07/05 13:57:32 he Exp $
-SHA1 (collectd-5.8.0.tar.bz2) = eb3567563de471e1950b7388e8883b911be3756a
-RMD160 (collectd-5.8.0.tar.bz2) = 7b812b1046d57a9047213bb182b8744d98606547
-SHA512 (collectd-5.8.0.tar.bz2) = 1b3d0cc44e2ca54e13eebf292074f1efa8b33d6800d04405e0eaaa2dd1cb2416c6eae580729fb5aead23a5039f41ffe8a9989a907a8c18be8f867f1099fc0008
-Size (collectd-5.8.0.tar.bz2) = 1686017 bytes
-SHA1 (patch-Makefile.am) = 110cce600c66226bb02291349e76433555418edd
-SHA1 (patch-configure.ac) = 91e2d0d6b0f9b592c52dfd2d0a02850416f04e93
-SHA1 (patch-src_bind.c) = 4aa7742c8e24ee6bd7293abc56fc95a605d0a2c7
-SHA1 (patch-src_collectd.conf.in) = f0b35085cf0ddfd766e140b145177ab1f1326f5f
-SHA1 (patch-src_cpu.c) = e645ae6b05c051c3c878f88a493fbbd7d548bb66
+SHA1 (collectd-5.11.0.tar.bz2) = 18bfb0be0493ed4a1b5d73c8bcc3f28d37652480
+RMD160 (collectd-5.11.0.tar.bz2) = 12ac883a22828d0c181459fe95f4701bf74b4407
+SHA512 (collectd-5.11.0.tar.bz2) = 87671545e3d01770c204ba4439265d1c0add6a105bf04ff02dc04db3731fd933d32ecb9b0dc15f2e504d70c3e421a64cf19728c897aa4fb1fda86e393ffc15bf
+Size (collectd-5.11.0.tar.bz2) = 1851663 bytes
+SHA1 (patch-Makefile.am) = 2762640d219125e0aa85d3c5c5354af5e659b257
+SHA1 (patch-configure.ac) = 77874524ded19078356a303b984c19bc85a86647
+SHA1 (patch-src_bind.c) = ee9f6c5e7828010b4beecff4b2d3d8ff2aebc7ac
+SHA1 (patch-src_collectd.conf.in) = ee885263d5dca87857c8d56069952db0d4ffef37
+SHA1 (patch-src_cpu.c) = 099f04b0a156ae78f5f5809d6db639534d4556a1
SHA1 (patch-src_daemon_collectd.c) = 155da2fde889e961719fe6be47aa7fc25199fbe7
SHA1 (patch-src_daemon_common.h) = d1ef6a5257156a864bf896629870f0f83a858cff
-SHA1 (patch-src_df.c) = 5c6549cd9ec72efed5cdb7d8dd9297c50491426e
+SHA1 (patch-src_df.c) = de699d221b003b70c22308cf43f4d61daa4071f7
SHA1 (patch-src_disk.c) = a9e71366f75fcc760384d41651771738ec28823f
-SHA1 (patch-src_entropy.c) = f20ad4ce2e968ba0b20bb13aa00771fc424562fd
-SHA1 (patch-src_irq.c) = 18106e9051ec344b0d45a23814eae5ba3be2f908
-SHA1 (patch-src_libcollectclient_network__buffer.c) = a19e1658017279c35fd9860e2ab855081bad8327
+SHA1 (patch-src_entropy.c) = 77ddaf1df7ab898d3009f94bfcca82d16e22f9fe
+SHA1 (patch-src_irq.c) = 51f0e61a58b439f5e4e8de873e887700fc3dd67e
+SHA1 (patch-src_libcollectclient_network__buffer.c) = 541332bcffcbcbb2e398275f93e2aa1ae8861598
SHA1 (patch-src_lua.c) = 656934889976f489abb80a8244492f845a3bd9f8
-SHA1 (patch-src_memory.c) = 3276b09d0c09e0a9446519bd6c304d95c30b617a
-SHA1 (patch-src_netstat__udp.c) = 30cb12d25f56c60959658dbd181783212e00cc61
-SHA1 (patch-src_nfs.c) = 6a174b852a38c5a87dda932255dfe8ed95668fb4
-SHA1 (patch-src_processes.c) = a22b1e9d7935c7924b65c57990b4212990acc6b7
+SHA1 (patch-src_memory.c) = ddfa79d68ebbaeed3bf1f35acbadda111d0387af
+SHA1 (patch-src_netstat__udp.c) = 4763c9c26a5639a84d1ed306b40c5b761110f632
+SHA1 (patch-src_nfs.c) = a38e2b2096b0b7c1d52bba18dcbb78f3cdc264a9
+SHA1 (patch-src_processes.c) = c1e4a5e45c2f489067b83164381b569f270b1a4e
SHA1 (patch-src_read_kafka.c) = 05334bd0ea51ab386afce0cb3336378fcc42d997
SHA1 (patch-src_statsd.c) = 35f4349d2d2c9bddc0f4770344f969157cd012f6
-SHA1 (patch-src_swap.c) = 98984dc7c6eee4f17b2f291124431172b06aa6c2
-SHA1 (patch-src_tcpconns.c) = 0469ffe477ae96a79e4fd28c4428a1e7682e9461
-SHA1 (patch-src_utils__dns.c) = 68c34489f3c8dca4a57035df9a38076bf35f7c5f
-SHA1 (patch-src_utils__format__kairosdb.c) = 2f7bde47682d2b877f9bd2d2c794a21c297aa9e5
+SHA1 (patch-src_swap.c) = 4ef887e0eddf5c21c121c951f64262781f71e984
+SHA1 (patch-src_tcpconns.c) = dc6c1d361561f16623933b53ec127d88052236b2
+SHA1 (patch-src_utils_dns_dns.c) = aebb564540a51088fbd8ed56c031e7e0acc1b2e3
+SHA1 (patch-src_utils_format__kairosdb_format__kairosdb.c) = 9d6a1567645a5beafb22e3704866b0fcaa6b6c35
diff --git a/collectd/patches/patch-Makefile.am b/collectd/patches/patch-Makefile.am
index d2a2f20c77..412cb721eb 100644
--- a/collectd/patches/patch-Makefile.am
+++ b/collectd/patches/patch-Makefile.am
@@ -1,20 +1,19 @@
$NetBSD: patch-Makefile.am,v 1.3 2018/01/04 15:42:42 jperkin Exp $
-Use other data directory, correct $< in explicit rule
-(https://github.com/collectd/collectd/issues/3313).
+Use other data directory.
---- Makefile.am.orig 2017-11-18 10:03:27.000000000 +0100
-+++ Makefile.am 2019-10-08 16:53:17.694282904 +0200
-@@ -165,7 +165,7 @@
- -DPREFIX='"${prefix}"' \
- -DCONFIGFILE='"${sysconfdir}/${PACKAGE_NAME}.conf"' \
- -DLOCALSTATEDIR='"${localstatedir}"' \
-- -DPKGLOCALSTATEDIR='"${localstatedir}/lib/${PACKAGE_NAME}"' \
-+ -DPKGLOCALSTATEDIR='"${localstatedir}/db/${PACKAGE_NAME}"' \
- -DPLUGINDIR='"${pkglibdir}"' \
- -DPKGDATADIR='"${pkgdatadir}"'
+--- Makefile.am.orig 2020-03-08 16:57:09.000000000 +0100
++++ Makefile.am 2020-07-06 19:13:59.289684798 +0200
+@@ -8,7 +8,7 @@
+ else
+ cpkgdatadir=$(pkgdatadir)
+ cpkglibdir=$(pkglibdir)
+-cpkglocalstatedir=${localstatedir}/lib/${PACKAGE_NAME}
++cpkglocalstatedir=${localstatedir}/db/${PACKAGE_NAME}
+ endif
-@@ -1205,6 +1205,12 @@
+ BUILT_SOURCES = \
+@@ -1478,6 +1478,12 @@
netlink_la_LIBADD = $(BUILD_WITH_LIBMNL_LIBS)
endif
@@ -27,7 +26,7 @@ Use other data directory, correct $< in explicit rule
if BUILD_PLUGIN_NETWORK
pkglib_LTLIBRARIES += network.la
network_la_SOURCES = \
-@@ -1942,6 +1948,8 @@
+@@ -2352,6 +2358,8 @@
if BUILD_PLUGIN_WRITE_PROMETHEUS
BUILT_SOURCES += prometheus.pb-c.c prometheus.pb-c.h
@@ -36,27 +35,3 @@ Use other data directory, correct $< in explicit rule
prometheus.pb-c.c prometheus.pb-c.h: $(srcdir)/proto/prometheus.proto
$(AM_V_PROTOC_C)$(PROTOC_C) -I$(srcdir)/proto --c_out=$(builddir) $(srcdir)/proto/prometheus.proto
endif
-@@ -1952,19 +1960,19 @@
-
- collectd.grpc.pb.cc: $(srcdir)/proto/collectd.proto $(srcdir)/proto/types.proto
- $(V_PROTOC)$(PROTOC) -I$(srcdir)/proto \
-- --grpc_out=$(builddir) --plugin=protoc-gen-grpc=$(GRPC_CPP_PLUGIN) $<
-+ --grpc_out=$(builddir) --plugin=protoc-gen-grpc=$(GRPC_CPP_PLUGIN) $>
-
- collectd.pb.cc: $(srcdir)/proto/collectd.proto $(srcdir)/proto/types.proto
-- $(V_PROTOC)$(PROTOC) -I$(srcdir)/proto --cpp_out=$(builddir) $<
-+ $(V_PROTOC)$(PROTOC) -I$(srcdir)/proto --cpp_out=$(builddir) $>
-
- types.pb.cc: $(srcdir)/proto/types.proto
-- $(V_PROTOC)$(PROTOC) -I$(srcdir)/proto --cpp_out=$(builddir) $<
-+ $(V_PROTOC)$(PROTOC) -I$(srcdir)/proto --cpp_out=$(builddir) $>
- endif
- endif
-
- install-exec-hook:
- $(mkinstalldirs) $(DESTDIR)$(localstatedir)/run
-- $(mkinstalldirs) $(DESTDIR)$(localstatedir)/lib/$(PACKAGE_NAME)
-+ $(mkinstalldirs) $(DESTDIR)$(localstatedir)/db/$(PACKAGE_NAME)
- $(mkinstalldirs) $(DESTDIR)$(localstatedir)/log
- $(mkinstalldirs) $(DESTDIR)$(sysconfdir)
- if test -e $(DESTDIR)$(sysconfdir)/collectd.conf; \
diff --git a/collectd/patches/patch-configure.ac b/collectd/patches/patch-configure.ac
index 3c6484039c..bc297bb8c1 100644
--- a/collectd/patches/patch-configure.ac
+++ b/collectd/patches/patch-configure.ac
@@ -1,40 +1,20 @@
-$NetBSD: patch-configure.ac,v 1.12 2020/03/19 06:26:26 rillig Exp $
+$NetBSD: patch-configure.ac,v 1.11 2017/11/21 15:18:23 fhajny Exp $
-Add KERNEL_NETBSD, add entry and disk, nfs plugins for NetBSD,
+Add KERNEL_NETBSD, add entry and netstat_udp plugin definition,
and also do swap for "have_swapctl_three_args" (as for NetBSD).
Also, the start of process support, but that's not yet finished.
-Correct tokyotyrant detection (add lib, not include, for -L).
-Correct libupsclient detection (argument may be a searchable directory).
---- configure.ac.orig 2017-11-18 09:03:27.330751467 +0000
-+++ configure.ac
-@@ -110,6 +110,7 @@
+--- configure.ac.orig 2020-03-19 09:52:56.000000000 +0100
++++ configure.ac 2020-07-06 19:24:03.404718013 +0200
+@@ -114,6 +114,7 @@
AM_CONDITIONAL([BUILD_FREEBSD], [test "x$ac_system" = "xFreeBSD"])
AM_CONDITIONAL([BUILD_LINUX], [test "x$ac_system" = "xLinux"])
AM_CONDITIONAL([BUILD_OPENBSD], [test "x$ac_system" = "xOpenBSD"])
+AM_CONDITIONAL([BUILD_NETBSD], [test "x$ac_system" = "xNetBSD"])
AM_CONDITIONAL([BUILD_SOLARIS], [test "x$ac_system" = "xSolaris"])
+ AM_CONDITIONAL([BUILD_WIN32], [test "x$ac_system" = "xWindows"])
- if test "x$ac_system" = "xSolaris"; then
-@@ -5209,7 +5210,7 @@
- with_libtokyotyrant="$withval"
- else
- with_libtokyotyrant_cppflags="-I$withval/include"
-- with_libtokyotyrant_ldflags="-L$withval/include"
-+ with_libtokyotyrant_ldflags="-L$withval/lib"
- with_libtokyotyrant_libs="-ltokyotyrant"
- with_libtokyotyrant="yes"
- fi
-@@ -5328,7 +5329,7 @@
- else if test "x$withval" = "xyes"; then
- with_libupsclient="use_pkgconfig"
- else
-- if test -x "$withval"; then
-+ if test -f "$withval" && test -x "$withval"; then
- with_libupsclient_config="$withval"
- with_libupsclient="use_libupsclient_config"
- else if test -x "$withval/bin/libupsclient-config"; then
-@@ -6136,6 +6137,7 @@
+@@ -6595,6 +6596,7 @@
plugin_mcelog="no"
plugin_memory="no"
plugin_multimeter="no"
@@ -42,25 +22,23 @@ Correct libupsclient detection (argument may be a searchable directory).
plugin_nfs="no"
plugin_numa="no"
plugin_ovs_events="no"
-@@ -6228,7 +6230,9 @@
- plugin_disk="yes"
- plugin_entropy="yes"
+@@ -6708,6 +6710,7 @@
plugin_irq="yes"
-+ plugin_nfs="yes"
+ plugin_nfs="yes"
plugin_processes="yes"
+ plugin_netstat_udp="yes"
fi
# Mac OS X devices
-@@ -6568,6 +6572,7 @@
- AC_PLUGIN([mysql], [$with_libmysql], [MySQL statistics])
- AC_PLUGIN([netapp], [$with_libnetapp], [NetApp plugin])
- AC_PLUGIN([netlink], [$with_libmnl], [Enhanced Linux network statistics])
-+AC_PLUGIN([netstat_udp], [$plugin_netstat_udp], [UDP network statistics])
- AC_PLUGIN([network], [yes], [Network communication plugin])
- AC_PLUGIN([nfs], [$plugin_nfs], [NFS statistics])
- AC_PLUGIN([nginx], [$with_libcurl], [nginx statistics])
-@@ -6987,6 +6992,7 @@
+@@ -7077,6 +7080,7 @@
+ AC_PLUGIN([mysql], [$with_libmysql], [MySQL statistics])
+ AC_PLUGIN([netapp], [$with_libnetapp], [NetApp plugin])
+ AC_PLUGIN([netlink], [$with_libmnl], [Enhanced Linux network statistics])
++AC_PLUGIN([netstat_udp], [$plugin_netstat_udp], [UDP network statistics])
+ AC_PLUGIN([network], [yes], [Network communication plugin])
+ AC_PLUGIN([nfs], [$plugin_nfs], [NFS statistics])
+ AC_PLUGIN([nginx], [$with_libcurl], [nginx statistics])
+@@ -7521,6 +7525,7 @@
AC_MSG_RESULT([ mysql . . . . . . . . $enable_mysql])
AC_MSG_RESULT([ netapp . . . . . . . $enable_netapp])
AC_MSG_RESULT([ netlink . . . . . . . $enable_netlink])
diff --git a/collectd/patches/patch-src_bind.c b/collectd/patches/patch-src_bind.c
index 6edf2ae0dc..002c1130df 100644
--- a/collectd/patches/patch-src_bind.c
+++ b/collectd/patches/patch-src_bind.c
@@ -2,8 +2,8 @@ $NetBSD: patch-src_bind.c,v 1.1 2020/07/05 13:57:32 he Exp $
Also pick out the response time bins from the resolver stats.
---- src/bind.c.orig 2017-11-18 09:03:27.000000000 +0000
-+++ src/bind.c
+--- src/bind.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/bind.c 2020-07-20 12:55:28.000000000 +0200
@@ -228,7 +228,17 @@ static const translation_info_t resstats
{"ValAttempt", "dns_resolver", "DNSSEC-attempt"},
{"ValOk", "dns_resolver", "DNSSEC-okay"},
diff --git a/collectd/patches/patch-src_collectd.conf.in b/collectd/patches/patch-src_collectd.conf.in
index 8081b1e051..8165e17834 100644
--- a/collectd/patches/patch-src_collectd.conf.in
+++ b/collectd/patches/patch-src_collectd.conf.in
@@ -1,8 +1,9 @@
$NetBSD: patch-src_collectd.conf.in,v 1.2 2015/06/10 20:05:26 fhajny Exp $
Fix default dirs.
---- src/collectd.conf.in.orig 2015-05-20 12:05:42.672060002 +0000
-+++ src/collectd.conf.in
+
+--- src/collectd.conf.in.orig 2020-03-19 09:52:56.000000000 +0100
++++ src/collectd.conf.in 2020-07-06 19:18:19.842344185 +0200
@@ -12,7 +12,7 @@
#Hostname "localhost"
@@ -12,7 +13,7 @@ Fix default dirs.
#PIDFile "@localstatedir@/run/@PACKAGE_NAME@.pid"
#PluginDir "@libdir@/@PACKAGE_NAME@"
#TypesDB "@prefix@/share/@PACKAGE_NAME@/types.db"
-@@ -315,16 +315,16 @@
+@@ -389,16 +389,16 @@
# LongRunAvgLatency false
# ConvertSpecialMetricTypes true
# <Daemon "osd.0">
@@ -33,7 +34,7 @@ Fix default dirs.
# </Daemon>
#</Plugin>
-@@ -340,7 +340,7 @@
+@@ -427,7 +427,7 @@
#</Plugin>
#
#<Plugin csv>
@@ -42,7 +43,7 @@ Fix default dirs.
# StoreRates false
#</Plugin>
-@@ -683,7 +683,7 @@
+@@ -1029,7 +1029,7 @@
# <Database db_name2>
# Alias "squeeze"
# Host "localhost"
@@ -51,7 +52,7 @@ Fix default dirs.
# SlaveStats true
# SlaveNotifications true
# </Database>
-@@ -956,14 +956,14 @@
+@@ -1347,14 +1347,14 @@
# <Server "server_name">
# Collect "latency"
# Collect "udp-answers" "udp-queries"
@@ -69,7 +70,7 @@ Fix default dirs.
#</Plugin>
#<Plugin processes>
-@@ -1011,14 +1011,14 @@
+@@ -1466,14 +1466,14 @@
#<Plugin rrdcached>
# DaemonAddress "unix:/tmp/rrdcached.sock"
@@ -86,7 +87,7 @@ Fix default dirs.
# CreateFilesAsync false
# CacheTimeout 120
# CacheFlush 900
-@@ -1174,7 +1174,7 @@
+@@ -1711,7 +1711,7 @@
# Type "kpackets_wire_per_sec.realtime"
# ValueFrom 4
# </Metric>
@@ -95,7 +96,7 @@ Fix default dirs.
# Instance "snort-eth0"
# Interval 600
# Collect "dropped" "mbps" "alerts" "kpps"
-@@ -1231,7 +1231,7 @@
+@@ -1773,7 +1773,7 @@
#</Plugin>
#<Plugin unixsock>
diff --git a/collectd/patches/patch-src_cpu.c b/collectd/patches/patch-src_cpu.c
index 8773e6c735..09480b12a4 100644
--- a/collectd/patches/patch-src_cpu.c
+++ b/collectd/patches/patch-src_cpu.c
@@ -2,18 +2,28 @@ $NetBSD: patch-src_cpu.c,v 1.3 2016/12/07 17:28:39 fhajny Exp $
Port this too to NetBSD.
---- src/cpu.c.orig 2016-11-30 08:52:01.308911943 +0000
-+++ src/cpu.c
-@@ -81,7 +81,7 @@
+--- src/cpu.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/cpu.c 2020-07-07 12:08:28.927383000 +0200
+@@ -78,13 +78,16 @@
+ #endif
+ #endif /* HAVE_SYS_DKSTAT_H */
- #if HAVE_SYSCTL
+-#define CAN_USE_SYSCTL 0
+ #if (defined(HAVE_SYSCTL) && defined(HAVE_SYSCTLBYNAME)) || defined(__OpenBSD__)
+ /* Implies BSD variant */
#if defined(CTL_HW) && defined(HW_NCPU) && defined(CTL_KERN) && \
- defined(KERN_CPTIME) && defined(CPUSTATES)
+ (defined(KERN_CPTIME) || defined(KERN_CP_TIME)) && defined(CPUSTATES)
#define CAN_USE_SYSCTL 1
- #else
- #define CAN_USE_SYSCTL 0
-@@ -673,6 +673,24 @@ static int cpu_read(void) {
++#else
++#define CAN_USE_SYSCTL 0
+ #endif
++#else
++#define CAN_USE_SYSCTL 0
+ #endif /* HAVE_SYSCTL_H && HAVE_SYSCTLBYNAME || __OpenBSD__ */
+
+ #define COLLECTD_CPU_STATE_USER 0
+@@ -746,6 +749,24 @@ static int cpu_read(void) {
memset(cpuinfo, 0, sizeof(cpuinfo));
@@ -38,7 +48,7 @@ Port this too to NetBSD.
#if defined(KERN_CPTIME2)
if (numcpu > 1) {
for (int i = 0; i < numcpu; i++) {
-@@ -710,6 +728,7 @@ static int cpu_read(void) {
+@@ -779,6 +800,7 @@ static int cpu_read(void) {
cpuinfo[0][i] = cpuinfo_tmp[i];
}
}
diff --git a/collectd/patches/patch-src_df.c b/collectd/patches/patch-src_df.c
index d2dcc3c169..5ddabf9313 100644
--- a/collectd/patches/patch-src_df.c
+++ b/collectd/patches/patch-src_df.c
@@ -2,11 +2,11 @@ $NetBSD: patch-src_df.c,v 1.5 2016/12/07 17:28:39 fhajny Exp $
Older NetBSD doesn't have float_t.
---- src/df.c.orig 2016-11-30 08:52:01.312911569 +0000
-+++ src/df.c
+--- src/df.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/df.c 2020-07-06 19:28:15.661572605 +0200
@@ -28,6 +28,14 @@
- #include "utils_ignorelist.h"
- #include "utils_mount.h"
+ #include "utils/ignorelist/ignorelist.h"
+ #include "utils/mount/mount.h"
+#if defined(__NetBSD__)
+#include <sys/param.h>
diff --git a/collectd/patches/patch-src_entropy.c b/collectd/patches/patch-src_entropy.c
index 16106cfa95..5c31c8abcf 100644
--- a/collectd/patches/patch-src_entropy.c
+++ b/collectd/patches/patch-src_entropy.c
@@ -5,11 +5,11 @@ This version tries to keep /dev/urandom open (for repeated use),
instead of constantly re-opening/closing it, since the latter will
needlessly reduce the kernel's entropy estimate.
---- src/entropy.c.orig 2017-11-18 09:03:27.354750373 +0000
-+++ src/entropy.c
+--- src/entropy.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/entropy.c 2020-07-06 19:39:37.204772249 +0200
@@ -29,23 +29,16 @@
- #include "common.h"
#include "plugin.h"
+ #include "utils/common/common.h"
-#if !KERNEL_LINUX
+static void entropy_submit (value_t);
diff --git a/collectd/patches/patch-src_irq.c b/collectd/patches/patch-src_irq.c
index 79634a5d80..d56562975b 100644
--- a/collectd/patches/patch-src_irq.c
+++ b/collectd/patches/patch-src_irq.c
@@ -2,11 +2,11 @@ $NetBSD: patch-src_irq.c,v 1.5 2017/11/21 15:18:23 fhajny Exp $
Provide a port to NetBSD.
---- src/irq.c.orig 2017-11-18 09:03:27.354750373 +0000
-+++ src/irq.c
-@@ -27,10 +27,20 @@
- #include "plugin.h"
- #include "utils_ignorelist.h"
+--- src/irq.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/irq.c 2020-07-06 19:50:01.057574443 +0200
+@@ -27,10 +27,18 @@
+ #include "utils/common/common.h"
+ #include "utils/ignorelist/ignorelist.h"
-#if !KERNEL_LINUX
+#if !KERNEL_LINUX && !KERNEL_NETBSD
@@ -14,19 +14,17 @@ Provide a port to NetBSD.
#endif
+#if KERNEL_NETBSD
-+
+#include <sys/param.h>
+#include <sys/types.h>
+#include <sys/sysctl.h>
+#include <sys/evcnt.h>
+#include <malloc.h>
-+
+#endif /* KERNEL_NETBSD */
+
/*
* (Module-)Global variables
*/
-@@ -75,6 +85,7 @@ static void irq_submit(const char *irq_n
+@@ -75,6 +83,7 @@ static void irq_submit(const char *irq_n
plugin_dispatch_values(&vl);
} /* void irq_submit */
@@ -34,7 +32,7 @@ Provide a port to NetBSD.
static int irq_read(void) {
FILE *fh;
char buffer[1024];
-@@ -167,6 +178,64 @@ static int irq_read(void) {
+@@ -165,6 +174,64 @@ static int irq_read(void) {
return 0;
} /* int irq_read */
diff --git a/collectd/patches/patch-src_libcollectclient_network__buffer.c b/collectd/patches/patch-src_libcollectclient_network__buffer.c
index 92db7ddf01..3361dbbbf9 100644
--- a/collectd/patches/patch-src_libcollectclient_network__buffer.c
+++ b/collectd/patches/patch-src_libcollectclient_network__buffer.c
@@ -2,9 +2,9 @@ $NetBSD: patch-src_libcollectclient_network__buffer.c,v 1.4 2017/11/21 15:18:23
Need the workaround on at least SunOS too.
---- src/libcollectdclient/network_buffer.c.orig 2017-11-18 09:03:27.358750191 +0000
-+++ src/libcollectdclient/network_buffer.c
-@@ -36,7 +36,7 @@
+--- src/libcollectdclient/network_buffer.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/libcollectdclient/network_buffer.c 2020-07-06 19:48:22.130670698 +0200
+@@ -41,7 +41,7 @@
#include <pthread.h>
#if HAVE_GCRYPT_H
@@ -13,7 +13,7 @@ Need the workaround on at least SunOS too.
/* default xcode compiler throws warnings even when deprecated functionality
* is not used. -Werror breaks the build because of erroneous warnings.
* http://stackoverflow.com/questions/10556299/compiler-warnings-with-libgcrypt-v1-5-0/12830209#12830209
-@@ -49,7 +49,7 @@
+@@ -54,7 +54,7 @@
*/
#define GCRYPT_NO_DEPRECATED
#include <gcrypt.h>
diff --git a/collectd/patches/patch-src_memory.c b/collectd/patches/patch-src_memory.c
index 19397ca059..8effbeb83c 100644
--- a/collectd/patches/patch-src_memory.c
+++ b/collectd/patches/patch-src_memory.c
@@ -3,31 +3,22 @@ $NetBSD: patch-src_memory.c,v 1.5 2017/11/21 15:18:23 fhajny Exp $
Add a port for NetBSD using VM_UVMEXP2, and preferring
sysctl over sysctlbyname.
---- src/memory.c.orig 2017-11-18 09:03:27.358750191 +0000
-+++ src/memory.c
-@@ -66,6 +66,10 @@ static mach_port_t port_host;
- static vm_size_t pagesize;
+--- src/memory.c.orig 2020-06-19 21:12:44.000000000 +0200
++++ src/memory.c 2020-07-09 21:13:27.000000000 +0200
+@@ -69,7 +69,12 @@ static vm_size_t pagesize;
/* #endif HAVE_HOST_STATISTICS */
-+#elif HAVE_SYSCTL
-+static int pagesize;
-+/* #endif HAVE_SYSCTL */
-+
#elif HAVE_SYSCTLBYNAME
++#if HAVE_SYSCTL && defined(KERNEL_NETBSD)
++static int pagesize;
++#include <unistd.h> /* getpagesize() */
++#else
/* no global variables */
++#endif
/* #endif HAVE_SYSCTLBYNAME */
-@@ -80,10 +84,6 @@ static kstat_t *ksp;
- static kstat_t *ksz;
- /* #endif HAVE_LIBKSTAT */
--#elif HAVE_SYSCTL
--static int pagesize;
--/* #endif HAVE_SYSCTL */
--
- #elif HAVE_LIBSTATGRAB
- /* no global variables */
- /* endif HAVE_LIBSTATGRAB */
-@@ -94,6 +94,10 @@ static int pagesize;
+ #elif KERNEL_LINUX
+@@ -97,6 +102,10 @@ static int pagesize;
#error "No applicable input method."
#endif
@@ -35,41 +26,23 @@ sysctl over sysctlbyname.
+# include <uvm/uvm_extern.h>
+#endif
+
- static _Bool values_absolute = 1;
- static _Bool values_percentage = 0;
+ static bool values_absolute = true;
+ static bool values_percentage;
-@@ -120,6 +124,14 @@ static int memory_init(void) {
- host_page_size(port_host, &pagesize);
- /* #endif HAVE_HOST_STATISTICS */
+@@ -124,7 +133,11 @@ static int memory_init(void) {
+ /* #endif HAVE_HOST_STATISTICS */
-+#elif HAVE_SYSCTL
-+ pagesize = getpagesize();
-+ if (pagesize <= 0) {
-+ ERROR("memory plugin: Invalid pagesize: %i", pagesize);
-+ return (-1);
-+ }
-+/* #endif HAVE_SYSCTL */
-+
#elif HAVE_SYSCTLBYNAME
++#if HAVE_SYSCTL && defined(KERNEL_NETBSD)
++ pagesize = getpagesize();
++#else
/* no init stuff */
++#endif /* HAVE_SYSCTL && defied(KERNEL_NETBSD) */
/* #endif HAVE_SYSCTLBYNAME */
-@@ -142,14 +154,6 @@ static int memory_init(void) {
- /* #endif HAVE_LIBKSTAT */
-
--#elif HAVE_SYSCTL
-- pagesize = getpagesize();
-- if (pagesize <= 0) {
-- ERROR("memory plugin: Invalid pagesize: %i", pagesize);
-- return -1;
-- }
--/* #endif HAVE_SYSCTL */
--
- #elif HAVE_LIBSTATGRAB
- /* no init stuff */
- /* #endif HAVE_LIBSTATGRAB */
-@@ -221,6 +225,46 @@ static int memory_read_internal(value_li
- /* #endif HAVE_HOST_STATISTICS */
+ #elif defined(KERNEL_LINUX)
+@@ -225,6 +238,45 @@ static int memory_read_internal(value_li
+ /* #endif HAVE_HOST_STATISTICS */
#elif HAVE_SYSCTLBYNAME
+
@@ -111,16 +84,15 @@ sysctl over sysctlbyname.
+/* #endif HAVE_SYSCTL && defined(KERNEL_NETBSD) */
+
+#else /* Other HAVE_SYSCTLBYNAME providers */
-+
/*
* vm.stats.vm.v_page_size: 4096
* vm.stats.vm.v_page_count: 246178
-@@ -259,6 +303,8 @@ static int memory_read_internal(value_li
+@@ -263,6 +315,8 @@ static int memory_read_internal(value_li
(gauge_t)sysctl_vals[3], "active", (gauge_t)sysctl_vals[4],
"inactive", (gauge_t)sysctl_vals[5], "cache",
(gauge_t)sysctl_vals[6]);
+
+#endif /* HAVE_SYSCTL && KERNEL_NETBSD */
- /* #endif HAVE_SYSCTLBYNAME */
+ /* #endif HAVE_SYSCTLBYNAME */
#elif KERNEL_LINUX
diff --git a/collectd/patches/patch-src_netstat__udp.c b/collectd/patches/patch-src_netstat__udp.c
index e65c4f904a..29565a6009 100644
--- a/collectd/patches/patch-src_netstat__udp.c
+++ b/collectd/patches/patch-src_netstat__udp.c
@@ -28,7 +28,7 @@ Useful for busyish DNS name servers.
+ **/
+
+#include "collectd.h"
-+#include "common.h"
++#include "utils/common/common.h"
+#include "plugin.h"
+
+#if !defined(KERNEL_NETBSD)
diff --git a/collectd/patches/patch-src_nfs.c b/collectd/patches/patch-src_nfs.c
index 8b22b4bb31..9a2581772d 100644
--- a/collectd/patches/patch-src_nfs.c
+++ b/collectd/patches/patch-src_nfs.c
@@ -1,75 +1,31 @@
$NetBSD: patch-src_nfs.c,v $
-Provide a port to NetBSD.
+Don't use undefined suppress_warning variable (see
+https://github.com/collectd/collectd/pull/3495).
---- src/nfs.c.orig 2017-11-18 10:03:27.000000000 +0100
-+++ src/nfs.c 2019-10-31 15:48:19.000000000 +0100
-@@ -27,6 +27,15 @@
- #include "common.h"
- #include "plugin.h"
+--- src/nfs.c.orig 2020-07-07 12:20:18.984988453 +0200
++++ src/nfs.c 2020-07-07 12:20:23.513661540 +0200
+@@ -622,19 +622,14 @@ static int nfs_read(void) {
-+#if KERNEL_NETBSD
-+#include <sys/param.h>
-+#include <sys/mount.h>
-+#include <sys/sysctl.h>
-+#include <nfs/rpcv2.h>
-+#include <nfs/nfsproto.h>
-+#include <nfs/nfs.h>
-+#endif
-+
- #if HAVE_KSTAT_H
- #include <kstat.h>
- #endif
-@@ -82,12 +91,14 @@ Number Procedures Procedures
- 21 commit
- */
-
-+#if KERNEL_LINUX | HAVE_KSTAT
- static const char *nfs2_procedures_names[] = {
- "null", "getattr", "setattr", "root", "lookup", "readlink",
- "read", "wrcache", "write", "create", "remove", "rename",
- "link", "symlink", "mkdir", "rmdir", "readdir", "fsstat"};
- static size_t nfs2_procedures_names_num =
- STATIC_ARRAY_SIZE(nfs2_procedures_names);
-+#endif
-
- static const char *nfs3_procedures_names[] = {
- "null", "getattr", "setattr", "lookup", "access", "readlink",
-@@ -320,7 +331,7 @@ static int nfs_config(const char *key, c
- return 0;
- }
-
--#if KERNEL_LINUX
-+#if KERNEL_LINUX || KERNEL_NETBSD
- static int nfs_init(void) { return 0; }
- /* #endif KERNEL_LINUX */
+ /* NetBSD reports v2 statistics mapped to v3 and doen't yet support v4 */
+ if (report_v2) {
+- if (!suppress_warning) {
+- WARNING(
+- "nfs plugin: NFSv2 statistics have been requested "
+- "but they are mapped to NFSv3 statistics in the kernel on NetBSD.");
+- }
++ WARNING("nfs plugin: NFSv2 statistics have been requested "
++ "but they are mapped to NFSv3 statistics in the kernel on NetBSD.");
+ return 0;
+ }
-@@ -596,6 +607,28 @@ static int nfs_read(void) {
- }
- /* #endif KERNEL_LINUX */
+ if (report_v4) {
+- if (!suppress_warning) {
+- WARNING("nfs plugin: NFSv4 statistics have been requested "
+- "but they are not yet supported on NetBSD.");
+- }
++ WARNING("nfs plugin: NFSv4 statistics have been requested "
++ "but they are not yet supported on NetBSD.");
+ return 0;
+ }
-+#elif KERNEL_NETBSD
-+static int nfs_read(void) {
-+ struct nfsstats ns;
-+ size_t size = sizeof(ns);
-+ int mib[] = { CTL_VFS, 2, NFS_NFSSTATS };
-+ value_t values[nfs3_procedures_names_num];
-+ int i;
-+
-+ /* NetBSD reports v2 statistics mapped to v3 and doen't yet support v4 */
-+ if (!report_v3) return 0;
-+ if (sysctl(mib, 3, &ns, &size, NULL, 0) != 0) return 1;
-+
-+ for (i = 0; i < nfs3_procedures_names_num; i++) values[i].counter = (derive_t)ns.rpccnt[i];
-+ nfs_procedures_submit("v3client", nfs3_procedures_names, values, nfs3_procedures_names_num);
-+
-+ for (i = 0; i < nfs3_procedures_names_num; i++) values[i].counter = (derive_t)ns.srvrpccnt[i];
-+ nfs_procedures_submit("v3server", nfs3_procedures_names, values, nfs3_procedures_names_num);
-+
-+ return 0;
-+}
-+/* #endif KERNEL_NETBSD */
-+
- #elif HAVE_LIBKSTAT
- static int nfs_read(void) {
- if (report_v2) {
diff --git a/collectd/patches/patch-src_processes.c b/collectd/patches/patch-src_processes.c
index a61690e77e..ff1553b754 100644
--- a/collectd/patches/patch-src_processes.c
+++ b/collectd/patches/patch-src_processes.c
@@ -2,9 +2,9 @@ $NetBSD: patch-src_processes.c,v 1.8 2017/11/21 16:02:20 he Exp $
Add a port to NetBSD.
---- src/processes.c.orig 2017-06-06 18:13:54.693164693 +0000
-+++ src/processes.c
-@@ -97,14 +97,16 @@
+--- src/processes.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/processes.c 2020-07-06 20:15:33.891304651 +0200
+@@ -102,14 +102,16 @@
/* #endif KERNEL_LINUX */
#elif HAVE_LIBKVM_GETPROCS && \
@@ -23,7 +23,7 @@ Add a port to NetBSD.
#elif HAVE_PROCINFO_H
#include <procinfo.h>
-@@ -286,10 +288,15 @@ static void ps_fill_details(const procst
+@@ -315,10 +317,15 @@ static void ps_fill_details(const procst
/* #endif KERNEL_LINUX */
#elif HAVE_LIBKVM_GETPROCS && \
@@ -41,8 +41,8 @@ Add a port to NetBSD.
#elif HAVE_PROCINFO_H
static struct procentry64 procentry[MAXPROCENTRY];
-@@ -673,10 +680,21 @@ static int ps_init(void) {
- /* #endif KERNEL_LINUX */
+@@ -774,10 +781,21 @@ static int ps_init(void) {
+ /* #endif KERNEL_LINUX */
#elif HAVE_LIBKVM_GETPROCS && \
- (HAVE_STRUCT_KINFO_PROC_FREEBSD || HAVE_STRUCT_KINFO_PROC_OPENBSD)
@@ -59,15 +59,15 @@ Add a port to NetBSD.
+#endif
+
pagesize = getpagesize();
- /* #endif HAVE_LIBKVM_GETPROCS && (HAVE_STRUCT_KINFO_PROC_FREEBSD ||
-- * HAVE_STRUCT_KINFO_PROC_OPENBSD) */
-+ * HAVE_STRUCT_KINFO_PROC_OPENBSD || HAVE_STRUCT_KINFO_PROC2_NETBSD) */
+ /* #endif HAVE_LIBKVM_GETPROCS && (HAVE_STRUCT_KINFO_PROC_FREEBSD ||
+- * HAVE_STRUCT_KINFO_PROC_OPENBSD) */
++ * HAVE_STRUCT_KINFO_PROC_OPENBSD || HAVE_STRUCT_KINFO_PROC2_NETBSD) */
#elif HAVE_PROCINFO_H
pagesize = getpagesize();
-@@ -2074,6 +2092,197 @@ static int ps_read(void) {
+@@ -2296,6 +2314,196 @@ static int ps_read(void) {
ps_submit_proc_list(ps_ptr);
- /* #endif HAVE_LIBKVM_GETPROCS && HAVE_STRUCT_KINFO_PROC_FREEBSD */
+ /* #endif HAVE_LIBKVM_GETPROCS && HAVE_STRUCT_KINFO_PROC_FREEBSD */
+#elif HAVE_LIBKVM_GETPROCS && HAVE_STRUCT_KINFO_PROC2_NETBSD
+ int running = 0;
@@ -258,7 +258,6 @@ Add a port to NetBSD.
+ for (ps_ptr = list_head_g; ps_ptr != NULL; ps_ptr = ps_ptr->next)
+ ps_submit_proc_list (ps_ptr);
+/* #endif HAVE_LIBKVM_GETPROCS && HAVE_STRUCT_KINFO_PROC2_NETBSD */
-+
+
#elif HAVE_LIBKVM_GETPROCS && HAVE_STRUCT_KINFO_PROC_OPENBSD
int running = 0;
diff --git a/collectd/patches/patch-src_swap.c b/collectd/patches/patch-src_swap.c
index 7eba7bf5e4..d529e12c42 100644
--- a/collectd/patches/patch-src_swap.c
+++ b/collectd/patches/patch-src_swap.c
@@ -3,10 +3,10 @@ $NetBSD: patch-src_swap.c,v 1.5 2017/11/21 15:18:23 fhajny Exp $
Extend support for NetBSD, and add per-swap-device
reporting for HAVE_SWAPCTL_THREE_ARGS.
---- src/swap.c.orig 2017-11-18 09:03:27.366749826 +0000
-+++ src/swap.c
-@@ -78,9 +78,12 @@ static _Bool report_bytes = 0;
- static _Bool report_by_device = 0;
+--- src/swap.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/swap.c 2020-07-06 20:21:18.416804717 +0200
+@@ -80,9 +80,12 @@ static bool report_bytes;
+ static bool report_by_device;
/* #endif KERNEL_LINUX */
-#elif HAVE_SWAPCTL && HAVE_SWAPCTL_TWO_ARGS
@@ -16,10 +16,10 @@ reporting for HAVE_SWAPCTL_THREE_ARGS.
+#if KERNEL_NETBSD
+static _Bool report_bytes = 0;
+#endif
- static _Bool report_by_device = 0;
+ static bool report_by_device;
/* #endif HAVE_SWAPCTL && HAVE_SWAPCTL_TWO_ARGS */
-@@ -118,7 +121,7 @@ static int swap_config(oconfig_item_t *c
+@@ -120,7 +123,7 @@ static int swap_config(oconfig_item_t *c
for (int i = 0; i < ci->children_num; i++) {
oconfig_item_t *child = ci->children + i;
if (strcasecmp("ReportBytes", child->key) == 0)
@@ -28,16 +28,16 @@ reporting for HAVE_SWAPCTL_THREE_ARGS.
cf_util_get_boolean(child, &report_bytes);
#else
WARNING("swap plugin: The \"ReportBytes\" option "
-@@ -152,7 +155,7 @@ static int swap_init(void) /* {{{ */
+@@ -154,7 +157,7 @@ static int swap_init(void) /* {{{ */
pagesize = (derive_t)sysconf(_SC_PAGESIZE);
- /* #endif KERNEL_LINUX */
+ /* #endif KERNEL_LINUX */
-#elif HAVE_SWAPCTL && HAVE_SWAPCTL_TWO_ARGS
+#elif HAVE_SWAPCTL && (HAVE_SWAPCTL_TWO_ARGS || HAVE_SWAPCTL_THREE_ARGS)
/* getpagesize(3C) tells me this does not fail.. */
pagesize = (derive_t)getpagesize();
- /* #endif HAVE_SWAPCTL */
-@@ -210,7 +213,7 @@ static void swap_submit_usage(char const
+ /* #endif HAVE_SWAPCTL */
+@@ -212,7 +215,7 @@ static void swap_submit_usage(char const
free, other_name, other_value, NULL);
} /* }}} void swap_submit_usage */
@@ -46,7 +46,7 @@ reporting for HAVE_SWAPCTL_THREE_ARGS.
__attribute__((nonnull(1))) static void
swap_submit_derive(char const *type_instance, /* {{{ */
derive_t value) {
-@@ -577,6 +580,43 @@ static int swap_read(void) /* {{{ */
+@@ -549,6 +552,43 @@ static int swap_read(void) /* {{{ */
/* #endif HAVE_SWAPCTL && HAVE_SWAPCTL_TWO_ARGS */
#elif HAVE_SWAPCTL && HAVE_SWAPCTL_THREE_ARGS
@@ -90,7 +90,7 @@ reporting for HAVE_SWAPCTL_THREE_ARGS.
static int swap_read(void) /* {{{ */
{
struct swapent *swap_entries;
-@@ -615,12 +655,32 @@ static int swap_read(void) /* {{{ */
+@@ -587,12 +627,32 @@ static int swap_read(void) /* {{{ */
/* TODO: Report per-device stats. The path name is available from
* swap_entries[i].se_path */
for (int i = 0; i < swap_num; i++) {
@@ -126,7 +126,7 @@ reporting for HAVE_SWAPCTL_THREE_ARGS.
if (total < used) {
ERROR(
-@@ -631,8 +691,15 @@ static int swap_read(void) /* {{{ */
+@@ -603,8 +663,15 @@ static int swap_read(void) /* {{{ */
}
swap_submit_usage(NULL, used, total - used, NULL, NAN);
diff --git a/collectd/patches/patch-src_tcpconns.c b/collectd/patches/patch-src_tcpconns.c
index a669589c8c..56897faf69 100644
--- a/collectd/patches/patch-src_tcpconns.c
+++ b/collectd/patches/patch-src_tcpconns.c
@@ -3,9 +3,9 @@ $NetBSD: patch-src_tcpconns.c,v 1.7 2017/11/21 15:18:23 fhajny Exp $
Include <sys/param.h>
Re-order to fix build on NetBSD.
---- src/tcpconns.c.orig 2017-11-18 09:03:27.370749644 +0000
-+++ src/tcpconns.c
-@@ -128,9 +128,9 @@
+--- src/tcpconns.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/tcpconns.c 2020-07-06 20:25:33.959459766 +0200
+@@ -127,9 +127,9 @@
#include <net/route.h>
#include <netdb.h>
#include <netinet/in.h>
@@ -16,7 +16,7 @@ Re-order to fix build on NetBSD.
#include <netinet/ip_var.h>
#include <netinet/tcp.h>
#include <netinet/tcp_timer.h>
-@@ -897,6 +897,7 @@ static int conn_init(void) {
+@@ -895,6 +895,7 @@ static int conn_init(void) {
return 0;
} /* int conn_init */
diff --git a/collectd/patches/patch-src_utils_dns_dns.c b/collectd/patches/patch-src_utils_dns_dns.c
index 8643e9c3bd..2d55df0111 100644
--- a/collectd/patches/patch-src_utils_dns_dns.c
+++ b/collectd/patches/patch-src_utils_dns_dns.c
@@ -2,9 +2,9 @@ $NetBSD: patch-src_utils__dns.c,v 1.3 2020/02/03 09:12:32 triaxx Exp $
Resolve conflict with pkgsrc PCAP on NetBSD 7 and 8.
---- src/utils_dns.c.orig 2017-11-18 09:03:27.370749644 +0000
-+++ src/utils_dns.c
-@@ -91,6 +91,12 @@
+--- src/utils/dns/dns.c.orig 2020-03-08 16:57:09.000000000 +0100
++++ src/utils/dns/dns.c 2020-07-20 12:55:29.000000000 +0200
+@@ -85,6 +85,12 @@
#endif
#if HAVE_PCAP_H
diff --git a/collectd/patches/patch-src_utils_format__kairosdb_format__kairosdb.c b/collectd/patches/patch-src_utils_format__kairosdb_format__kairosdb.c
index a1d8eec823..b97b0e8aeb 100644
--- a/collectd/patches/patch-src_utils_format__kairosdb_format__kairosdb.c
+++ b/collectd/patches/patch-src_utils_format__kairosdb_format__kairosdb.c
@@ -3,8 +3,8 @@ $NetBSD: patch-src_utils__format__kairosdb.c,v 1.4 2017/01/19 17:20:42 he Exp $
Cast arguments to isalnum() and tolower() to "unsigned char" to
squelch warnings.
---- src/utils_format_kairosdb.c.orig 2016-11-30 08:52:01.000000000 +0000
-+++ src/utils_format_kairosdb.c
+--- src/utils/format_kairosdb/format_kairosdb.c.orig 2016-11-30 08:52:01.000000000 +0000
++++ src/utils/format_kairosdb/format_kairosdb.c
@@ -80,9 +80,9 @@ static int kairosdb_escape_string(char *
/* authorize -_. and alpha num but also escapes " */
BUFFER_ADD('"');
Home |
Main Index |
Thread Index |
Old Index