exec plugin: Removed whitespaces at EOL.
exec plugin: Separate stdout and stderr.
Hi!
Digitemp sends errors to stderr, but collectd handles stdout and stderr
as the same and reports parsing errors.
My idea is to seperate stdout and stderr.
I also removed the special pipe handling checking for stdin...
because exec plugin will alway have a fd > 2 for pipes !!
(fd 0,1 and 2 (stdin, stdout, stderr) are used by collectd with /dev/null if demonized)
now strings from stderr will be reportet by ERROR
cu Peter
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Hi!
Digitemp sends errors to stderr, but collectd handles stdout and stderr
as the same and reports parsing errors.
My idea is to seperate stdout and stderr.
I also removed the special pipe handling checking for stdin...
because exec plugin will alway have a fd > 2 for pipes !!
(fd 0,1 and 2 (stdin, stdout, stderr) are used by collectd with /dev/null if demonized)
now strings from stderr will be reportet by ERROR
cu Peter
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
ipmi plugin: Add ignorelist functionality.
ipmi plugin: Improve error messages when removing a sensor.
Don't tell the user to file a bug report, when a sensor is removed because IPMI
reported an error. Tell him to file a bug report, though, if collectd doesn't
know how to handle the value.
Don't tell the user to file a bug report, when a sensor is removed because IPMI
reported an error. Tell him to file a bug report, though, if collectd doesn't
know how to handle the value.
16 years agoipmi plugin: Add a stupi bug which prevented basically all sensors from being collected.
ipmi plugin: Add a stupi bug which prevented basically all sensors from being collected.
src/collectd.conf.in: Added a `LoadPlugin' line for the ipmi plugin.
configure.in: Add the OpenIPMI library to the status output.
Merge branch 'collectd-4.3'
Merge branch 'collectd-4.2' into collectd-4.3
COPYING: Added the file (including the GPLv2).
Newer versions of automake copy the GPLv3 when invoked with ``--add-missing''
which is not what we want.
Newer versions of automake copy the GPLv3 when invoked with ``--add-missing''
which is not what we want.
ipmi plugin: Add a plugin to read sensor values via IPMI.
The plugin is very basic and still basically alpha quality. You cannot
configure anything yet, neither where to connect to (the local, SMI connection
is used right now) nor what sensors to collect (collects all it can make sense
of). I hope to be able to do that on friday or some other workday in the near
future.
The plugin is very basic and still basically alpha quality. You cannot
configure anything yet, neither where to connect to (the local, SMI connection
is used right now) nor what sensors to collect (collects all it can make sense
of). I hope to be able to do that on friday or some other workday in the near
future.
Merge branch 'collectd-4.3'
Merge branch 'collectd-4.2' into collectd-4.3
Conflicts:
configure.in
src/plugin.c
Conflicts:
configure.in
src/plugin.c
unixsock plugin: Do not unregister a write-callback in us_shutdown().
The unixsock plugin no longer registers a write-callback. Basically,
unregistering a non-existent callback does not do any harm, However, if no
write-callback has been registered at all, the appropriate linked list has
never been created and the process will segfault when trying to access it.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
The unixsock plugin no longer registers a write-callback. Basically,
unregistering a non-existent callback does not do any harm, However, if no
write-callback has been registered at all, the appropriate linked list has
never been created and the process will segfault when trying to access it.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configure.in: Set CPPFLAGS when checking headers.
When checking for <upsclient.h> (and the headers of a few other libraries) the
library specific CFLAGS were added to the global CFLAGS variable. This variable
is used when checking for ``header usability'', but not when checking for
``header presence'' for some reason.
This commit uses the global CPPFLAGS variable instead, which is used in both
checks. Libraries that benefit from this commit are:
- libcurl,
- libmysql(client),
- libnetsnmp,
- libupsclient.
Resolves #6
When checking for <upsclient.h> (and the headers of a few other libraries) the
library specific CFLAGS were added to the global CFLAGS variable. This variable
is used when checking for ``header usability'', but not when checking for
``header presence'' for some reason.
This commit uses the global CPPFLAGS variable instead, which is used in both
checks. Libraries that benefit from this commit are:
- libcurl,
- libmysql(client),
- libnetsnmp,
- libupsclient.
Resolves #6
apache plugin: Increase the size of the read-buffer dynamically.
Why guess the size if you can just adapt to whatever comes in? The memory isn't
freed ever, though.
Why guess the size if you can just adapt to whatever comes in? The memory isn't
freed ever, though.
src/plugin.c: plugin_dispatch_values: Improve the error messages.
If no write plugin was loaded or no DS was defined, the
`plugin_dispatch_values' used to fail silently. This is of course not good, so
this commit introduces error messages for this case, so that users can see why
their setup is not working properly.
Also, the ``no such DS type'' message was promoted from DEBUG to INFO.
If no write plugin was loaded or no DS was defined, the
`plugin_dispatch_values' used to fail silently. This is of course not good, so
this commit introduces error messages for this case, so that users can see why
their setup is not working properly.
Also, the ``no such DS type'' message was promoted from DEBUG to INFO.
src/common.c: Make really sure BYTE_ORDER and BIG_ENDIAN are defined.
If both, BYTE_ORDER and BIG_ENDIAN, are undefined, the statement
#if BYTE_ORDER == BIG_ENDIAN
will be evaluated to `true', which may cause `ntohll' and `htonll' to behave
weird.
If both, BYTE_ORDER and BIG_ENDIAN, are undefined, the statement
#if BYTE_ORDER == BIG_ENDIAN
will be evaluated to `true', which may cause `ntohll' and `htonll' to behave
weird.
src/utils_tail.c: Call `stat' after reading till the end of file.
The old code used stat(2) to determine if the file was moved and reopened the
file before reading anything. This way lines, that were added to the file
before it was moved, would have been missed. This commit changes that behavior
so that the file is read until EOF and _then_ stat(2) is used to check if the
file has been moved away.
The old code used stat(2) to determine if the file was moved and reopened the
file before reading anything. This way lines, that were added to the file
before it was moved, would have been missed. This commit changes that behavior
so that the file is read until EOF and _then_ stat(2) is used to check if the
file has been moved away.
plugin.c: Tell the user if a plugin could not be found.
Up to now this error was silently ignored, letting the user believe that
everything went fine.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Up to now this error was silently ignored, letting the user believe that
everything went fine.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
collection.cgi: Make sure to pass valid variable names to rrdgraph.
Variable names used with DEF, VDEF, etc. must be made up of the
characters "A-Z, a-z, 0-9, -, _". In meta_graph_generic_stack() variable
names have been generated from the instance name which may, however,
contain illegal characters. Now, all illegal characters will be replaced
with "_" and a number will be prepended to the variable name to make
sure the name is still unique.
Thanks to Joerg Jaspert for pointing this out and helpful debugging
information.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Variable names used with DEF, VDEF, etc. must be made up of the
characters "A-Z, a-z, 0-9, -, _". In meta_graph_generic_stack() variable
names have been generated from the instance name which may, however,
contain illegal characters. Now, all illegal characters will be replaced
with "_" and a number will be prepended to the variable name to make
sure the name is still unique.
Thanks to Joerg Jaspert for pointing this out and helpful debugging
information.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
hddtemp plugin: Prefix all messages with "hddtemp plugin:".
collection.cgi: Added "meta graph" for "dns_qtype" and "dns_rcode".
This will merge all query types and return codes into a single graph each.
get_n_colors() has been taken from the version 3 script to get the colors for
the graphs. get_random_color() imho is not suitable for that purpose as it can
return colors that are hardly different - which would result in graphs that
are hard to read. get_n_colors() now returns a hash-ref suitable to be passed
to meta_graph_generic_stack().
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
This will merge all query types and return codes into a single graph each.
get_n_colors() has been taken from the version 3 script to get the colors for
the graphs. get_random_color() imho is not suitable for that purpose as it can
return colors that are hardly different - which would result in graphs that
are hard to read. get_n_colors() now returns a hash-ref suitable to be passed
to meta_graph_generic_stack().
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
collection.cgi: Added support for "wireless" values.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
rrdtool plugin: Reduce the filesize of files created per default.
When creating an RRD file, the rrdtool plugin doesn't do what it's supposed to
do. Instead of creating 5 RRAs it creates 4 and in doing so it skips the first
one. The result is about 2x the number of datapoints total. The fix below works
for me. It's for 4.2.2 but it looks like this hasn't changed in the latest 4.3
beta.
Resolves: #5
When creating an RRD file, the rrdtool plugin doesn't do what it's supposed to
do. Instead of creating 5 RRAs it creates 4 and in doing so it skips the first
one. The result is about 2x the number of datapoints total. The fix below works
for me. It's for 4.2.2 but it looks like this hasn't changed in the latest 4.3
beta.
Resolves: #5
collection.cgi: Updated "dns" types to version 4.x.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
powerdns plugin: Fixes for the connection handling.
The connection stuff has been fixed to actually work with the daemon. The data
received is not yet handled completely. I'm waiting for feedback from Luke on
that..
References #1
The connection stuff has been fixed to actually work with the daemon. The data
received is not yet handled completely. I'm waiting for feedback from Luke on
that..
References #1
powerdns plugin: Code cleanups.
powerdns plugin: Added a plugin to read statistics from PowerDNS' control socket.
Bumped version to 4.3.2; Updated ChangeLog.
Merge branch 'collectd-4.2' into collectd-4.3
Conflicts:
ChangeLog
version-gen.sh
Conflicts:
ChangeLog
version-gen.sh
Bumped version to 4.2.6
disk plugin: Implement an ignorelist.
Not all disks collected by the disk plugin may be of interest. This commit
implements an ignorelist as provided by src/utils_ignorelist.c to make it
possible to select exactly which instances are interesting and which are not.
Resolves: #3
Not all disks collected by the disk plugin may be of interest. This commit
implements an ignorelist as provided by src/utils_ignorelist.c to make it
possible to select exactly which instances are interesting and which are not.
Resolves: #3
src/utils_ignorelist.c: ignorelist_match: Allow the `ignorelist' to be NULL.
This makes calling the function easier, because initialization of the
ignorelist in the plugin usually depends on configuration parameters..
This makes calling the function easier, because initialization of the
ignorelist in the plugin usually depends on configuration parameters..
ChangeLog: Added changes since 4.2.5.
collectd.conf(5): Document vmem's configuration option.
Also updates src/collectd.conf.in.
Also updates src/collectd.conf.in.
vmem plugin: Add the `Verbose' config option.
All the statistics is just too much for every-day-use ;)
All the statistics is just too much for every-day-use ;)
vmem plugin: Added a plugin to collect virtual memory statistics.
sensors plugin: Simple fix for temperature sensors.
Hi everybody!
While playing with sensors i missed temperature rrd files:
--- sensors.c.orig 2008-03-25 14:58:21.000000000 +0100
+++ sensors.c 2008-03-25 14:58:27.000000000 +0100
@@ -580,7 +580,7 @@
type = "fanspeed";
else if (fl->feature->type
== SENSORS_FEATURE_TEMP)
- type = "input";
+ type = "temperature";
else
continue;
because this type got registered as input and "input" is not in types.db
after configuring with --enable-debug i saw a log:
No such dataset registered: input
should that be also without --enable-debug in my syslog?
cu Peter
Hi everybody!
While playing with sensors i missed temperature rrd files:
--- sensors.c.orig 2008-03-25 14:58:21.000000000 +0100
+++ sensors.c 2008-03-25 14:58:27.000000000 +0100
@@ -580,7 +580,7 @@
type = "fanspeed";
else if (fl->feature->type
== SENSORS_FEATURE_TEMP)
- type = "input";
+ type = "temperature";
else
continue;
because this type got registered as input and "input" is not in types.db
after configuring with --enable-debug i saw a log:
No such dataset registered: input
should that be also without --enable-debug in my syslog?
cu Peter
Merge branch 'collectd-4.3'
Merge branch 'pull/master'
Merge branch 'pull/collectd-4.3' into collectd-4.3
Merge branch 'collectd-4.3'
Conflicts:
src/unixsock.c
Conflicts:
src/unixsock.c
Merge branch 'collectd-4.2' into collectd-4.3
Conflicts:
src/unixsock.c
Conflicts:
src/unixsock.c
unixsock plugin: Open two different IO stream handles for reading and writing.
Full-duplex standard IO streams are not really supported on sockets.
Mixing input and output functions involves calls to lseek(2) which is
not supported on sockets and thus causes the IO operations to fail.
Opening two IO streams solves the problem.
This is a backport of 43df21461d523023951746ef669f1bb95f61366d.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Full-duplex standard IO streams are not really supported on sockets.
Mixing input and output functions involves calls to lseek(2) which is
not supported on sockets and thus causes the IO operations to fail.
Opening two IO streams solves the problem.
This is a backport of 43df21461d523023951746ef669f1bb95f61366d.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
unixsock plugin: Open two different IO stream handles for reading and writing.
Full-duplex standard IO streams are not really supported on sockets.
Mixing input and output functions involves calls to lseek(2) which is
not supported on sockets and thus causes the IO operations to fail.
Opening two IO streams solves the problem.
This is a backport of 43df21461d523023951746ef669f1bb95f61366d.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Full-duplex standard IO streams are not really supported on sockets.
Mixing input and output functions involves calls to lseek(2) which is
not supported on sockets and thus causes the IO operations to fail.
Opening two IO streams solves the problem.
This is a backport of 43df21461d523023951746ef669f1bb95f61366d.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
unixsock plugin: Open two different IO stream handles for reading and writing.
Full-duplex standard IO streams are not really supported on sockets.
Mixing input and output functions involves calls to lseek(2) which is
not supported on sockets and thus causes the IO operations to fail.
Opening two IO streams solves the problem.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Full-duplex standard IO streams are not really supported on sockets.
Mixing input and output functions involves calls to lseek(2) which is
not supported on sockets and thus causes the IO operations to fail.
Opening two IO streams solves the problem.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
contrib/cussh.pl: Fixed input line parsing.
The regexes parsing the user input lines have been adopted to take into
account that the newline at the end of the line has been removed.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
The regexes parsing the user input lines have been adopted to take into
account that the newline at the end of the line has been removed.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
contrib/cussh.pl: Added support for LISTVAL.
Also fixed the following minor problems:
* the arguments passed to Collectd::Unixsock::putval() have been updated
to the current version of the Perl module
* remove newlines from the end of the input line - the unixsock plugin
currently seems to be buggy when receiving two newlines in a row
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Also fixed the following minor problems:
* the arguments passed to Collectd::Unixsock::putval() have been updated
to the current version of the Perl module
* remove newlines from the end of the input line - the unixsock plugin
currently seems to be buggy when receiving two newlines in a row
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Collectd::Unixsock: Fixed some typos.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
utils_cmd_{get,put}val.c: Fixed usage of parse_identifier().
This function modifies its first argument which, in these cases, is used
again after the function call. Now, a copy of the string is passed to
parse_identifier().
This is a backport of 0a905cbd3151716c5749b5e7c5e439861466804d.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
This function modifies its first argument which, in these cases, is used
again after the function call. Now, a copy of the string is passed to
parse_identifier().
This is a backport of 0a905cbd3151716c5749b5e7c5e439861466804d.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
utils_cmd_{get,put}val.c: Fixed usage of parse_identifier().
This function modifies its first argument which, in these cases, is used
again after the function call. Now, a copy of the string is passed to
parse_identifier().
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
This function modifies its first argument which, in these cases, is used
again after the function call. Now, a copy of the string is passed to
parse_identifier().
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
utils_cmd_*: Terminate all lines printed to the socket with newline.
This is a backport of 1ca0b79a4274784e4cc15d45e46e2cfa0c2039cf.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
This is a backport of 1ca0b79a4274784e4cc15d45e46e2cfa0c2039cf.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
utils_cmd_*: Terminate all lines printed to the socket with newline.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Disambiguated the protocol used by the unixsock (and other) plugins.
As discussed with Florian on IRC, the interpretation of the status line
returned by the unixsock plugin (et.al.) is now strictly specified. A status
greater than or equal to zero indicates success and the number of subsequent
lines of output. A negative status still indicates failure.
This way, frontends can manage the output without having to know any
command-specific interpretation rules.
The GETVAL command has been updated to implement this specification. It now
returns each value on a separate line. collectd-unixsock(5) has been updated
to reflect the changes.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
As discussed with Florian on IRC, the interpretation of the status line
returned by the unixsock plugin (et.al.) is now strictly specified. A status
greater than or equal to zero indicates success and the number of subsequent
lines of output. A negative status still indicates failure.
This way, frontends can manage the output without having to know any
command-specific interpretation rules.
The GETVAL command has been updated to implement this specification. It now
returns each value on a separate line. collectd-unixsock(5) has been updated
to reflect the changes.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
utils_cmd_flush.c: Simplified / improved option parsing.
Instead of parsing all options before doing any work, each option is now
handled right after it has been parsed. This has the following benefits:
* No need to allocate and construct any data structures.
* The timeout option may be used multiple times now, only affecting any
plugins listed after this.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Instead of parsing all options before doing any work, each option is now
handled right after it has been parsed. This has the following benefits:
* No need to allocate and construct any data structures.
* The timeout option may be used multiple times now, only affecting any
plugins listed after this.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
collectd-unixsock(5): Updated the paragraph about Collectd::Unixsock.
The module is no longer available in contrib/PerlLib/ but bindings/perl/.
Also it's now installed by default.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
The module is no longer available in contrib/PerlLib/ but bindings/perl/.
Also it's now installed by default.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Merge branch 'collectd-4.3'
Merge branch 'collectd-4.2' into collectd-4.3
liboconfig/parser.y: Enabled verbose error messages.
This uses bison's "%error-verbose" option which might not be available in
other yacc implementations.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
This uses bison's "%error-verbose" option which might not be available in
other yacc implementations.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
liboconfig: Include the filename in error messages.
As collectd now supports more than one config file, this is more
convenient.
A module-global variable is used for that purpose. If no filename is
available (e.g. if the user uses oconfig_parse_fh() directly), a string
like "<fd#X>" is used instead, where X is replaced by the file descriptor.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
As collectd now supports more than one config file, this is more
convenient.
A module-global variable is used for that purpose. If no filename is
available (e.g. if the user uses oconfig_parse_fh() directly), a string
like "<fd#X>" is used instead, where X is replaced by the file descriptor.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
perl plugin: Updated copyright information.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
collectd-unixsock(5): Fixed some typos.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
utils_cmd_flush.c: Terminate all lines printed to the socket with a newline.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
collectd-unixsock(5): Be more specific which time `LISTVAL' returns.
The timestamp of the last value and the time at which the last value was
received may differ..
The timestamp of the last value and the time at which the last value was
received may differ..
unixsock plugin: Use `src/utils_cmd_listval.[ch]' and remove the local cache.
Since no command uses the cache in the unixsock plugin anymore, it can be
removed. The implementation in `src/utils_cache.[ch]' is now used for all
commands, and all commands are in separate modules. This should be a
performance gain, since the implementation of unixsock used a linked list,
which is much slower than the AVL tree used in the global cache.
Also this resolves a nasty bug: The unixsock plugin used to use the _local_
interval setting when removing values from the cache. The global cache uses the
interval setting of the values themselves, to that mixing different intervals
in a big setup is now compatible with the `listval' and other commands.
Since no command uses the cache in the unixsock plugin anymore, it can be
removed. The implementation in `src/utils_cache.[ch]' is now used for all
commands, and all commands are in separate modules. This should be a
performance gain, since the implementation of unixsock used a linked list,
which is much slower than the AVL tree used in the global cache.
Also this resolves a nasty bug: The unixsock plugin used to use the _local_
interval setting when removing values from the cache. The global cache uses the
interval setting of the values themselves, to that mixing different intervals
in a big setup is now compatible with the `listval' and other commands.
src/utils_cmd_listval.[ch]: Added a new module which implements the `LISTVAL' command.
It's done using the global cache implemented in `src/utils_cache.[ch]'.
It's done using the global cache implemented in `src/utils_cache.[ch]'.
src/utils_cache.[ch]: Improved the `uc_get_names' to return the times, too.
src/utils_cache.[ch]: Add `uc_get_names', a function to return all keys in the cache.
sensors plugin: Print information why a specific feature is ignored in debug mode.
As requested by Ondřej Válek.
As requested by Ondřej Válek.
wireless plugin: Fix reading the noise value.
Accidentally the wrong value was used as `noise'. This patch fixes it.
Thanks to Ondřej Válek for pointing this out.
Accidentally the wrong value was used as `noise'. This patch fixes it.
Thanks to Ondřej Válek for pointing this out.
build.sh: Use glibtoolize if it's available.
This way, the script should work on e.g. MacOSX as well.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
This way, the script should work on e.g. MacOSX as well.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configure: Do not preset $with_libstatgrab and $with_libdevstat.
Those variables are set when parsing the command line options and evaluated
inside the AC_ARG_WITH() macro. Presetting them overwrites any command line
options.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Those variables are set when parsing the command line options and evaluated
inside the AC_ARG_WITH() macro. Presetting them overwrites any command line
options.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
contrib/redhat/collectd.spec: Updated the description of the package.
Also updated the packager and vendor fields and added the redhat/ subdirectory
to contrib/README.
Also updated the packager and vendor fields and added the redhat/ subdirectory
to contrib/README.
contrib/redhat/: Added a spec file and affiliated config files.
src/utils_cache.c: Fix a bug that was introduced by the preceding merge.
Merge branch 'collectd-4.3'
Conflicts:
src/utils_cache.c
Conflicts:
src/utils_cache.c
Merge branch 'collectd-4.2' into collectd-4.3
collectd(1): Document the supported signals.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
perl plugin: Fixed the "EnableDebugger after LoadPlugin" warning.
For some strange reason my original patch (perl plugin: Warn if
"EnableDebugger" has been used after "LoadPlugin".) has been applied at the
wrong position (it has been applied to perl_config_includedir() instead of
perl_config_enabledebugger() - I have absolutely no clue why though).
Also, the check for the precondition of this warning has been fixed. In some
cases aTHX does not seem to be set, even though the Perl interpreter has
already been initialized. Now, perl_threads is used to check for that
condition.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
For some strange reason my original patch (perl plugin: Warn if
"EnableDebugger" has been used after "LoadPlugin".) has been applied at the
wrong position (it has been applied to perl_config_includedir() instead of
perl_config_enabledebugger() - I have absolutely no clue why though).
Also, the check for the precondition of this warning has been fixed. In some
cases aTHX does not seem to be set, even though the Perl interpreter has
already been initialized. Now, perl_threads is used to check for that
condition.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configfile.c: Include more than one files in lexicographical order.
Using qsort() and strcmp() the list of files (after reading the contents
of a directory or expanding globs) is sorted before inclusion. As the
order of options in the config file matters this is more convenient.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Using qsort() and strcmp() the list of files (after reading the contents
of a directory or expanding globs) is sorted before inclusion. As the
order of options in the config file matters this is more convenient.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
liboconfig/oconfig.c: Free all allocated memory in oconfig_free().
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configfile.c: Abort if any config file could not be read.
So far, when including all files from some directory, errors while reading
any of those config files have been reported but otherwise ignored. So,
collectd would run with some potentially incomplete configuration which is
not what I would expect.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
So far, when including all files from some directory, errors while reading
any of those config files have been reported but otherwise ignored. So,
collectd would run with some potentially incomplete configuration which is
not what I would expect.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configfile.c: Fixed a memory leak in cf_read_generic().
In case stat(2) failed, the memory allocated for the return value has not
been freed.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
In case stat(2) failed, the memory allocated for the return value has not
been freed.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configfile.c: Fixed a segfault after a parse error.
In cf_read_generic(), the parse result had not been checked to not be
NULL, which caused a segfault when trying to access any of its members.
Now, an error will be returned in that case.
Also, cf_ci_append_children() has been made more robust in that respect.
It now detects an empty source and does nothing in that case.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
In cf_read_generic(), the parse result had not been checked to not be
NULL, which caused a segfault when trying to access any of its members.
Now, an error will be returned in that case.
Also, cf_ci_append_children() has been made more robust in that respect.
It now detects an empty source and does nothing in that case.
Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
AUTHORS: Speak about `plugins', not `modules'.
Also sorted the plugins and put them all before any other patches.
Also sorted the plugins and put them all before any other patches.
Merge branch 'pull/collectd-4.3' into collectd-4.3
src/utils_{cache,threshold}.c: Fix the concept of failed and missing values.
Apparently I was confused at the time - and still am ;)
Apparently I was confused at the time - and still am ;)
Merge branch 'pull/collectd-4.3' into collectd-4.3
src/utils_cache.c: Fix the handling of `Persist'.
And reorganized/cleaned up the code a bit.
And reorganized/cleaned up the code a bit.
contrib/rrd_filter.px: Added the ability to add (empty) data sources.
src/{mbmon,plugin,unixsock}.c: Simple fixes for Solaris 5.8
contrib/rrd_filter.px: Added a scale and shift filter.
src/utils_threshold.c: Fix the configuration of {Failure,Warning}Max and inverted checking.
The first issue is a simple copy'n'paste error, the second a nasty oversight.
The first issue is a simple copy'n'paste error, the second a nasty oversight.
contrib/rrd_filter.px: Remove the (unused) Data::Dumper.
Bumped version to 4.3.1; Updated ChangeLog.
contrib/rrd_filter.px: Renamed the old `extractDS.px'.
It can do more than extracting DSes now.
It can do more than extracting DSes now.
network plugin: Use `sstrncpy' instead of `strncpy'.
This removes a few "buf[buflen - 1] = '\0';".
This removes a few "buf[buflen - 1] = '\0';".
src/common.[ch]: Changed the signature of `sstrncpy' to match that of `strncpy'.
Merge branch 'collectd-4.2' into collectd-4.3
Conflicts:
ChangeLog
src/network.c
version-gen.sh
Conflicts:
ChangeLog
src/network.c
version-gen.sh