Code

collectd.git
13 years agocurl_json plugin: Add compatibility code for libyajl v2.
Florian Forster [Tue, 5 Jul 2011 14:28:10 +0000 (16:28 +0200)]
curl_json plugin: Add compatibility code for libyajl v2.

Thanks to "spupykin" of the Arch Linux project on whose patch this commit is
loosely based.

13 years agocollectd.conf: Added a (commented out) 'LoadPlugin target_v5upgrade' line.
Sebastian Harl [Tue, 28 Jun 2011 07:09:50 +0000 (09:09 +0200)]
collectd.conf: Added a (commented out) 'LoadPlugin target_v5upgrade' line.

13 years agoREADME: Added 'write_redis' plugin.
Sebastian Harl [Sun, 5 Jun 2011 16:45:02 +0000 (18:45 +0200)]
README: Added 'write_redis' plugin.

13 years agoAMQP plugin: Fix printing of interval_g.
Florian Forster [Fri, 17 Jun 2011 14:37:31 +0000 (16:37 +0200)]
AMQP plugin: Fix printing of interval_g.

13 years agorrdcached plugin: Handle boolean config options as well.
Sebastian Harl [Fri, 17 Jun 2011 08:29:13 +0000 (10:29 +0200)]
rrdcached plugin: Handle boolean config options as well.

This was lost previously when changing to the complex config callback.

13 years agorrdcached plugin: Register write/flush only if DaemonAddress has been given.
Sebastian Harl [Fri, 17 Jun 2011 08:25:48 +0000 (10:25 +0200)]
rrdcached plugin: Register write/flush only if DaemonAddress has been given.

Else, the write callback would remove itself on the first call. This
operation, however, is not thread-safe as access to the write list is not
synchronized. Thus, removing the callback at that point leads to random
segfaults.

13 years agorrdcached plugin: Handle configuration using a "complex config" callback.
Sebastian Harl [Fri, 17 Jun 2011 08:20:17 +0000 (10:20 +0200)]
rrdcached plugin: Handle configuration using a "complex config" callback.

This allows to handle all of the configuration in one go and execute some
action once after doing so.

13 years agothreshold: Don't register missing/write callbacks unless we have thresholds.
Sebastian Harl [Fri, 17 Jun 2011 07:25:05 +0000 (09:25 +0200)]
threshold: Don't register missing/write callbacks unless we have thresholds.

The checking is fairly expensive, so don't do that unless really necessary.

13 years agoavl tree: Report size of the tree and make that available in _get_size().
Sebastian Harl [Fri, 17 Jun 2011 07:24:02 +0000 (09:24 +0200)]
avl tree: Report size of the tree and make that available in _get_size().

13 years agothreshold plugin: Dont check for interesting values if there are no thresholds.
Sebastian Harl [Fri, 17 Jun 2011 07:05:48 +0000 (09:05 +0200)]
threshold plugin: Dont check for interesting values if there are no thresholds.

13 years agoamqp plugin: Fixed format strings when printing 'interval_g'.
Sebastian Harl [Thu, 16 Jun 2011 09:42:20 +0000 (11:42 +0200)]
amqp plugin: Fixed format strings when printing 'interval_g'.

13 years agoconfigure: Removed last traces of 'owniptc'.
Sebastian Harl [Thu, 16 Jun 2011 09:11:40 +0000 (11:11 +0200)]
configure: Removed last traces of 'owniptc'.

E.g., autoconf still tried to generated src/owniptc/Makefile in AC_OUTPUT(),
which obviously fails if owniptc is no longer there.

13 years agoVarious plugins: Set the cURL option "CURLOPT_NOSIGNAL".
Mike Flisher [Sun, 22 May 2011 15:39:29 +0000 (17:39 +0200)]
Various plugins: Set the cURL option "CURLOPT_NOSIGNAL".

This fixes problems with version 7.21.2 (and later) of libcurl that are due to
collectd being a multi-threaded program.

Signed-off-by: Florian Forster <octo@collectd.org>
13 years agocollectd-nagios: Sort LISTVAL output.
Sebastian Harl [Mon, 16 May 2011 13:08:41 +0000 (15:08 +0200)]
collectd-nagios: Sort LISTVAL output.

Also, output the data for each host in a separate "section", printing the
hostname as the heading and leaving it out from any further output.

This way, the strings may directly be used as options for -H and -n.

13 years agolibcollectdclient: Added `lcc_sort_identifiers()'.
Sebastian Harl [Mon, 16 May 2011 13:07:18 +0000 (15:07 +0200)]
libcollectdclient: Added `lcc_sort_identifiers()'.

This function may be used to sort an array of lcc_identifier_t objects.

13 years agocollectd-nagios: Select a single host in LISTVAL output when -H has been used.
Sebastian Harl [Mon, 16 May 2011 12:43:34 +0000 (14:43 +0200)]
collectd-nagios: Select a single host in LISTVAL output when -H has been used.

13 years agocollectd-nagios: Let '-n LIST' list all available datasets.
Sebastian Harl [Mon, 16 May 2011 12:39:53 +0000 (14:39 +0200)]
collectd-nagios: Let '-n LIST' list all available datasets.

13 years agosrc/meta_data.c: Free a leaking mutex.
Rafal Lesniak [Fri, 13 May 2011 15:15:54 +0000 (17:15 +0200)]
src/meta_data.c: Free a leaking mutex.

This problem primarily manifested on FreeBSD but may well effect other
systems as well.

Thanks to Tomas Krasnican for reporting this problem.

Signed-off-by: Florian Forster <octo@collectd.org>
13 years agodf plugin: Improve error message.
Florian Forster [Mon, 9 May 2011 21:36:17 +0000 (23:36 +0200)]
df plugin: Improve error message.

13 years agocontrib/migrate-4-5.px: "df" does not have COUNTER DSTs.
Florian Forster [Wed, 27 Apr 2011 15:29:33 +0000 (17:29 +0200)]
contrib/migrate-4-5.px: "df" does not have COUNTER DSTs.

13 years agopf plugin: dont reinvent code, use code from pfctl
Stefan Rinkes [Mon, 25 Apr 2011 16:13:09 +0000 (18:13 +0200)]
pf plugin: dont reinvent code, use code from pfctl

13 years agopf plugin: cleaner error-handling
Stefan Rinkes [Mon, 25 Apr 2011 14:46:04 +0000 (16:46 +0200)]
pf plugin: cleaner error-handling

13 years agocontrib/migrate-4-5.px: Remove useless "OutDir" option.
Florian Forster [Sat, 23 Apr 2011 15:31:08 +0000 (08:31 -0700)]
contrib/migrate-4-5.px: Remove useless "OutDir" option.

13 years agopf plugin: define generation new/old depend on OpenBSD Version
Stefan Rinkes [Fri, 22 Apr 2011 11:04:43 +0000 (13:04 +0200)]
pf plugin: define generation new/old depend on OpenBSD Version

13 years agopf plugin: some code cleanup
Stefan Rinkes [Thu, 21 Apr 2011 19:30:04 +0000 (21:30 +0200)]
pf plugin: some code cleanup

13 years agopf plugin: collect bytes and packets for in and out
Stefan Rinkes [Tue, 19 Apr 2011 06:20:49 +0000 (08:20 +0200)]
pf plugin: collect bytes and packets for in and out

13 years agopf plugin: all types in a single types.db
Stefan Rinkes [Sun, 17 Apr 2011 11:14:11 +0000 (13:14 +0200)]
pf plugin: all types in a single types.db

13 years agopf plugin: also support OpenBSD 4.9/Current
Stefan Rinkes [Sun, 17 Apr 2011 11:08:49 +0000 (13:08 +0200)]
pf plugin: also support OpenBSD 4.9/Current

13 years agopf plugin: read permissions are enough for /dev/pf
Stefan Rinkes [Sun, 17 Apr 2011 09:14:07 +0000 (11:14 +0200)]
pf plugin: read permissions are enough for /dev/pf

13 years agopf plugin: split up in GAUGE and COUNTER
Stefan Rinkes [Sun, 17 Apr 2011 08:07:06 +0000 (10:07 +0200)]
pf plugin:  split up in GAUGE and COUNTER

13 years agopf plugin: add nat and rdr rules
Stefan Rinkes [Sat, 16 Apr 2011 22:53:28 +0000 (00:53 +0200)]
pf plugin: add nat and rdr rules

13 years agopf plugin: add more advanced pfrule-plugin
Stefan Rinkes [Sat, 16 Apr 2011 21:59:59 +0000 (23:59 +0200)]
pf plugin: add more advanced pfrule-plugin

Use rulestring as identifier, e.g
 bytes-block-drop-in-on-lo0-proto-icmp-all.rrd

Currently for OpenBSD 4.5 only.
OpenBSD 4.9/Current follows.

13 years agopf plugin: pfutils depends on system version
Stefan Rinkes [Sat, 16 Apr 2011 18:59:59 +0000 (20:59 +0200)]
pf plugin: pfutils depends on system version

13 years agopf plugin: copy print_rule from /usr/src/sbin/pfctl to pfutils
Stefan Rinkes [Sat, 16 Apr 2011 18:42:38 +0000 (20:42 +0200)]
pf plugin: copy print_rule from /usr/src/sbin/pfctl to pfutils

13 years agopf plugin: whitos cleanup and close dev after reading rules
Stefan Rinkes [Sat, 16 Apr 2011 10:06:22 +0000 (12:06 +0200)]
pf plugin: whitos cleanup and close dev after reading rules

13 years agopf plugin: add very simple rule monitoring
Stefan Rinkes [Sat, 16 Apr 2011 09:06:56 +0000 (11:06 +0200)]
pf plugin: add very simple rule monitoring

13 years agopf plugin: whitespace cleanup
Stefan Rinkes [Thu, 14 Apr 2011 20:08:53 +0000 (22:08 +0200)]
pf plugin: whitespace cleanup

13 years agopf plugin: pf values are GAUGE Part II
Stefan Rinkes [Thu, 14 Apr 2011 19:59:40 +0000 (21:59 +0200)]
pf plugin: pf values are GAUGE Part II

13 years agopf plugin: pf values are GAUGE
Stefan Rinkes [Thu, 14 Apr 2011 19:51:44 +0000 (21:51 +0200)]
pf plugin: pf values are GAUGE

13 years agopf plugin: add myself to copyright
Stefan Rinkes [Thu, 14 Apr 2011 19:22:21 +0000 (21:22 +0200)]
pf plugin: add myself to copyright

13 years agopf plugin: add types.db for pf-types
Stefan Rinkes [Thu, 14 Apr 2011 19:18:10 +0000 (21:18 +0200)]
pf plugin: add types.db for pf-types

13 years agopf plugin: whitespace cleanup and use sstrncpy like other plugins
Stefan Rinkes [Thu, 14 Apr 2011 19:17:45 +0000 (21:17 +0200)]
pf plugin: whitespace cleanup and use sstrncpy like other plugins

13 years agopf plugin: init commit - import pf.c from pyr@openbsd.org
Stefan Rinkes [Thu, 14 Apr 2011 15:47:35 +0000 (17:47 +0200)]
pf plugin: init commit - import pf.c from pyr@openbsd.org

13 years agoiptables plugin: Remove the shipped version of libiptc.
Florian Forster [Sun, 3 Apr 2011 16:17:26 +0000 (09:17 -0700)]
iptables plugin: Remove the shipped version of libiptc.

Since libiptc is now publicly available as a shared library, we don't really
have any need to ship it with collectd anymore.

13 years agonotify_desktop plugin: Add compatibility code for libnotify 0.7.
Samuli Suominen [Mon, 28 Mar 2011 00:16:33 +0000 (02:16 +0200)]
notify_desktop plugin: Add compatibility code for libnotify 0.7.

The current code in src/notify_desktop.c is not compatible with the new
libnotify 0.7 API

This:

  notification = notify_notification_new (summary, n->message, NULL, NULL);

Should now be:

  notification = notify_notification_new (summary, n->message, NULL;

As in, one argument less for notify_notification_new.

But we can't just remove it or it'll break compability with libnotify
0.4.x and 0.5.x.

This piece of code sets dummy NOTIFY_CHECK_VERSION for libnotify-0.4.x,
because NOTIFY_CHECK_VERSION was added only in 0.5.x:

  #ifndef NOTIFY_CHECK_VERSION
  #define NOTIFY_CHECK_VERSION(x,y,z) 0
  #endif

Then we can freely use NOTIFY_CHECK_VERSION, and it will work with all
of 0.4, 0.5 and 0.7 series:

  #if NOTIFY_CHECK_VERSION (0, 7, 0)
  do something cool
  #endif

I'm attaching the working patch.  It's been tested with all of the
mentioned versions, as well as it's in active use at Gentoo Linux.

Thanks, Samuli

Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years agosrc/collectd.h: Define "_Bool" to "int" if the C compiler doesn't know the type.
Florian Forster [Sun, 27 Mar 2011 18:58:40 +0000 (11:58 -0700)]
src/collectd.h: Define "_Bool" to "int" if the C compiler doesn't know the type.

13 years agoMerge branch 'collectd-5.0'
Florian Forster [Sun, 27 Mar 2011 17:06:47 +0000 (10:06 -0700)]
Merge branch 'collectd-5.0'

13 years agoChangeLog: Add release date. collectd-5.0.0
Florian Forster [Sun, 27 Mar 2011 16:31:22 +0000 (09:31 -0700)]
ChangeLog: Add release date.

13 years agoMerge branch 'collectd-4.10' into collectd-5.0
Florian Forster [Sat, 26 Mar 2011 18:01:26 +0000 (11:01 -0700)]
Merge branch 'collectd-4.10' into collectd-5.0

Conflicts:
ChangeLog
src/libvirt.c
src/plugin.c
src/plugin.h
version-gen.sh

13 years agoBump version to 4.10.3; Update ChangeLog. collectd-4.10.3
Florian Forster [Sat, 26 Mar 2011 16:00:17 +0000 (09:00 -0700)]
Bump version to 4.10.3; Update ChangeLog.

13 years agoMerge branch 'collectd-4.9' into collectd-4.10
Florian Forster [Sat, 26 Mar 2011 15:53:22 +0000 (08:53 -0700)]
Merge branch 'collectd-4.9' into collectd-4.10

Conflicts:
ChangeLog
version-gen.sh

13 years agoBump version to 4.9.5; Update ChangeLog. collectd-4.9.5
Florian Forster [Fri, 25 Mar 2011 15:39:17 +0000 (08:39 -0700)]
Bump version to 4.9.5; Update ChangeLog.

13 years agolibvirt plugin: Correctly check the status code of virDomainGetVcpus().
Florian Forster [Sat, 19 Mar 2011 14:43:41 +0000 (15:43 +0100)]
libvirt plugin: Correctly check the status code of virDomainGetVcpus().

The status code is less than zero on failure and the number of vCPUs
otherwise. Thanks to "JLPC" for pointing this problem out.

13 years agoFix compilation error with plugin_register_shutdown
Bruno Prémont [Fri, 18 Mar 2011 07:24:40 +0000 (08:24 +0100)]
Fix compilation error with plugin_register_shutdown

Compiling collectd-4.10.2 on an OpenSuSE 11.3 system causes the
following error:
  snmp.c: In function ‘module_register’:
  snmp.c:1620:3: error: passing argument 1 of ‘plugin_register_shutdown’ discards qualifiers from pointer target type
  plugin.h:275:5: note: expected ‘char *’ but argument is of type ‘const char *’

Convert plugin_register_shutdown's name argument from 'char *' to
'const char *' in order to match the other plugin_register_*
functions.

Signed-off-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years ago.gitignore: Added collectdctl.
Sebastian Harl [Thu, 12 Aug 2010 20:12:47 +0000 (22:12 +0200)]
.gitignore: Added collectdctl.

13 years agoMerge branch 'collectd-4.10' into collectd-5.0
Florian Forster [Mon, 14 Mar 2011 19:08:24 +0000 (20:08 +0100)]
Merge branch 'collectd-4.10' into collectd-5.0

13 years agoMerge branch 'collectd-4.9' into collectd-4.10
Florian Forster [Mon, 14 Mar 2011 19:06:53 +0000 (20:06 +0100)]
Merge branch 'collectd-4.9' into collectd-4.10

13 years agodispatch proper values in Python write plugin
Gregory Szorc [Sat, 5 Mar 2011 06:25:45 +0000 (22:25 -0800)]
dispatch proper values in Python write plugin

Fixes the Python write callback so the appropriate value is dispatched to
Python. Previously, the code only looked at the first element of a data set
to determine which value type (GAUGE, COUNTER, etc) to dispatch. If your data
set consisted of multiple values of different types, then the Python write
plugin was receiving bad values for the elements at position n > 0 whose type
was not the same as that at position 0.

13 years agosnmp plugin: Improve error message.
Florian Forster [Tue, 8 Mar 2011 20:28:36 +0000 (21:28 +0100)]
snmp plugin: Improve error message.

Go to some length to make it possible to display the name of the
<host /> and <data /> block when complaining about an unknown ASN type.

13 years agoRemoved bogus checking in ut_config.
Andres J. Diaz [Tue, 1 Mar 2011 16:25:22 +0000 (17:25 +0100)]
Removed bogus checking in ut_config.

Since threshold is a plugin, the main config block (<Plugin "threshold">)
cannot contain only one keyword (as was mandatory in previous versions),
so checking must be removed.

Signed-off-by: Andres J. Diaz <ajdiaz@connectical.com>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years agoFix buffer length in parse_identifier_vl function.
Andres J. Diaz [Tue, 1 Mar 2011 16:25:21 +0000 (17:25 +0100)]
Fix buffer length in parse_identifier_vl function.

In parse_identifier_vl function (common.c), the value passed to
sstrncpy as buffer length is the sizeof a char pointer, which
is 4bytes for 32bit arch and 8bytes for 64 bit ones.

This patch fix the length and truncate the buffer to the same size as
destination buffer.

Signed-off-by: Andres J. Diaz <ajdiaz@connectical.com>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years agoRemoved bogus checking in ut_config.
Andres J. Diaz [Tue, 1 Mar 2011 16:25:22 +0000 (17:25 +0100)]
Removed bogus checking in ut_config.

Since threshold is a plugin, the main config block (<Plugin "threshold">)
cannot contain only one keyword (as was mandatory in previous versions),
so checking must be removed.

Signed-off-by: Andres J. Diaz <ajdiaz@connectical.com>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years agoFix buffer length in parse_identifier_vl function.
Andres J. Diaz [Tue, 1 Mar 2011 16:25:21 +0000 (17:25 +0100)]
Fix buffer length in parse_identifier_vl function.

In parse_identifier_vl function (common.c), the value passed to
sstrncpy as buffer length is the sizeof a char pointer, which
is 4bytes for 32bit arch and 8bytes for 64 bit ones.

This patch fix the length and truncate the buffer to the same size as
destination buffer.

Signed-off-by: Andres J. Diaz <ajdiaz@connectical.com>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years agoprocesses plugin: Call kvm_close() after kvm_geterr().
Florian Forster [Tue, 8 Mar 2011 08:36:13 +0000 (09:36 +0100)]
processes plugin: Call kvm_close() after kvm_geterr().

13 years agocollectd.conf(5): Mention MySQL privileges required for repl stats.
Sebastian Harl [Tue, 22 Feb 2011 09:17:46 +0000 (10:17 +0100)]
collectd.conf(5): Mention MySQL privileges required for repl stats.

13 years agocollectd.conf(5): Be more verbose about how to access a notification daemon.
Sebastian Harl [Tue, 7 Sep 2010 20:03:54 +0000 (22:03 +0200)]
collectd.conf(5): Be more verbose about how to access a notification daemon.

13 years agofilter_chain: Use a complaint to report plugin_write()'s ENOENT error.
Sebastian Harl [Tue, 7 Sep 2010 19:45:44 +0000 (21:45 +0200)]
filter_chain: Use a complaint to report plugin_write()'s ENOENT error.

In most cases this is a permanent error, so using the complain mechanism
avoids spamming the logs.

13 years agosrc/plugin.c: Print a more verbose error message if lt_dlopen() fails.
Florian Forster [Wed, 9 Feb 2011 06:28:03 +0000 (07:28 +0100)]
src/plugin.c: Print a more verbose error message if lt_dlopen() fails.

Since the Debian package doesn't depend on the libraries used by the
collectd plugins, some plugins may fail to load. ltdl reports this with
the very confusing error message "file not found". Since the plugin is
in fact available, many users don't realize a dependency is missing and
assume collectd is looking in the wrong directory -- and they are hardly
to blame for this.

This commit introduces a lengthy error message which hopefully points
users into the right direction.

13 years agocontrib/collection3: Set @INC at runtime, too.
Florian Forster [Tue, 8 Feb 2011 15:43:22 +0000 (16:43 +0100)]
contrib/collection3: Set @INC at runtime, too.

Apparently the @INC variable is reset by mod_perl, which
causes later require()s to fail.

13 years agocontrib/collection3: Add basic compatibility to mod_perl.
Florian Forster [Tue, 8 Feb 2011 10:14:19 +0000 (11:14 +0100)]
contrib/collection3: Add basic compatibility to mod_perl.

Some data is cached between requests, which may increase
performance, especially if different timespans of the same
graph are requested.

13 years agoswap plugin: Declare swap_submit_derive() only on Linux.
Florian Forster [Mon, 7 Feb 2011 13:42:17 +0000 (14:42 +0100)]
swap plugin: Declare swap_submit_derive() only on Linux.

13 years agoChangeLog: Fix typo.
Florian Forster [Mon, 7 Feb 2011 08:02:35 +0000 (09:02 +0100)]
ChangeLog: Fix typo.

13 years agoMerge branch 'collectd-5.0'
Florian Forster [Mon, 7 Feb 2011 07:47:44 +0000 (08:47 +0100)]
Merge branch 'collectd-5.0'

13 years agoMerge branch 'collectd-4.10' into collectd-5.0
Florian Forster [Mon, 7 Feb 2011 07:47:35 +0000 (08:47 +0100)]
Merge branch 'collectd-4.10' into collectd-5.0

13 years agoMerge branch 'collectd-4.9' into collectd-4.10
Florian Forster [Mon, 7 Feb 2011 07:47:18 +0000 (08:47 +0100)]
Merge branch 'collectd-4.9' into collectd-4.10

13 years agoMerge remote branch 'origin/ff/modbus'
Florian Forster [Mon, 7 Feb 2011 07:46:04 +0000 (08:46 +0100)]
Merge remote branch 'origin/ff/modbus'

13 years agoMerge branch 'ff/flush-rrdcached'
Florian Forster [Mon, 7 Feb 2011 07:42:22 +0000 (08:42 +0100)]
Merge branch 'ff/flush-rrdcached'

13 years agoMerge branch 'ff/swap'
Florian Forster [Mon, 7 Feb 2011 07:42:05 +0000 (08:42 +0100)]
Merge branch 'ff/swap'

13 years agoexec plugin: Remove useless preprocessor stuff.
Florian Forster [Mon, 7 Feb 2011 07:31:37 +0000 (08:31 +0100)]
exec plugin: Remove useless preprocessor stuff.

13 years agoMerge branch 'pw/exclude_regex'
Florian Forster [Mon, 7 Feb 2011 07:00:31 +0000 (08:00 +0100)]
Merge branch 'pw/exclude_regex'

13 years agovarnish plugin: Use a DERIVE type for allocated and free bytes.
Florian Forster [Mon, 7 Feb 2011 06:40:22 +0000 (07:40 +0100)]
varnish plugin: Use a DERIVE type for allocated and free bytes.

Each event is counted, so storing a GAUGE is not the right thing to do.
Thanks to Renaud Chaput for pointing this out.

N.B.: The total amount of allocated memory is tracked by
"bytes-outstanding" for many storage backends.

13 years agosrc/collectd.conf.in: Remove the "TranslateDevicename" option from the "hddtemp"...
Florian Forster [Fri, 4 Feb 2011 20:37:49 +0000 (21:37 +0100)]
src/collectd.conf.in: Remove the "TranslateDevicename" option from the "hddtemp" plugin.

13 years agosrc/common.c: Include <netinet/in.h> before <arpa/inet.h>.
Florian Forster [Thu, 3 Feb 2011 22:42:28 +0000 (23:42 +0100)]
src/common.c: Include <netinet/in.h> before <arpa/inet.h>.

13 years agoteamspeak2 plugin: Include <netinet/in.h> before <arpa/inet.h>.
Florian Forster [Thu, 3 Feb 2011 07:42:39 +0000 (08:42 +0100)]
teamspeak2 plugin: Include <netinet/in.h> before <arpa/inet.h>.

13 years agorrdcached plugin: Pass FLUSHes on to the caching daemon.
Florian Forster [Wed, 2 Feb 2011 14:07:26 +0000 (15:07 +0100)]
rrdcached plugin: Pass FLUSHes on to the caching daemon.

13 years agoconfigure.in: Using sysctl(3) for swap statistics is only possible under Mac OS X.
Florian Forster [Wed, 2 Feb 2011 13:25:32 +0000 (14:25 +0100)]
configure.in: Using sysctl(3) for swap statistics is only possible under Mac OS X.

13 years agoconfigure.in: Fix (de)activation of the Swap plugin for OpenBSD.
Florian Forster [Wed, 2 Feb 2011 10:31:58 +0000 (11:31 +0100)]
configure.in: Fix (de)activation of the Swap plugin for OpenBSD.

13 years agontpd plugin: Report failures of "ntpd_do_query" as *errors*, not debug messages.
Florian Forster [Fri, 28 Jan 2011 08:18:16 +0000 (09:18 +0100)]
ntpd plugin: Report failures of "ntpd_do_query" as *errors*, not debug messages.

13 years agoMySQL plugin: Update copyright header.
Florian Forster [Tue, 25 Jan 2011 06:53:49 +0000 (07:53 +0100)]
MySQL plugin: Update copyright header.

13 years agosrc/configfile.[ch]: Update copyright header.
Florian Forster [Tue, 25 Jan 2011 06:48:45 +0000 (07:48 +0100)]
src/configfile.[ch]: Update copyright header.

13 years agosrc/configfile.c: cf_util_get_port_number: Gracefully handle number arguments as...
Florian Forster [Tue, 25 Jan 2011 06:42:53 +0000 (07:42 +0100)]
src/configfile.c: cf_util_get_port_number: Gracefully handle number arguments as well.

Why force the user into using strings when it's not strictly
necessary..?

13 years agosrc/utils_threshold.c: Fix creation of percentage notifications.
Florian Forster [Thu, 13 Jan 2011 07:57:24 +0000 (08:57 +0100)]
src/utils_threshold.c: Fix creation of percentage notifications.

Joey Hess has reported a problem when creating notifications from
percentage thresholds. Because the (percentage) minimum value is
compared to the (raw) DS value, the following message is possible:

  Message: Host XXX, plugin df type df (instance root): Data source
  "free" is currently 1773072384.000000. That is above the warning
  threshold of nan%.

A new section will handle this case correctly. In the inverted case, the
problem should not exist.

13 years agosrc/plugin.c: Free allocated data if plugin_insert_read() fails.
Florian Forster [Tue, 11 Jan 2011 08:06:58 +0000 (09:06 +0100)]
src/plugin.c: Free allocated data if plugin_insert_read() fails.

13 years agosrc/plugin.c: Move the error-checking code up.
Florian Forster [Tue, 11 Jan 2011 07:57:08 +0000 (08:57 +0100)]
src/plugin.c: Move the error-checking code up.

This way the error message is much closer to the check and we save one
level of indentation for the "good" code.

13 years agoplugin.c: prevent re-adding read functions
Blaise Tarr [Mon, 10 Jan 2011 22:15:47 +0000 (17:15 -0500)]
plugin.c: prevent re-adding read functions

When multiple LoadPlugin options are used with a plugin, the plugin is
only loaded once, however the plugin's read function is invoked
multiple times at every interval. This in turn causes undesired
redundant data to be sent to the write plugins.

This patch prevents a plugin's read function from being re-added to
the read_heap and read_list during plugin registration.

Signed-off-by: Blaise Tarr <blaise.tarr@gmail.com>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
13 years agoswap plugin: Implement the "ReportByDevice" for Linux.
Florian Forster [Sat, 8 Jan 2011 15:57:56 +0000 (16:57 +0100)]
swap plugin: Implement the "ReportByDevice" for Linux.

13 years agoconfigure.in: Unify status output.
Florian Forster [Sat, 8 Jan 2011 08:54:40 +0000 (09:54 +0100)]
configure.in: Unify status output.

13 years agolibcollectdclient: Remove the "nonnull" attribute.
Florian Forster [Sat, 8 Jan 2011 08:36:08 +0000 (09:36 +0100)]
libcollectdclient: Remove the "nonnull" attribute.

Some old versions of GCC don't know it and throw a warning.

13 years agolibcollectdclient: Remove lcc_strdup().
Florian Forster [Sat, 8 Jan 2011 08:32:57 +0000 (09:32 +0100)]
libcollectdclient: Remove lcc_strdup().

We use XSI anyway, so why go there?

13 years agosrc/utils_dns.c: Make IPv6 support optional.
Florian Forster [Fri, 7 Jan 2011 07:28:32 +0000 (08:28 +0100)]
src/utils_dns.c: Make IPv6 support optional.