Marc Fournier [Wed, 3 Dec 2014 15:15:28 +0000 (16:15 +0100)]
netlink: ensure size_t portability in DEBUG() statement
This prevents the following error when building on 32bit systems with
gcc 4.7.2:
netlink.c: In function 'ir_read':
netlink.c:783:7: error: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'size_t' [-Werror=format]
Marc Fournier [Mon, 24 Nov 2014 08:23:18 +0000 (09:23 +0100)]
Merge branch 'collectd-5.3' into collectd-5.4
Conflicts:
src/write_graphite.c
Marc Fournier [Mon, 24 Nov 2014 08:18:44 +0000 (09:18 +0100)]
Merge branch 'collectd-4.10' into collectd-5.3
Marc Fournier [Wed, 19 Nov 2014 16:59:30 +0000 (17:59 +0100)]
Revert "Let snmp_synch_response deal with PDU freeing"
This reverts commit
9d6f72e5054cfbb183585991fefcf119259d71c4.
The proper fix to this issue is in the collectd-4.10 branch. See also
79e90bba.
Marc Fournier [Wed, 19 Nov 2014 16:49:30 +0000 (17:49 +0100)]
Revert "Let snmp_synch_response deal with PDU freeing"
This reverts commit
e767dc103a142e1c57800f06a9c384f21a48aef5.
The proper fix to this issue is in the collectd-4.10 branch. See also
79e90bba.
Marc Fournier [Wed, 19 Nov 2014 16:54:09 +0000 (17:54 +0100)]
snmp: avoid freeing req under normal operation
Equivalent patch to
79e90bba5, to avoid issue #804 introduced while
fixing #610.
Pierre-Yves Ritschard [Wed, 19 Nov 2014 15:00:54 +0000 (16:00 +0100)]
Let snmp_synch_response deal with PDU freeing
When reading from tables, upon errors the PDUs sent are already
freed by snmp_synch_response since they are right after
snmp_send is called.
This commit syncs collectd's approach with other occurences of
snmp_synch_response calls.
There might be a few corner cases where we leak PDUs, but it
is unclear how to check for those since we would need to
have an indication that snmp_send was never called, which
as far as I can tell is not possible.
The potential for failure in snmp_send is rather low and will
be easily spotted though, since when crafting invalid PDUs
snmp send will constantly fail and since valid configurations
can never leak memory.
This fixes #804
Pierre-Yves Ritschard [Wed, 19 Nov 2014 15:00:54 +0000 (16:00 +0100)]
Let snmp_synch_response deal with PDU freeing
When reading from tables, upon errors the PDUs sent are already
freed by snmp_synch_response since they are right after
snmp_send is called.
This commit syncs collectd's approach with other occurences of
snmp_synch_response calls.
There might be a few corner cases where we leak PDUs, but it
is unclear how to check for those since we would need to
have an indication that snmp_send was never called, which
as far as I can tell is not possible.
The potential for failure in snmp_send is rather low and will
be easily spotted though, since when crafting invalid PDUs
snmp send will constantly fail and since valid configurations
can never leak memory.
This fixes #804
Pierre-Yves Ritschard [Sat, 15 Nov 2014 14:45:00 +0000 (15:45 +0100)]
Merge pull request #796 from mfournier/write_redis-colon-mistake
write_redis: re-add colon dropped in
b7984797 + manpage
Bjørn Nordbø [Wed, 12 Nov 2014 11:27:43 +0000 (12:27 +0100)]
Link aggregation.so to libm.so
Conflicts:
src/Makefile.am
Pierre-Yves Ritschard [Tue, 11 Nov 2014 18:39:58 +0000 (19:39 +0100)]
Merge pull request #765 from tokkee/sh/write-err
Use the complain mechanism to report write failures.
Vincent Bernat [Fri, 7 Nov 2014 14:20:22 +0000 (15:20 +0100)]
network: don't enable gcrypt thread callbacks when gcrypt recent enough
From `gcrypt.h`:
> NOTE: Since Libgcrypt 1.6 the thread callbacks are not anymore used.
> However we keep it to allow for some source code compatibility if used
> in the standard way.
Otherwise, we get a deprecation warning which is turned into an error:
```
CC libcollectdclient_la-network_buffer.lo
../../../src/libcollectdclient/network_buffer.c:58:15: error: 'gcry_thread_cbs' is deprecated (declared at /usr/include/gcrypt.h:213) [-Werror=deprecated-declarations]
GCRY_THREAD_OPTION_PTHREAD_IMPL;
```
Fixes: #632
Marc Fournier [Tue, 11 Nov 2014 10:39:40 +0000 (11:39 +0100)]
add write_redis to manpage
Marc Fournier [Sat, 8 Nov 2014 23:16:11 +0000 (00:16 +0100)]
write_redis: re-add colon dropped in
b7984797
When running
f3706b0b87, the following command gets sent to redis:
"ZADD" "collectd/hostname/entropy/entropy" "
1415487432.000000" "
1415487432:932"
Meaning the value actually stored, and later returned by redis is:
"<timstamp>:<value>".
b7984797 accidentally dropped the comma separating the timestamp and the
value, which leads the plugin to store a somewhat confusing value in
redis:
"ZADD" "collectd/hostname/entropy/entropy" "
1415487432.000000" "
1415487432932"
Marc Fournier [Fri, 7 Nov 2014 16:37:40 +0000 (17:37 +0100)]
redhat initscript: add timeout when stopping the daemon
This mitigates the risk of having 2 daemons running simultaneously
during a short period, on restart.
The debian package's initscript does the same thing, using the same
timeout value.
Pierre-Yves Ritschard [Tue, 4 Nov 2014 16:41:38 +0000 (17:41 +0100)]
Merge pull request #764 from tokkee/sh/collectd-5.3
write_graphite plugin: Improved error reporting when connecting to the server.
Katelyn Perry [Mon, 3 Nov 2014 23:11:14 +0000 (17:11 -0600)]
fix grammar in plugin loading error message
"cause for this problem are" => "cause for this problem is"
Marc Fournier [Tue, 24 Jun 2014 15:47:08 +0000 (17:47 +0200)]
logfile: avoid total silence in case of a misconfiguration
Basically the same patch that was applied to syslog.c in
84c38056
Marc Fournier [Tue, 24 Jun 2014 15:48:26 +0000 (17:48 +0200)]
correct typo in error message
Wilfried Goesgens [Sat, 7 Jun 2014 10:01:32 +0000 (12:01 +0200)]
Syslog: if we can't find the loglevel specified by the configuration string default to 'info' and warn about the unknown configuration option. no way to make syslog totaly silent anymore.
Wilfried Goesgens [Thu, 30 Oct 2014 20:32:17 +0000 (21:32 +0100)]
curl_json: fix the array access implemented in
f1e1e37e
In the avl-tree we store two different structs, cj_key_t for the value
we search, c_avl_tree_t for sub-nodes.
The old version does assume when it will find a key, and when a tree,
which doesn't have to be right in all cases.
Therefore we utilize the magic to revalidate this cast.
Being able to tell tree from key, we now can also implement array access
on the right most node of the tree-path.
Sebastian Harl [Sun, 19 Oct 2014 18:25:50 +0000 (20:25 +0200)]
Use the complain mechanism to report write failures.
This ensures that we don't spam the log for each submitted value. Instead, an
exponential backup is used to report permanent errors starting at one message
per second.
Sebastian Harl [Sun, 19 Oct 2014 16:22:09 +0000 (18:22 +0200)]
write_graphite plugin: Improved error reporting when connecting to the server.
Marc Fournier [Thu, 25 Sep 2014 16:54:56 +0000 (18:54 +0200)]
statsd: clarify/simplify documentation & example
Denis Boulas [Tue, 23 Sep 2014 08:08:25 +0000 (11:08 +0300)]
Added documentation for StatsD module per added functionality in issue #403.
Scott Sanders [Fri, 19 Sep 2014 14:31:18 +0000 (10:31 -0400)]
Bit shift right by 8 to get return code from exit status
Pull-Request: #741
Signed-off-by: Florian Forster <octo@collectd.org>
Florian Forster [Wed, 17 Sep 2014 06:24:57 +0000 (08:24 +0200)]
cpu plugin: Remove temperature code for Mac OS X.
This code would throw an error for some systems, because the temperature
couldn't be read. Since the plugin still works in general, this was very
confusing to users. Becaus the temperature, even when read sucessfully, was
never dispatched, remove the code entirely. We might want to add this back to
the apple_sensors plugin eventually.
Fixes: #22
Florian Forster [Wed, 17 Sep 2014 05:41:38 +0000 (07:41 +0200)]
swap plugin: Make "cached" optional under Linux.
This is the smallest possible fix for OpenVZ, where cached is not available.
master has a more complete fix which should be used going forward.
Fixes: #733
Vladimir Smirnov [Wed, 10 Sep 2014 19:08:50 +0000 (21:08 +0200)]
Fix typo in if caluse
Fixes #729
Signed-off-by: Florian Forster <octo@collectd.org>
Florian Forster [Wed, 10 Sep 2014 15:15:24 +0000 (17:15 +0200)]
Merge branch 'collectd-5.3' into collectd-5.4
Florian Forster [Wed, 10 Sep 2014 14:54:26 +0000 (16:54 +0200)]
src/common.c: Fix strstripnewline().
Because the length of the string was decremented too late, the function
would actually overwrite the trailing null byte instead of the newline.
Marc Fournier [Mon, 8 Sep 2014 15:29:14 +0000 (17:29 +0200)]
RPM specfile: enable lvm plugin on RHEL7
Marc Fournier [Mon, 8 Sep 2014 15:21:38 +0000 (17:21 +0200)]
Merge branch 'collectd-5.3' into collectd-5.4
Conflicts:
contrib/redhat/collectd.spec
Marc Fournier [Mon, 8 Sep 2014 14:59:30 +0000 (16:59 +0200)]
RPM specfile: enable netlink plugin on RHEL > 5
Marc Fournier [Mon, 8 Sep 2014 14:42:14 +0000 (16:42 +0200)]
RPM specfile: fix bogus dates
modern rpmbuild versions appear to be more strict on this point.
Marc Fournier [Mon, 8 Sep 2014 14:41:21 +0000 (16:41 +0200)]
RPM specfile: support for RHEL7
Marc Fournier [Mon, 8 Sep 2014 12:12:51 +0000 (14:12 +0200)]
RPM specfile: add missing %files section for modbus plugin
complement to
a781eb2c5
Marc Fournier [Mon, 8 Sep 2014 10:49:49 +0000 (12:49 +0200)]
RPM specfile: remove define accidentally re-added when handling merge conflict
Marc Fournier [Mon, 8 Sep 2014 10:38:53 +0000 (12:38 +0200)]
RPM specfile: remove macro accidentally re-added when handling merge conflict
Marc Fournier [Mon, 8 Sep 2014 10:26:55 +0000 (12:26 +0200)]
RPM specfile: remove duplicate modbus block
Florian Forster [Sat, 6 Sep 2014 09:27:56 +0000 (11:27 +0200)]
Merge branch 'collectd-5.3' into collectd-5.4
Conflicts:
src/curl.c
Florian Forster [Sat, 6 Sep 2014 08:58:45 +0000 (10:58 +0200)]
network plugin: Improve client connecting behavior.
This moves the socket creation logic so it's called from
networt_send_buffer_plain(). This allows us to recover after network
failures or when collectd was started before the network was available.
Fixes: #627
Florian Forster [Wed, 3 Sep 2014 07:10:00 +0000 (09:10 +0200)]
src/utils_match.[ch]: Implement match_value_reset().
This is called from the curl and memcachec plugins. Previously, gauge
average, minimum and maximum values were calculated since the start of
the daemon, rather than per-interval. This is not the documented
functionality.
Fixes: #663
Florian Forster [Wed, 3 Sep 2014 05:39:27 +0000 (07:39 +0200)]
curl plugin: Use the utility functions for config handling.
Florian Forster [Tue, 2 Sep 2014 17:51:37 +0000 (19:51 +0200)]
Merge remote-tracking branch 'github/collectd-5.3' into collectd-5.3
Florian Forster [Tue, 2 Sep 2014 17:50:47 +0000 (19:50 +0200)]
src/meta_data.c: If the meta_data_t is empty, avoid calling malloc(0).
Florian Forster [Tue, 2 Sep 2014 17:49:11 +0000 (19:49 +0200)]
src/utils_format_json.c: Handle empty meta_data_t gracefully.
Previously, `meta != NULL` and `keys_num == 0` was possible and would
result in "{}", which is not valid JSON.
Fixes: 716
Florian Forster [Tue, 2 Sep 2014 17:48:10 +0000 (19:48 +0200)]
python plugin: Don't create empty meta_data_t objects.
Fixes: #716
Florian Forster [Tue, 2 Sep 2014 14:54:07 +0000 (16:54 +0200)]
src/utils_rrdcreate.c: Free "args".
Thanks to Yves Mettier for pointing this out!
Fixes: #661
Marc Fournier [Fri, 29 Aug 2014 15:26:41 +0000 (17:26 +0200)]
Merge branch 'collectd-5.3' into collectd-5.4
Conflicts:
contrib/redhat/collectd.spec
Marc Fournier [Fri, 29 Aug 2014 15:20:57 +0000 (17:20 +0200)]
RPM specfile: update changelog without incrementing release number
Florian Forster [Thu, 28 Aug 2014 18:55:45 +0000 (20:55 +0200)]
GenericJMXConfConnection: Remove unused imports.
Florian Forster [Thu, 28 Aug 2014 18:41:25 +0000 (20:41 +0200)]
java plugin: Make sure cjni_thread_detach() is called on all paths.
Each call to cjni_thread_attach() much be accompanied by
a call to cjni_thread_detach(). Some error handling cases were missing
the call, potentially locking the plugin up.
Florian Forster [Fri, 29 Aug 2014 05:00:33 +0000 (07:00 +0200)]
collectd.conf(5): Improve AutoLoadPlugin documentation.
Make it clear that plugins without a <Plugin /> block will still need a
LoadPlugin line.
References: #715
Florian Forster [Wed, 27 Aug 2014 11:04:59 +0000 (13:04 +0200)]
collectd.conf(5): Improve documentation of LoadPlugin.
Mention AutoLoadPlugin in the relevant places. Add a <Plugin /> block
for the "df" plugin to make it easier to spot that it is preceded by a
<LoadPlugin /> *block*.
Fixes: #715
Kevin Bowling [Thu, 14 Aug 2014 09:30:45 +0000 (02:30 -0700)]
EL <6 provide perl-ExtUtils-Embed with base perl
Conflicts:
contrib/redhat/collectd.spec
John Leach [Mon, 18 Aug 2014 20:36:35 +0000 (21:36 +0100)]
Statsd: support samplerate field in timing metric types
Fixes "Unable to parse line" bug, often seen receiving stats from
OpenStack Swift. Should fix GH issue #461
Florian Forster [Mon, 18 Aug 2014 07:58:34 +0000 (09:58 +0200)]
collectd.conf: Fix default packet size of the network plugin.
Fixes: #710
Florian Forster [Mon, 18 Aug 2014 07:35:04 +0000 (09:35 +0200)]
Merge branch 'collectd-5.3' into collectd-5.4
Conflicts:
contrib/redhat/collectd.spec
Florian Forster [Mon, 18 Aug 2014 07:33:29 +0000 (09:33 +0200)]
Merge branch 'collectd-4.10' into collectd-5.3
Arthur Marble [Sun, 17 Aug 2014 22:34:04 +0000 (17:34 -0500)]
curl_xml plugin: Fixed tautological pointer comparison error.
Fixes: http://bugs.debian.org/758481
Signed-off-by: Florian Forster <octo@collectd.org>
Marc Fournier [Wed, 13 Aug 2014 07:09:14 +0000 (09:09 +0200)]
collectd.conf(5): add detail & example about multi-instance filterchain targets
Marc Fournier [Fri, 8 Aug 2014 13:55:10 +0000 (15:55 +0200)]
snmp: free snmp_pdu struct allocated by snmp_pdu_create()
This should fix the leak reported in issue #610.
Marc Fournier [Thu, 7 Aug 2014 13:42:22 +0000 (15:42 +0200)]
Merge pull request #540 from tokkee/configure
configure: Fixed check for libsigrok and AM_PATH_GLIB_2_0.
Marc Fournier [Thu, 7 Aug 2014 12:32:47 +0000 (14:32 +0200)]
Merge pull request #689 from ymettier/ym/cd53_fix_tcpconns_inet_diag
Fix for 'linux/inet_diag.h: No such file or directory'
Marc Fournier [Wed, 6 Aug 2014 14:59:21 +0000 (16:59 +0200)]
RedHat RPM spec: add modbus plugin
... now that EPEL6 provides libmodbus
Yves Mettier [Mon, 4 Aug 2014 12:01:01 +0000 (14:01 +0200)]
Fix for 'linux/inet_diag.h: No such file or directory'
Marc Fournier [Mon, 4 Aug 2014 11:37:09 +0000 (13:37 +0200)]
fix: use DOUBLE_TO_CDTIME_T() to match input type
... as strtod() returns a double not a time_t.
Follow-up to
7d1d59fb to match what
ada80db25 does (currently in
master) and avoid a merge conflict.
KOMEDA Shinji [Wed, 30 Jul 2014 08:56:07 +0000 (17:56 +0900)]
mistake, SAVE_LIBS="$LIBS" is correct.
KOMEDA Shinji [Wed, 25 Jun 2014 13:34:15 +0000 (22:34 +0900)]
patch required to build oracle plugin, collectd-5.4.0 (#653)
Pierre-Yves Ritschard [Mon, 28 Jul 2014 20:48:17 +0000 (22:48 +0200)]
Merge pull request #579 from mfournier/libiptc-ldflags
link iptables plugin against flags from pkg-config
Pierre-Yves Ritschard [Mon, 28 Jul 2014 15:07:17 +0000 (17:07 +0200)]
Merge pull request #677 from collectd/revert-630-F-METRICS-383-tsdb-writer-5.4
Revert "write_tsdb plugin"
Pierre-Yves Ritschard [Mon, 28 Jul 2014 15:07:07 +0000 (17:07 +0200)]
Revert "write_tsdb plugin"
Pierre-Yves Ritschard [Mon, 28 Jul 2014 15:07:02 +0000 (17:07 +0200)]
Merge pull request #630 from llnw/F-METRICS-383-tsdb-writer-5.4
write_tsdb plugin
Sebastian Harl [Sun, 27 Jul 2014 12:15:23 +0000 (14:15 +0200)]
utils_vl_lookup: Fixed a race when creating user objects.
This could cause multiple aggregation instances to be created in the
aggregation plugin when first writing data to the plugin. This, in turn, led
to "value too old" warnings because subsequently all data was submitted twice.
Thanks to @faxm0dem for reporting this in GH #535.
Manuel Luis Sanmartín Rozada [Thu, 19 Jun 2014 14:37:15 +0000 (16:37 +0200)]
Plugin exec: change notification time to integer.
Acording to collectd-exec.5 NOTIFICATION DATA FORMAT: time is epoch, i. e. as seconds since 1970-01-01 00:00:00 UTC.
Manuel Luis Sanmartín Rozada [Thu, 19 Jun 2014 17:14:53 +0000 (19:14 +0200)]
cmd PUTNOTIF time option: handle double values.
Conflicts:
src/utils_cmd_putnotif.c
Manuel Luis Sanmartín Rozada [Thu, 19 Jun 2014 13:14:02 +0000 (15:14 +0200)]
Plugin java: fix notification time conversion to cdtime_t.
Manuel Luis Sanmartín Rozada [Thu, 19 Jun 2014 14:50:48 +0000 (16:50 +0200)]
Plugin threshold: time is not set in missing notifications.
Pierre-Yves Ritschard [Sat, 26 Jul 2014 07:40:11 +0000 (09:40 +0200)]
Merge pull request #592 from mfournier/bug-582
curl_json: also allow long callback names.
Marc Fournier [Tue, 24 Jun 2014 15:09:08 +0000 (17:09 +0200)]
manpage: document 2 missing options to amqp plugin section
Marc Fournier [Mon, 23 Jun 2014 16:00:01 +0000 (18:00 +0200)]
add missing backticks which broke the build
Marc Fournier [Mon, 23 Jun 2014 14:47:20 +0000 (16:47 +0200)]
write_riemann: coding style consistency
Make the style in line with
50d1b34d6 (from master) and avoid later
merge conflict.
Lauri Tirkkonen [Thu, 22 May 2014 11:05:40 +0000 (14:05 +0300)]
don't assume pkg-config is in PATH
Wilfried Goesgens [Thu, 5 Jun 2014 18:04:13 +0000 (20:04 +0200)]
Configparser: when we alocate an empty list, we also need to reset the counter; else we will trip over this later.
This fixes https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=750440
Kevin Bowling [Wed, 11 Jun 2014 08:44:02 +0000 (01:44 -0700)]
[METRICS-390] Make sure HostTags is initialized if not configured
Kevin Bowling [Tue, 3 Jun 2014 04:11:27 +0000 (21:11 -0700)]
[METRICS-390] Fix string handling for TSDB prefix and tags
Kevin Bowling [Sat, 31 May 2014 02:42:14 +0000 (19:42 -0700)]
[METRICS-390] Add tag writing from metadata using TSDB target_set patches
Kevin Bowling [Fri, 30 May 2014 02:58:51 +0000 (19:58 -0700)]
[METRICS-383] Add HostTags which adds tags for all metrics from this writer
Kevin Bowling [Fri, 30 May 2014 01:15:21 +0000 (18:15 -0700)]
Uncrustify write_tsdb
txaj [Mon, 28 Apr 2014 16:28:41 +0000 (11:28 -0500)]
Add DeleteSocket option in synopsis of manpage
Signed-off-by: Florian Forster <octo@collectd.org>
Kevin Bowling [Tue, 22 Apr 2014 03:53:25 +0000 (20:53 -0700)]
[METRICS-383] write_tsdb plugin
Marc Fournier [Tue, 1 Apr 2014 22:22:34 +0000 (00:22 +0200)]
add brackets to the list of characters graphite chokes on
Pierre-Yves Ritschard [Fri, 24 Jan 2014 15:49:22 +0000 (16:49 +0100)]
Graphite deals poorly with metric names containing quotes.
Sanitize graphite metrics with our own escaping function,
better suited for this use-case than the one in `utils_parse_option`
Marc Fournier [Mon, 31 Mar 2014 23:10:47 +0000 (01:10 +0200)]
curl_json: also allow long callback names.
This is basically the same as
2f392819, which got applied to the
curl_xml plugin a few months ago.
Fixes #582.
Manuel Luis Sanmartin Rozada [Mon, 31 Mar 2014 19:08:05 +0000 (21:08 +0200)]
Fix check for htonll in configure.ac
Adrian Miron [Sat, 8 Mar 2014 16:56:11 +0000 (18:56 +0200)]
fix for #477: Notification time gone wrong
Sub-second time handling was added in collectd 5.0.0. This adds support
for this to the target_notification plugin, which got missed out at the
time.
Manuel Luis Sanmartín Rozada [Wed, 12 Mar 2014 14:04:39 +0000 (15:04 +0100)]
Fix getargs declaration to compile in AIX7
Manuel Luis Sanmartín Rozada [Tue, 4 Mar 2014 17:27:54 +0000 (18:27 +0100)]
AIX doesn't have MSG_DONTWAIT, define as MSG_NONBLOCK
Joel Uckelman [Tue, 4 Mar 2014 11:07:04 +0000 (12:07 +0100)]
Updated Color to match DataSources and DSName for single-series graphs.