Florian Forster [Tue, 8 Dec 2009 12:27:47 +0000 (13:27 +0100)]
configure.in: Be more verbose when the python configuration fails.
Florian Forster [Tue, 8 Dec 2009 11:49:15 +0000 (12:49 +0100)]
src/pyvalues.c: Don't use Py_ssize_t - it's new in Python 2.5.
Florian Forster [Tue, 8 Dec 2009 11:25:03 +0000 (12:25 +0100)]
python plugin: Try to avoid casting errors with Sun's cc.
"python.c", line 534: warning: argument #1 is incompatible with prototype:
prototype: pointer to void : "python.c", line 470
argument : pointer to function(pointer to const char, pointer to function(..) returning void, pointer to struct user_data_s {pointer to void data, pointer to function(..) returning void free_func}) returning int
"python.c", line 534: warning: argument #2 is incompatible with prototype:
prototype: pointer to void : "python.c", line 470
argument : pointer to function(int, pointer to const char, pointer to struct user_data_s {pointer to void data, pointer to function(..) returning void free_func}) returning void
Florian Forster [Tue, 8 Dec 2009 11:14:56 +0000 (12:14 +0100)]
src/pyconfig.c: Make document strings non-const.
pyconfig.c:147: warning: initialization discards qualifiers from pointer target type
Florian Forster [Tue, 8 Dec 2009 10:59:22 +0000 (11:59 +0100)]
src/cpython.h: Apparently Python 2.3 doesn't have the Py_RETURN_NONE macro.
Florian Forster [Tue, 8 Dec 2009 10:53:10 +0000 (11:53 +0100)]
python plugin: Cast pointer to `void *' to work around strict aliasing problems.
python.c: In function `cpy_write_callback':
python.c:349: warning: dereferencing type-punned pointer will break strict-aliasing rules
python.c: In function `cpy_notification_callback':
python.c:368: warning: dereferencing type-punned pointer will break strict-aliasing rules
python.c: In function `cpy_oconfig_to_pyconfig':
python.c:842: warning: dereferencing type-punned pointer will break strict-aliasing rules
python.c: In function `cpy_config':
python.c:887: warning: dereferencing type-punned pointer will break strict-aliasing rules
python.c:888: warning: dereferencing type-punned pointer will break strict-aliasing rules
python.c:889: warning: dereferencing type-punned pointer will break strict-aliasing rules
Florian Forster [Tue, 8 Dec 2009 10:49:14 +0000 (11:49 +0100)]
python plugin: Fix some typos in the inline documentation.
Florian Forster [Tue, 8 Dec 2009 10:04:11 +0000 (11:04 +0100)]
collectd-python(5): Some more formatting and typo fixes.
Florian Forster [Tue, 8 Dec 2009 09:55:42 +0000 (10:55 +0100)]
collectd-python(5): Improve formatting of the classes.
Florian Forster [Tue, 8 Dec 2009 09:33:56 +0000 (10:33 +0100)]
collectd-python(5): Fix some formatting.
Florian Forster [Tue, 8 Dec 2009 09:23:11 +0000 (10:23 +0100)]
README: Added the python plugin.
Florian Forster [Tue, 8 Dec 2009 09:17:27 +0000 (10:17 +0100)]
AUTHORS: Sven +python.
Florian Forster [Tue, 8 Dec 2009 09:12:58 +0000 (10:12 +0100)]
src/plugin.c: Add libtool 1 compatibility code.
Florian Forster [Mon, 7 Dec 2009 14:39:43 +0000 (15:39 +0100)]
src/pyvalues.c: Cast `void *' to a int that's guaranteed to be big enough.
For some weird reason `int' is only 4 bytes long on x86_64, so casting
`void *' to `int' results in compiler warnings / errors.
Sven Trenkel [Sun, 6 Dec 2009 18:29:17 +0000 (19:29 +0100)]
Clean up exceptions in places where we don't care about them.
Sven Trenkel [Sun, 6 Dec 2009 18:10:19 +0000 (19:10 +0100)]
This should have been in the last commit.
Sven Trenkel [Sun, 6 Dec 2009 01:20:05 +0000 (02:20 +0100)]
Better unicode support.
Sven Trenkel [Sat, 5 Dec 2009 19:22:47 +0000 (20:22 +0100)]
Fixed build system bug.
Sven Trenkel [Sat, 5 Dec 2009 15:27:49 +0000 (16:27 +0100)]
Removes the __name__ from callback identifiers. It was useless and made things way more complicated and confusing than necessary.
Sven Trenkel [Sat, 5 Dec 2009 01:48:34 +0000 (02:48 +0100)]
Added collectd-python man page.
Sven Trenkel [Sat, 5 Dec 2009 01:10:20 +0000 (02:10 +0100)]
Added write method to Values.
Sven Trenkel [Thu, 3 Dec 2009 01:19:59 +0000 (02:19 +0100)]
Don't log stuff while holding the GIL!
Sven Trenkel [Wed, 2 Dec 2009 22:47:34 +0000 (23:47 +0100)]
Some signal dodging stuff.
Florian Forster [Wed, 2 Dec 2009 15:21:24 +0000 (16:21 +0100)]
Build system: Add the python plugin.
Sven Trenkel [Tue, 1 Dec 2009 01:22:57 +0000 (02:22 +0100)]
Finished inline documentation.
Sven Trenkel [Sat, 28 Nov 2009 13:17:50 +0000 (14:17 +0100)]
Added notification support.
Sven Trenkel [Mon, 23 Nov 2009 00:21:43 +0000 (01:21 +0100)]
Split the Values class into PluginData and Values to use PluginData as a baseclass for Notification later.
Also wrote some documentation.
Sven Trenkel [Sat, 21 Nov 2009 01:56:34 +0000 (02:56 +0100)]
Added proper doc strings to the Config class.
Sven Trenkel [Mon, 16 Nov 2009 00:57:20 +0000 (01:57 +0100)]
Added unregister functions for all callbacks.
Also removed useless plugin_unregister_complex_read declaration.
Sven Trenkel [Sun, 15 Nov 2009 02:46:03 +0000 (03:46 +0100)]
Added flush and register_flush functions.
Also changed name generation.
Sven Trenkel [Wed, 11 Nov 2009 10:31:41 +0000 (11:31 +0100)]
Proper exception logging.
Sven Trenkel [Mon, 9 Nov 2009 20:49:34 +0000 (21:49 +0100)]
Added a config option to start collectd as an interactive python shell.
Sven Trenkel [Sat, 7 Nov 2009 19:59:25 +0000 (20:59 +0100)]
No need to check for NULL if you're gonna pass NULL anyway.
Sven Trenkel [Sat, 7 Nov 2009 19:54:08 +0000 (20:54 +0100)]
Meh, forgot to pass the userdata back on write callbacks.
Sven Trenkel [Sat, 7 Nov 2009 18:37:16 +0000 (19:37 +0100)]
Added read callback. And "read" in this case means "plugin_register_complex_read".
Sven Trenkel [Tue, 3 Nov 2009 00:32:36 +0000 (01:32 +0100)]
Added write callbacks.
Sven Trenkel [Thu, 29 Oct 2009 12:24:39 +0000 (13:24 +0100)]
Better workaround for global plugin loading.
Sven Trenkel [Tue, 27 Oct 2009 16:36:57 +0000 (17:36 +0100)]
Added new python class "Values". Only "dispatch" is implemented right now.
Sven Trenkel [Wed, 21 Oct 2009 14:08:30 +0000 (16:08 +0200)]
Split python module. Added support for cyclic GC runs.
Sven Trenkel [Sat, 17 Oct 2009 18:06:51 +0000 (20:06 +0200)]
Added a workaround to module loading to allow Python scripts to do imports.
Redid the python thread handling.
Added log callback.
Sven Trenkel [Mon, 12 Oct 2009 22:17:16 +0000 (00:17 +0200)]
Added logging.
Sven Trenkel [Sun, 11 Oct 2009 23:04:01 +0000 (01:04 +0200)]
Added shutdown callback.
Also fixed a refcount bug.
Sven Trenkel [Sun, 11 Oct 2009 15:29:05 +0000 (17:29 +0200)]
Added init callbacks with full threading support.
Sven Trenkel [Sun, 11 Oct 2009 01:47:39 +0000 (03:47 +0200)]
Added keyword support for register_config.
Sven Trenkel [Sun, 11 Oct 2009 01:28:07 +0000 (03:28 +0200)]
Added python plugin.
It adds a "collectd" module to the embedded python interpreter
which contains a "register_config" method to register config
callbacks and "Config" class which contains a config item.
Sven Trenkel [Thu, 1 Oct 2009 11:20:53 +0000 (13:20 +0200)]
Added new netapp data types to types.db.
Doug MacEachern [Thu, 1 Oct 2009 00:28:08 +0000 (17:28 -0700)]
include netinet/in.h for sockaddr_in on FreeBSD
Fixes:
common.c: In function 'service_name_to_port_number':
common.c:1112: error: dereferencing pointer to incomplete type
common.c:1119: error: dereferencing pointer to incomplete type
Florian Forster [Wed, 30 Sep 2009 16:20:32 +0000 (18:20 +0200)]
Merge branch 'st/netapp'
Florian Forster [Wed, 30 Sep 2009 16:16:15 +0000 (18:16 +0200)]
netapp plugin: Subtract snap_norm_used from norm_used in any case.
Florian Forster [Wed, 30 Sep 2009 15:51:17 +0000 (17:51 +0200)]
collectd.conf(5): Updated the “GetSnapshot” entry.
Florian Forster [Wed, 30 Sep 2009 15:49:54 +0000 (17:49 +0200)]
netapp plugin: Use the “volume-” prefix for all volume related data.
Florian Forster [Wed, 30 Sep 2009 13:30:07 +0000 (15:30 +0200)]
netapp plugin: Create a notification when a volume goes offline or comes back.
Florian Forster [Wed, 30 Sep 2009 13:29:30 +0000 (15:29 +0200)]
netapp plugin: cna_handle_volume_snap_usage: Explain what's going on in a comment.
Sven Trenkel [Wed, 30 Sep 2009 12:13:44 +0000 (14:13 +0200)]
Fixed VolumePerf data collection.
Sven Trenkel [Wed, 30 Sep 2009 10:17:55 +0000 (12:17 +0200)]
Merge commit 'remotes/octo/st/netapp' into st/netapp
Sven Trenkel [Wed, 30 Sep 2009 10:17:39 +0000 (12:17 +0200)]
Added snapshot usage stats.
Florian Forster [Wed, 30 Sep 2009 08:59:30 +0000 (10:59 +0200)]
Build system: Link the netapp plugin with libnetapp.
D'oh! ;)
Florian Forster [Wed, 30 Sep 2009 06:11:10 +0000 (08:11 +0200)]
netapp plugin: Don't access a struct after freeing it.
Thanks Sven :)
Florian Forster [Tue, 29 Sep 2009 14:51:45 +0000 (16:51 +0200)]
netapp plugin: Add a shutdown callback.
Florian Forster [Tue, 29 Sep 2009 14:50:22 +0000 (16:50 +0200)]
netapp plugin: free_host_config: Close the connection if applicable.
Florian Forster [Tue, 29 Sep 2009 14:44:49 +0000 (16:44 +0200)]
collectd.conf(5): Document the “Interval” option in all blocks of the netapp plugin.
Florian Forster [Tue, 29 Sep 2009 14:37:48 +0000 (16:37 +0200)]
netapp plugin: Rename the “Capacity” and “Snapshot” options again.
They've been renamed to “GetCapacity” and “GetSnapshot” so the
names used within the “VolumeUsage” block are the same as the names
used elsewhere in the plugin.
Florian Forster [Tue, 29 Sep 2009 14:31:35 +0000 (16:31 +0200)]
netapp plugin: Remove left-over references to volume_t.
Florian Forster [Tue, 29 Sep 2009 14:29:30 +0000 (16:29 +0200)]
netapp plugin: Remove all left-over references to cfg_service_t.
Florian Forster [Tue, 29 Sep 2009 14:24:40 +0000 (16:24 +0200)]
netapp plugin: Refactor the VolumePerf collection.
Same procedure one last time. The “GetVolumePerfData” block has been
renamed to “VolumePerf”. The “Get{IO,Ops,Latency}” options now
use ignore lists, too. Appropriate “IgnoreSelected{IO,Ops,Latency}”
options have been introduced.
Florian Forster [Tue, 29 Sep 2009 13:53:12 +0000 (15:53 +0200)]
netapp plugin: Set the HAVE_VOLUME_USAGE_SIS_SAVED after determining the value.
Florian Forster [Tue, 29 Sep 2009 13:51:07 +0000 (15:51 +0200)]
netapp plugin: Fix handling of the SIS value.
Florian Forster [Tue, 29 Sep 2009 12:33:15 +0000 (14:33 +0200)]
netapp plugin: Refactored volume usage statistics.
Much of this is like disk, wafl and system statistics before. The
“GetVolumeData” has been renamed to “VolumeUsage” and the
“GetDiskUtil” and “GetSnapUtil” options have been changed, too. The
configuration now looks like this:
<VolumeUsage>
Capacity "vol0"
Capacity "vol1"
IgnoreSelectedCapacity false
Snapshot "vol1"
Snapshot "vol3"
IgnoreSelectedSnapshot false
</VolumeUsage>
The code now uses to "ignore lists" to check whether capacity and/or
snapshot information should be collected for a volume. This means the
order in which volumes are listed no longer matters and than you can
use such advanced options as selecting volumes via regular expressions.
Sven Trenkel [Mon, 28 Sep 2009 23:02:48 +0000 (01:02 +0200)]
Fixed NULL pointer bug.
Florian Forster [Mon, 28 Sep 2009 14:05:55 +0000 (16:05 +0200)]
netapp plugin: Inform the user when he screwed up the disk and system blocks, too.
Florian Forster [Mon, 28 Sep 2009 13:56:26 +0000 (15:56 +0200)]
netapp plugin: Print a notice if all WAFL values have been disabled.
This message is printed if the user did supply a <WAFL /> block but
then disabled all supported values. WAFL collection will be disabled
in this case to increase performance.
Florian Forster [Mon, 28 Sep 2009 13:45:13 +0000 (15:45 +0200)]
netapp plugin: Document the graceful return if statistics are not wanted.
Unfortunately this behavior isn't exactly obvious.
Florian Forster [Mon, 28 Sep 2009 13:42:42 +0000 (15:42 +0200)]
netapp plugin: Refactor system statistics.
Same procedure as before: Instead of using the “service handler”,
create a cfg_system_t pointer if the user wants system statistics. Then
call cna_query_system instead of the service handler.
The “GetSystemPerfData” block has been renamed to “System” and the
“Multiplier” option has been replaced by the “Interval” option.
Florian Forster [Mon, 28 Sep 2009 12:43:37 +0000 (14:43 +0200)]
Merge remote branch 'trenkel/st/netapp' into st/netapp
Florian Forster [Mon, 28 Sep 2009 12:41:10 +0000 (14:41 +0200)]
netapp plugin: Refactor handling of the WAFL data.
Basically the same structure as for the Disk data has been used. The
service handler has been removed and replaced by a call to
“cna_query_wafl”.
The “GetWaflPerfData” block has been renamed to “WAFL” to make the
config file easier to read. The “GetBufCache” config option has been
renamed to “GetBufferCache”. Maybe it should be renamed to
“GetBufferHash”, because that's what the NetApp API uses…?
Sven Trenkel [Mon, 28 Sep 2009 11:57:46 +0000 (13:57 +0200)]
Merge commit 'octo/st/netapp' into st/netapp
Florian Forster [Mon, 28 Sep 2009 11:27:13 +0000 (13:27 +0200)]
netapp plugin: Changed Sven's email address at his request.
Florian Forster [Mon, 28 Sep 2009 11:26:34 +0000 (13:26 +0200)]
netapp plugin: Refactored reading of disk data.
Instead of obscuring control-flow with generic function pointers, use a
clear and easy to read function hierarchy. All disk-related action now
starts with “cna_query_disk (host)” instead of
“service->handler (host, data, service->data)”.
The “GetDiskPerfData”block has been renamed to “Disks”. All those
blocks start with “Get” and most end with “PerfData”, distracting
from the actual relevant part.
The “Multiplier” option has been replaced by the “Interval” option,
which expects a time in seconds rather than a factor which is multiplied
to the host interval.
Florian Forster [Mon, 28 Sep 2009 11:14:12 +0000 (13:14 +0200)]
netapp plugin: Fix a typo.
Sven Trenkel [Mon, 28 Sep 2009 10:40:44 +0000 (12:40 +0200)]
Copypasta error in volume usage.
Florian Forster [Mon, 28 Sep 2009 09:59:59 +0000 (11:59 +0200)]
netapp plugin: cna_config_disk: Fix typo.
Sven Trenkel [Sat, 26 Sep 2009 23:39:40 +0000 (01:39 +0200)]
Preparations for collecting snapshot data,
fixed NULL pointer bug,
removed duplicate error message.
Florian Forster [Sat, 26 Sep 2009 09:27:33 +0000 (11:27 +0200)]
netapp plugin: cna_init: Add some comments.
Sven Trenkel [Sat, 26 Sep 2009 01:27:41 +0000 (03:27 +0200)]
Don't try to graph operations that aren't licensed
on this filer.
Doug MacEachern [Fri, 25 Sep 2009 20:25:47 +0000 (13:25 -0700)]
redirect sysctl kern.cp_times stderr > /dev/null
Doug MacEachern [Fri, 25 Sep 2009 20:03:41 +0000 (13:03 -0700)]
use kern.cp_times sysctl for FreeBSD smp support
Doug MacEachern [Fri, 25 Sep 2009 20:02:26 +0000 (13:02 -0700)]
define HAVE_SYSCTL_KERN_CP_TIMES if sysctl supports kern.cp_times
Florian Forster [Thu, 24 Sep 2009 16:03:51 +0000 (18:03 +0200)]
netapp plugin: Improved handling host <Host /> blocks.
Use the new "cf_util_get_string" and "cf_util_get_port_number" functions
and free the host configuration if it fails.
The "Login" option has been split up into the "User" and "Password" options.
Florian Forster [Thu, 24 Sep 2009 15:54:21 +0000 (17:54 +0200)]
netapp plugin: Rename set_global_{perf_,}vol_flag.
Hopefully the new names are more descriptive.
Florian Forster [Thu, 24 Sep 2009 15:38:02 +0000 (17:38 +0200)]
src/configfile.[ch]: Implement "cf_util_get_port_number".
Florian Forster [Thu, 24 Sep 2009 15:37:25 +0000 (17:37 +0200)]
tokyotyrant plugin: Remove no longer needed includes.
Florian Forster [Thu, 24 Sep 2009 15:32:29 +0000 (17:32 +0200)]
src/configfile.[ch]: Implement "cf_util_get_string".
Florian Forster [Thu, 24 Sep 2009 15:30:56 +0000 (17:30 +0200)]
src/common.[ch]: Implement "service_name_to_port_number".
It returns the numeric representation of a service name. The implementation
has been taken from the tokyotyrant plugin.
Florian Forster [Thu, 24 Sep 2009 12:47:12 +0000 (14:47 +0200)]
netapp plugin: Use the "cna_config_" prefix for configuration handling functions.
Florian Forster [Thu, 24 Sep 2009 12:36:53 +0000 (14:36 +0200)]
netapp plugin: Add a short description to most functions.
The order of some functions has been changed, too.
Florian Forster [Thu, 24 Sep 2009 12:19:19 +0000 (14:19 +0200)]
netapp plugin: Add folding markers to all remaining functions.
Florian Forster [Thu, 24 Sep 2009 12:03:53 +0000 (14:03 +0200)]
netapp plugin: Changed some type names.
The structure is roughly like this: Structs that only hold flags to tell
the functions what data to submit are prefixed with "cfg_". Structs that
hold old values for counters are prefixed with "data_".
The "disk_t" type now included flags, too, to indicate valid / invalid
values. The "query_submit_disk_data" function has been changed to honor
those flags.
Various "volume_data" stuff has been renamed to "volume_usage" to make
it more distinguishable from "volume_performance".
Various defines are now also prefixed with "CFG_" to show which flags
are used for configuration and which are used do mark counters valid.
The latter use the "HAVE_" prefix.
Florian Forster [Thu, 24 Sep 2009 10:53:32 +0000 (12:53 +0200)]
AUTHORS: Add Sven Trenkel.
Florian Forster [Thu, 24 Sep 2009 10:53:21 +0000 (12:53 +0200)]
README: Add the “netapp” plugin.
Florian Forster [Thu, 24 Sep 2009 10:48:30 +0000 (12:48 +0200)]
netapp plugin: Split up “collect_perf_wafl_data” …
… into “query_wafl_data” and “submit_wafl_data”.
Again, flags are used to keep track of valid (old) counters.