From 32073e0ab5b7d059f4562422974952fea4831f0f3fb2c27156f716673f700407 Mon Sep 17 00:00:00 2001 From: Ruediger Oertel Date: Thu, 3 Feb 2011 01:08:32 +0000 Subject: [PATCH] Accepting request 59758 from YaST:Web Accepted submit request 59758 from user schubi2 OBS-URL: https://build.opensuse.org/request/show/59758 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/collectd?expand=0&rev=1 --- .gitattributes | 23 + .gitignore | 1 + collectd-4.10.2.tar.bz2 | 3 + collectd-collection3.patch | 124 +++ collectd-dont_poison_strcpy.patch | 13 + collectd-fix-buffer-overflow.patch | 11 + collectd-fix-config.patch | 62 ++ collectd-fix-ignore-return-value.patch | 13 + collectd-fix-warnings.patch | 20 + collectd-fix_broken_perl-5.10.patch | 17 + ...x_collectd_config_path_in_snmp_probe.patch | 11 + collectd-fix_collection_cgi.patch | 19 + collectd-fix_libltdl_autoreconf.patch | 19 + collectd-fix_libltdl_serial_order.patch | 20 + collectd-fix_spamassassin_doc.patch | 16 + ...d-fix_teamspeak2_array_out_of_bounds.patch | 20 + collectd-iproute2-HZ.patch | 24 + collectd-js.apache2.conf | 30 + collectd-lib64.patch | 11 + collectd-perl-vendor.patch | 11 + collectd-pthread.pc | 10 + collectd-split_README.patch | 61 ++ collectd-version.patch | 9 + collectd.apache2.conf | 16 + collectd.changes | 494 +++++++++++ collectd.spec | 833 ++++++++++++++++++ collectd.suse.init | 95 ++ iproute2-2.6.34.tar.bz2 | 3 + iproute2-optflags.patch | 14 + 29 files changed, 2003 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 collectd-4.10.2.tar.bz2 create mode 100644 collectd-collection3.patch create mode 100644 collectd-dont_poison_strcpy.patch create mode 100644 collectd-fix-buffer-overflow.patch create mode 100644 collectd-fix-config.patch create mode 100644 collectd-fix-ignore-return-value.patch create mode 100644 collectd-fix-warnings.patch create mode 100644 collectd-fix_broken_perl-5.10.patch create mode 100644 collectd-fix_collectd_config_path_in_snmp_probe.patch create mode 100644 collectd-fix_collection_cgi.patch create mode 100644 collectd-fix_libltdl_autoreconf.patch create mode 100644 collectd-fix_libltdl_serial_order.patch create mode 100644 collectd-fix_spamassassin_doc.patch create mode 100644 collectd-fix_teamspeak2_array_out_of_bounds.patch create mode 100644 collectd-iproute2-HZ.patch create mode 100644 collectd-js.apache2.conf create mode 100644 collectd-lib64.patch create mode 100644 collectd-perl-vendor.patch create mode 100644 collectd-pthread.pc create mode 100644 collectd-split_README.patch create mode 100644 collectd-version.patch create mode 100644 collectd.apache2.conf create mode 100644 collectd.changes create mode 100644 collectd.spec create mode 100644 collectd.suse.init create mode 100644 iproute2-2.6.34.tar.bz2 create mode 100644 iproute2-optflags.patch diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/collectd-4.10.2.tar.bz2 b/collectd-4.10.2.tar.bz2 new file mode 100644 index 0000000..a82ab17 --- /dev/null +++ b/collectd-4.10.2.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17cd6741c360cb2544f00fbe902ec3e9aa0d04a7ab6a744e3e8ea5615bb794be +size 1419603 diff --git a/collectd-collection3.patch b/collectd-collection3.patch new file mode 100644 index 0000000..3ada440 --- /dev/null +++ b/collectd-collection3.patch @@ -0,0 +1,124 @@ +--- contrib/collection3/bin/graph.cgi.orig 2009-10-07 23:29:32.000000000 +0200 ++++ contrib/collection3/bin/graph.cgi 2009-10-07 23:51:50.000000000 +0200 +@@ -2,10 +2,9 @@ + + use strict; + use warnings; +-use lib ('../lib'); ++use lib ('/usr/lib/collectd-js'); + use utf8; + +-use FindBin ('$RealBin'); + use Carp (qw(confess cluck)); + use CGI (':cgi'); + use RRDs (); +@@ -49,7 +48,7 @@ + HTTP + } + +-gc_read_config ("$RealBin/../etc/collection.conf"); ++gc_read_config ("/etc/collectd/collection-js.conf"); + + if ($GraphWidth) + { +--- contrib/collection3/bin/index.cgi.orig 2009-10-07 23:30:27.000000000 +0200 ++++ contrib/collection3/bin/index.cgi 2009-10-07 23:52:09.000000000 +0200 +@@ -17,11 +17,10 @@ + + use strict; + use warnings; +-use lib ('../lib'); ++use lib ('/usr/lib/collectd-js'); + use utf8; + + use Carp (qw(cluck confess)); +-use FindBin ('$RealBin'); + use CGI (':cgi'); + use CGI::Carp ('fatalsToBrowser'); + use HTML::Entities ('encode_entities'); +@@ -59,7 +58,7 @@ + exit 1; + } + +-gc_read_config ("$RealBin/../etc/collection.conf"); ++gc_read_config ("/etc/collectd/collection-js.conf"); + + $Actions{$action}->(); + exit (0); +@@ -144,9 +143,9 @@ + print < + collection.cgi, Version 3 +- +- +- ++ ++ ++ + + + HTML +--- contrib/collection3/bin/json.cgi.orig 2009-10-07 23:30:58.000000000 +0200 ++++ contrib/collection3/bin/json.cgi 2009-10-07 23:51:33.000000000 +0200 +@@ -17,10 +17,9 @@ + + use strict; + use warnings; +-use lib ('../lib'); ++use lib ('/usr/lib/collectd-js'); + use utf8; + +-use FindBin ('$RealBin'); + use CGI (':cgi'); + use CGI::Carp ('fatalsToBrowser'); + use URI::Escape ('uri_escape'); +@@ -36,7 +35,7 @@ + our $Debug = param ('debug') ? 1 : 0; + our $ServerName = 'collect.noris.net'; + +-gc_read_config ("$RealBin/../etc/collection.conf"); ++gc_read_config ("/etc/collectd/collection-js.conf"); + + if ($Debug) + { +--- contrib/collection3/etc/collection.conf.orig 2009-10-07 23:52:29.000000000 +0200 ++++ contrib/collection3/etc/collection.conf 2009-10-07 23:52:34.000000000 +0200 +@@ -1,4 +1,4 @@ +-#DataDir "/var/lib/collectd/rrd" ++#DataDir "/var/lib/collectd" + GraphWidth 400 + #UnixSockAddr "/var/run/collectd-unixsock" + +--- contrib/collection3/lib/Collectd/Graph/Common.pm.orig 2009-10-07 23:36:33.000000000 +0200 ++++ contrib/collection3/lib/Collectd/Graph/Common.pm 2009-10-07 23:36:39.000000000 +0200 +@@ -44,7 +44,7 @@ + flush_files + )); + +-our $DefaultDataDir = '/var/lib/collectd/rrd'; ++our $DefaultDataDir = '/var/lib/collectd'; + + return (1); + +--- contrib/collection3/lib/Collectd/Graph/Config.pm.orig 2009-10-07 23:35:15.000000000 +0200 ++++ contrib/collection3/lib/Collectd/Graph/Config.pm 2009-10-07 23:35:31.000000000 +0200 +@@ -57,7 +57,7 @@ + return (1); + } + +- $file ||= "etc/collection.conf"; ++ $file ||= "/etc/collectd/collection-js.conf"; + + %conf = ParseConfig (-ConfigFile => $file, + -LowerCaseNames => 1, +--- contrib/collection3/lib/Collectd/Config.pm.orig 2009-10-07 23:32:23.000000000 +0200 ++++ contrib/collection3/lib/Collectd/Config.pm 2009-10-07 23:34:57.000000000 +0200 +@@ -58,7 +58,7 @@ + return (1); + } + +- $file ||= "etc/collection.conf"; ++ $file ||= "/etc/collectd/collection-js.conf"; + + %conf = ParseConfig (-ConfigFile => $file, + -LowerCaseNames => 1, diff --git a/collectd-dont_poison_strcpy.patch b/collectd-dont_poison_strcpy.patch new file mode 100644 index 0000000..78fa655 --- /dev/null +++ b/collectd-dont_poison_strcpy.patch @@ -0,0 +1,13 @@ +--- src/collectd.h.orig 2008-09-12 00:14:09.000000000 +0200 ++++ src/collectd.h 2008-09-12 00:14:55.000000000 +0200 +@@ -254,10 +254,6 @@ + # define __attribute__(x) /**/ + #endif + +-#if __GNUC__ +-# pragma GCC poison strcpy strcat strtok +-#endif +- + /* + * Special hack for the perl plugin: Because the later included perl.h defines + * a macro which is never used, but contains `sprintf', we cannot poison that diff --git a/collectd-fix-buffer-overflow.patch b/collectd-fix-buffer-overflow.patch new file mode 100644 index 0000000..f2f56a3 --- /dev/null +++ b/collectd-fix-buffer-overflow.patch @@ -0,0 +1,11 @@ +--- src/perl.c.orig 2007-09-13 00:08:17.000000000 +0200 ++++ src/perl.c 2007-09-13 00:17:42.000000000 +0200 +@@ -333,7 +333,7 @@ + status = snprintf (buf, buf_len, "%s::%s", base_name, module); + if ((status < 0) || (status >= buf_len)) + return (NULL); +- buf[buf_len] = '\0'; ++ buf[buf_len - 1] = '\0'; + return (buf); + } /* char *get_module_name */ + diff --git a/collectd-fix-config.patch b/collectd-fix-config.patch new file mode 100644 index 0000000..890bc11 --- /dev/null +++ b/collectd-fix-config.patch @@ -0,0 +1,62 @@ +--- src/collectd.conf.in.orig 2010-07-09 12:01:59.000000000 +0200 ++++ src/collectd.conf.in 2010-07-12 01:05:24.000000000 +0200 +@@ -12,10 +12,10 @@ + + #Hostname "localhost" + FQDNLookup true +-#BaseDir "@prefix@/var/lib/@PACKAGE_NAME@" +-#PIDFile "@prefix@/var/run/@PACKAGE_NAME@.pid" +-#PluginDir "@prefix@/lib/@PACKAGE_NAME@" +-#TypesDB "@prefix@/share/@PACKAGE_NAME@/types.db" ++#BaseDir "/var/lib/@PACKAGE_NAME@" ++#PIDFile "/var/run/@PACKAGE_NAME@.pid" ++#PluginDir "@libdir@/@PACKAGE_NAME@" ++#TypesDB "@libdir@/@PACKAGE_NAME@/types.db" + #Interval 10 + #Timeout 2 + #ReadThreads 5 +@@ -149,7 +149,7 @@ + + # + # URL "http://localhost/status?auto" +-# User "www-user" ++# User "www" + # Password "secret" + # CACert "/etc/ssl/ca.crt" + # +@@ -161,7 +161,7 @@ + + # + # URL "http://localhost/ascent/status/" +-# User "www-user" ++# User "www" + # Password "secret" + # CACert "/etc/ssl/ca.crt" + # +@@ -186,7 +186,7 @@ + # + + # +-# DataDir "@prefix@/var/lib/@PACKAGE_NAME@/csv" ++# DataDir "/var/lib/@PACKAGE_NAME@/csv" + # StoreRates false + # + +@@ -299,7 +299,7 @@ + # + + # +-# SocketFile "@prefix@/var/run/@PACKAGE_NAME@-email" ++# SocketFile "/var/run/@PACKAGE_NAME@-email" + # SocketGroup "collectd" + # SocketPerms "0770" + # MaxConns 5 +@@ -881,7 +881,7 @@ + # + + # +-# SocketFile "@prefix@/var/run/@PACKAGE_NAME@-unixsock" ++# SocketFile "/var/run/@PACKAGE_NAME@-unixsock" + # SocketGroup "collectd" + # SocketPerms "0660" + # diff --git a/collectd-fix-ignore-return-value.patch b/collectd-fix-ignore-return-value.patch new file mode 100644 index 0000000..70eee5b --- /dev/null +++ b/collectd-fix-ignore-return-value.patch @@ -0,0 +1,13 @@ +--- src/multimeter.c.orig 2007-02-10 22:48:00.000000000 +0100 ++++ src/multimeter.c 2007-02-10 22:48:46.000000000 +0100 +@@ -90,8 +90,10 @@ + struct timeval timeout; + struct timeval time_now; + +- write(fd, "D", 1); ++ if (write(fd, "D", 1) == -1) { ++ perror("unable to write D on file descriptor: "); ++ } + + FD_ZERO(&rfds); + FD_SET(fd, &rfds); diff --git a/collectd-fix-warnings.patch b/collectd-fix-warnings.patch new file mode 100644 index 0000000..c281563 --- /dev/null +++ b/collectd-fix-warnings.patch @@ -0,0 +1,20 @@ +--- src/netlink.c.orig 2009-02-17 12:56:09.000000000 +0100 ++++ src/netlink.c 2009-02-17 12:56:44.000000000 +0100 +@@ -573,7 +573,7 @@ + } + + if (rtnl_dump_filter (&rth, link_filter, /* arg1 = */ NULL, +- NULL, NULL) != 0) ++ (rtnl_filter_t)NULL, NULL) != 0) + { + ERROR ("netlink plugin: ir_read: rtnl_dump_filter failed."); + return (-1); +@@ -611,7 +611,7 @@ + } + + if (rtnl_dump_filter (&rth, qos_filter, (void *) &ifindex, +- NULL, NULL) != 0) ++ (rtnl_filter_t)NULL, NULL) != 0) + { + ERROR ("netlink plugin: ir_read: rtnl_dump_filter failed."); + continue; diff --git a/collectd-fix_broken_perl-5.10.patch b/collectd-fix_broken_perl-5.10.patch new file mode 100644 index 0000000..e51b25c --- /dev/null +++ b/collectd-fix_broken_perl-5.10.patch @@ -0,0 +1,17 @@ +--- src/perl.c.orig 2008-04-02 21:06:14.000000000 +0200 ++++ src/perl.c 2008-04-02 21:15:50.000000000 +0200 +@@ -1440,7 +1440,13 @@ + + log_debug ("perl_config: loading perl plugin \"%s\"", value); + load_module (PERL_LOADMOD_NOIMPORT, +- newSVpv (module_name, strlen (module_name)), Nullsv); ++ newSVpv (module_name, strlen (module_name)), ++#if PERL_VERSION >= 10 ++ newSViv(0) ++#else ++ Nullsv ++#endif ++ ); + return 0; + } /* static int perl_config_loadplugin (oconfig_item_it *) */ + diff --git a/collectd-fix_collectd_config_path_in_snmp_probe.patch b/collectd-fix_collectd_config_path_in_snmp_probe.patch new file mode 100644 index 0000000..2659e0c --- /dev/null +++ b/collectd-fix_collectd_config_path_in_snmp_probe.patch @@ -0,0 +1,11 @@ +--- contrib/snmp-probe-host.px.orig 2009-10-07 22:55:23.000000000 +0200 ++++ contrib/snmp-probe-host.px 2009-10-07 22:57:45.000000000 +0200 +@@ -290,7 +290,7 @@ + =cut + + my $host; +-my $file = '/etc/collectd/collectd.conf'; ++my $file = '/etc/collectd.conf'; + my $community = 'public'; + my $conf; + my $working_data; diff --git a/collectd-fix_collection_cgi.patch b/collectd-fix_collection_cgi.patch new file mode 100644 index 0000000..a709e09 --- /dev/null +++ b/collectd-fix_collection_cgi.patch @@ -0,0 +1,19 @@ +--- contrib/collection.cgi.orig 2010-04-22 11:30:07.000000000 +0200 ++++ contrib/collection.cgi 2010-05-20 18:23:38.000000000 +0200 +@@ -11,7 +11,7 @@ + use RRDs (); + use Data::Dumper (); + +-our $Config = "/etc/collection.conf"; ++our $Config = "/etc/collectd/collection.conf"; + our @DataDirs = (); + our @DontShowTypes = (); + our $LibDir; +--- contrib/collection.conf.orig 2010-04-22 11:29:35.000000000 +0200 ++++ contrib/collection.conf 2010-05-20 18:23:38.000000000 +0200 +@@ -1,3 +1,2 @@ +-datadir: "/opt/collectd/var/lib/collectd/rrd/" +-libdir: "/opt/collectd/lib/collectd/" +- ++datadir: "/var/lib/collectd/" ++libdir: "@@LIBDIR@@/collectd/" diff --git a/collectd-fix_libltdl_autoreconf.patch b/collectd-fix_libltdl_autoreconf.patch new file mode 100644 index 0000000..eb48cf6 --- /dev/null +++ b/collectd-fix_libltdl_autoreconf.patch @@ -0,0 +1,19 @@ +--- Makefile.in.orig 2009-07-27 16:44:54.000000000 +0200 ++++ Makefile.in 2009-07-27 16:45:08.000000000 +0200 +@@ -263,7 +263,7 @@ + top_build_prefix = @top_build_prefix@ + top_builddir = @top_builddir@ + top_srcdir = @top_srcdir@ +-ACLOCAL_AMFLAGS = -I libltdl/m4 ++ACLOCAL_AMFLAGS = -I libltdl + SUBDIRS = libltdl src bindings + INCLUDES = $(LTDLINCL) + EXTRA_DIST = contrib version-gen.sh +--- Makefile.am.orig 2009-07-27 16:44:44.000000000 +0200 ++++ Makefile.am 2009-07-27 16:44:52.000000000 +0200 +@@ -1,4 +1,4 @@ +-ACLOCAL_AMFLAGS = -I libltdl/m4 ++ACLOCAL_AMFLAGS = -I libltdl + + SUBDIRS = libltdl src bindings + diff --git a/collectd-fix_libltdl_serial_order.patch b/collectd-fix_libltdl_serial_order.patch new file mode 100644 index 0000000..7e99905 --- /dev/null +++ b/collectd-fix_libltdl_serial_order.patch @@ -0,0 +1,20 @@ +--- libltdl/acinclude.m4.orig 2009-10-08 07:19:06.000000000 +0200 ++++ libltdl/acinclude.m4 2009-10-08 07:19:42.000000000 +0200 +@@ -8,6 +8,8 @@ + ## modifications, as long as this notice is preserved. + + # serial 52 Debian 1.5.26-4 AC_PROG_LIBTOOL ++# serial 9 AC_LIB_LTDL ++ + + + # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) +@@ -6677,8 +6679,6 @@ + ## unlimited permission to copy and/or distribute it, with or without + ## modifications, as long as this notice is preserved. + +-# serial 9 AC_LIB_LTDL +- + # AC_WITH_LTDL + # ------------ + # Clients of libltdl can use this macro to allow the installer to diff --git a/collectd-fix_spamassassin_doc.patch b/collectd-fix_spamassassin_doc.patch new file mode 100644 index 0000000..4ba3a2d --- /dev/null +++ b/collectd-fix_spamassassin_doc.patch @@ -0,0 +1,16 @@ +--- contrib/SpamAssassin/Collectd.pm.orig 2009-10-07 22:34:14.000000000 +0200 ++++ contrib/SpamAssassin/Collectd.pm 2009-10-07 22:36:50.000000000 +0200 +@@ -4,13 +4,7 @@ + + Collectd - plugin for filling collectd with stats + +-=head1 INSTALLATION +- +-Just copy Collectd.pm into your SpamAssassin Plugin path +-(e.g /usr/share/perl5/Mail/SpamAssassin/Plugin/) and +-add a loadplugin call into your init.pre file. +- + =head1 SYNOPSIS + + loadplugin Mail::SpamAssassin::Plugin::Collectd + diff --git a/collectd-fix_teamspeak2_array_out_of_bounds.patch b/collectd-fix_teamspeak2_array_out_of_bounds.patch new file mode 100644 index 0000000..9397f1b --- /dev/null +++ b/collectd-fix_teamspeak2_array_out_of_bounds.patch @@ -0,0 +1,20 @@ +--- src/teamspeak2.c.orig 2008-05-07 21:18:33.000000000 +0200 ++++ src/teamspeak2.c 2008-05-07 21:19:45.000000000 +0200 +@@ -389,7 +389,7 @@ + ERROR ("teamspeak2 plugin: tss2_receive_line failed."); + return (-1); + } +- response[sizeof (response)] = 0; ++ response[sizeof (response) - 1] = 0; + + /* Check answer */ + if ((strncasecmp ("OK", response, 2) == 0) +@@ -437,7 +437,7 @@ + ERROR ("teamspeak2 plugin: tss2_receive_line failed."); + return (-1); + } +- buffer[sizeof (buffer)] = 0; ++ buffer[sizeof (buffer) - 1] = 0; + + if (strncmp ("average_packet_loss=", buffer, + strlen ("average_packet_loss=")) == 0) diff --git a/collectd-iproute2-HZ.patch b/collectd-iproute2-HZ.patch new file mode 100644 index 0000000..fec78e6 --- /dev/null +++ b/collectd-iproute2-HZ.patch @@ -0,0 +1,24 @@ +--- lib/utils.c.orig 2008-04-17 19:12:54.000000000 +0200 ++++ lib/utils.c 2008-05-08 00:20:27.000000000 +0200 +@@ -33,6 +33,10 @@ + + #include "utils.h" + ++#ifndef HZ ++#define HZ sysconf(_SC_CLK_TCK) ++#endif ++ + int get_integer(int *val, const char *arg, int base) + { + long res; +@@ -430,8 +434,8 @@ + + int inet_addr_match(const inet_prefix *a, const inet_prefix *b, int bits) + { +- const __u32 *a1 = a->data; +- const __u32 *a2 = b->data; ++ const __u32 *a1 = (__u32*)a->data; ++ const __u32 *a2 = (__u32*)b->data; + int words = bits >> 0x05; + + bits &= 0x1f; diff --git a/collectd-js.apache2.conf b/collectd-js.apache2.conf new file mode 100644 index 0000000..9c88204 --- /dev/null +++ b/collectd-js.apache2.conf @@ -0,0 +1,30 @@ + + ScriptAlias /collectd-js /srv/www/collectd-js/bin/index.cgi + + # Access control: + + Order allow,deny + + # You might want to change this to avoid giving everyone + # access to the collectd statistics, e.g.: + # Allow from all + # Allow from localhost + # Allow from 192.168. + Deny from all + + + + Options +ExecCGI + AddHandler cgi-script .cgi + + Order allow,deny + + # You might want to change this to avoid giving everyone + # access to the collectd statistics, e.g.: + # Allow from all + # Allow from localhost + # Allow from 192.168. + Deny from all + + + diff --git a/collectd-lib64.patch b/collectd-lib64.patch new file mode 100644 index 0000000..7d492ab --- /dev/null +++ b/collectd-lib64.patch @@ -0,0 +1,11 @@ +--- src/collectd.h.orig 2009-12-20 16:36:31.000000000 +0100 ++++ src/collectd.h 2009-12-21 20:01:00.000000000 +0100 +@@ -254,7 +254,7 @@ + #endif + + #ifndef PLUGINDIR +-#define PLUGINDIR PREFIX "/lib/" PACKAGE_NAME ++#define PLUGINDIR PREFIX "/lib64/" PACKAGE_NAME + #endif + + #ifndef PKGDATADIR diff --git a/collectd-perl-vendor.patch b/collectd-perl-vendor.patch new file mode 100644 index 0000000..ee6672a --- /dev/null +++ b/collectd-perl-vendor.patch @@ -0,0 +1,11 @@ +--- bindings/Makefile.am.orig 2008-01-22 09:16:05.000000000 +0100 ++++ bindings/Makefile.am 2008-01-22 09:16:18.000000000 +0100 +@@ -3,7 +3,7 @@ + all-local: @PERL_BINDINGS@ + + install-exec-local: +- [ ! -f perl/Makefile ] || ( cd perl && $(MAKE) install ) ++ [ ! -f perl/Makefile ] || ( cd perl && $(MAKE) install_vendor ) + + clean-local: + [ ! -f perl/Makefile ] || ( cd perl && $(MAKE) realclean ) diff --git a/collectd-pthread.pc b/collectd-pthread.pc new file mode 100644 index 0000000..d8b8da1 --- /dev/null +++ b/collectd-pthread.pc @@ -0,0 +1,10 @@ +prefix=/ +exec_prefix=${prefix} +libdir=/@@LIB@@ +includedir=${prefix}/include + +Name: pthread +Description: POSIX threading library +Version: 0.0.0 +Libs: -lpthread +Cflags: diff --git a/collectd-split_README.patch b/collectd-split_README.patch new file mode 100644 index 0000000..02f1b11 --- /dev/null +++ b/collectd-split_README.patch @@ -0,0 +1,61 @@ +--- contrib/README.orig 2009-10-07 22:17:58.000000000 +0200 ++++ contrib/README 2009-10-07 22:45:41.000000000 +0200 +@@ -28,22 +28,6 @@ + `/var/lib/collectd/' and generate an HTML file and a directory containing + several PNG files which are graphs of the RRD files found. + +-collection.cgi +--------------- +- Sample CGI script that creates graphs on the fly. The Perl modules `RRDs' +-(Debian package `librrds-perl'), `URI:Escape' (package liburi-perl), +-`HTML::Entities' (package libhtml-parser-perl) and a CGI capable web server +-(e.g. apache2 or boa) are needed. Simply install the script to a place where +-the webserver will treat it as a CGI script (/usr/lib/cgi-bin/ by default) and +-visit that page in a browser (http://localhost/cgi-bin/collection.cgi by +-default). Please refer to your webserver's documentation for more details. +- +- Starting with version 4, collection.cgi requires a small config file, which +-should look something like this: +- +- datadir: "/var/lib/collectd/rrd/" +- libdir: "/usr/lib/collectd/" +- + exec-munin.px + ------------- + Script to be used with the exec-plugin (see collectd-exec(5) for details) +@@ -65,16 +49,6 @@ + RRD-file that should have been in multiple RRD-files instead. Is is used by + `migrate-3-4.px' to split up the cpu-, nfs-, swap-files and possibly others. + +-fedora/ +-------- +- Init-script and Spec-file that can be used when creating RPM-packages for +-Fedora. +- +-GenericJMX.conf +---------------- +- Example configuration file for the ‘GenericJMX’ Java plugin. Please read the +-documentation at the beginning of the file for more details. +- + migrate-3-4.px + -------------- + Migration-script to ease the switch from version 3 to version 4. Many +@@ -84,10 +58,6 @@ + may still need to do some things by hand, read `README.migration' for more + details. + +-redhat/ +-------- +- Spec-file and affiliated files to build an RedHat RPM package of collectd. +- + snmp-data.conf + -------------- + Sample configuration for the SNMP plugin. This config includes a few standard +@@ -97,7 +67,3 @@ + whatever people have send in. If you have some more definitions please send + them in, so others can profit from it. + +-solaris-smf +------------ +- Manifest file for the Solaris SMF system and detailed information on how to +-register collectd as a service with this system. diff --git a/collectd-version.patch b/collectd-version.patch new file mode 100644 index 0000000..ad8a89e --- /dev/null +++ b/collectd-version.patch @@ -0,0 +1,9 @@ +--- configure.in.orig 2009-12-20 16:36:31.000000000 +0100 ++++ configure.in 2009-12-21 20:25:07.000000000 +0100 +@@ -1,5 +1,5 @@ + dnl Process this file with autoconf to produce a configure script. +-AC_INIT(collectd, m4_esyscmd(./version-gen.sh)) ++AC_INIT(collectd, @@VERSION@@) + AC_CONFIG_SRCDIR(src/collectd.c) + AC_CONFIG_HEADERS(src/config.h) + diff --git a/collectd.apache2.conf b/collectd.apache2.conf new file mode 100644 index 0000000..2db987e --- /dev/null +++ b/collectd.apache2.conf @@ -0,0 +1,16 @@ + + ScriptAlias /collectd /srv/www/collectd/collection.cgi + + # Access control: + + Order allow,deny + + # You might want to change this to avoid giving everyone + # access to the collectd statistics, e.g.: + # Allow from all + # Allow from localhost + # Allow from 192.168. + Deny from all + + + diff --git a/collectd.changes b/collectd.changes new file mode 100644 index 0000000..694fe99 --- /dev/null +++ b/collectd.changes @@ -0,0 +1,494 @@ +------------------------------------------------------------------- +Tue Dec 21 14:27:22 UTC 2010 - lslezak@suse.cz + +- fixed packaging on openSUSE-11.4 - some perl-files are not + generated, disabled plugin-notify-desktop - it doesn't build + +------------------------------------------------------------------- +Thu Dec 9 12:11:28 UTC 2010 - schubi@novell.com + +- Update to version 4.9.4 in order to fix security issue: + CVE-2010-4336 + +------------------------------------------------------------------- +Sun Jul 11 00:00:58 UTC 2010 - pascal.bleser@opensuse.org + +- update to 4.10.1: + * the shutdown speed when terminating the read threads has been improved + * libcollectdclient: a format error in the PUTVAL command has been removed + * DF plugin: an error message shown when cu_mount_getlist fails has been added + * Processes plugin: missing initialization code for IO members of a struct has been added + * Python plugin: memory leaks in the write and notification callbacks have been fixed; a possible crash when the plugin was loaded but not configured has been fixed + * SNMP plugin: verbosity with regard to unknown ASN types has been increased + * PowerDNS plugin: compatibility changes for PowerDNS 2.9.22 and above have been applied + +- changes from 4.10.0: + * JSON output now includes the dstypes and dsnames fields + * the new Timeout option can be used to specify a timeout for missing values + * Apache plugin: support for IdleWorkers (Apache 1.*: IdleServers) has been added + * cURL plugin: the new ExcludeRegex allows to easily exclude certain lines from the match + * cURL-XML plugin: new plugin allows to read XML files using cURL and extract metrics included in the files + * FileCount plugin: the new IncludeHidden option allows to include hidden files and directories in the statistics + * LogFile plugin: the new PrintSeverity option allows to include the severity of a message in the output + * memcachec plugin: the new ExcludeRegex allows to easily exclude certain lines from the match + * Modbus plugin: new plugin allows to read registers from Modbus-TCP enabled devices + * Network plugin: new Interface option allows to set the interface to be used for multicast and, if supported, unicast traffic + * OpenVPN plugin: the CollectUserCount and CollectIndividualUsers options allow more detailed control over how to report sessions of multiple users + * Pinba plugin: new plugin receives timing information from the Pinba PHP extension, which can be used for profiling PHP code and webserver performance + * Ping plugin: new MaxMissed allows to re-resolve a hosts address when it doesn't reply to a number of ping requests + * PostgreSQL plugin: the Interval config option has been added; the plugin has been relicensed under the 2-clause BSD license + * Processes plugin: support for code and data virtual memory sizes has been added + * Python plugin: support for Python 3 has been implemented + * RouterOS plugin: support for collecting CPU load, memory usage, used and free disk space, sectors written and number of bad blocks from MikroTik devices has been added + * Swap plugin: support for Linux < 2.6 has been added + * Tail plugin: the new ExcludeRegex allows to easily exclude certain lines from the match + * Write HTTP plugin: the StoreRates option has been added + * RegEx match: the Invert option has been added + +- bumped in-tree libnetlink_version version from 2.6.33 to 2.6.34 + +------------------------------------------------------------------- +Fri Apr 23 12:32:21 UTC 2010 - pascal.bleser@opensuse.org + +- bumped in-tree libnetlink_version version from 2.6.29-1 to 2.6.33 + +- update to 4.9.2: + * append a newline to messages written to STDERR. + * serialization of NANs in JSON format has been fixed + * checks whether a "sleep" returned early have been added + * continue reading files in a directory when parsing one file fails + * Apache plugin: collection of the number of active connections has been fixed for Apache 2.* + * Exec plugin: error messages have been improved; the "running" flag is now cleared correctly when forking a child fails + * IPTables plugin: fix a violation of aliasing rules + * Java plugin: the Java API files are now packaged into a .jar file + * Network plugin: fix a segmentation fault when receiving packets with an unknown data source type + * Network plugin: a memory leak when receiving encrypted network packets has been fixed + * Oracle plugin: fix checking for lost connections and reconnect in this case + * UnixSock plugin: a memory leak in the "LISTVAL" command has been fixed + * Write HTTP plugin: use the "any" authentication schema, used to be "digest" + +------------------------------------------------------------------- +Fri Jan 15 23:35:19 UTC 2010 - pascal.bleser@opensuse.org + +- update to 4.9.1: + * RRDtool plugin: fix a bug with random write timeouts: due to an + incorrect initialization some files may be suspended basically + indefinitely; after flushing the files they were written + regularly again + * documentation: some manpage fixes + * default config: added sample configuration for missing plugins + * apache plugin: fix a segmentation fault in the config handling + of VerifyPeer / VerifyHost + * processes plugin: fix handling of derive data sources + * RouterOS plugin: use the node name for the "host" field + * monitorus plugin: put the plugin into the "Collectd::Plugins" + namespace + * Perl bindings: fix a warning that was printed when building + debugging output + +------------------------------------------------------------------- +Mon Dec 21 13:40:31 UTC 2009 - pascal.bleser@opensuse.org + +- update to 4.9.0: + * new plugins: NetApp, Python, RouterOS, ContextSwitch, Monitorus, + OpenVZ + * timing information is now collected in the cURL plugin + * the possibility to set the source address and device used has + been added to the Ping plug-in + * the detail provided by the DF plug-in has been enhanced + * collection of IO-metrics has been added to the Processes plugin + +------------------------------------------------------------------- +Sat Dec 19 23:11:00 UTC 2009 - pascal.bleser@opensuse.org + +- update to 4.8.2: + * fixes a memory leak in the "listval" command + * adds detection of dead connections and reconnection in the GenericJMX and Oracle plugins + * fixes handling of negative values and hex strings has been corrected in the SNMP plugin + * improved treatment of error messages when no log plugin was loaded + +- build memcachec and dbi plugins + +------------------------------------------------------------------- +Wed Oct 7 00:00:00 CEST 2009 - pascal.bleser@opensuse.org + +- split out -virt plugin package to avoid depending on libvirt.so and libxenstore.so + in the main package +- more preconfigured integration and documentation mangling for files under contrib/ +- split out spamassassin contrib files into their own package, properly preconfigured +- fix Apache2 configuration file in -web subpackage + +------------------------------------------------------------------- +Sun Oct 4 00:00:00 CEST 2009 - pascal.bleser@opensuse.org + +- update to 4.8.1: + * UnixSock plugin: fix a (well hidden) race condition related to file descriptor handling + +- changes from 4.8.0: + * collectd: two new data source types, DERIVE and ABSOLUTE, have been added: DERIVE can be used for counters that are reset occasionally + * thresholds: the advanced threshold options “Percentage”, “Hits”, and “Hysteresis” have been added + * cURL-JSON plugin: the new cURL-JSON plugin reads JSON files using the cURL library and parses the contents according to user specification; among other things, this allows to read statistics from a CouchDB instance + * DF plugin: using the new “ReportByDevice” option the device rather than the mount point can be used to identify partitions + * DNS plugin: the possibility to ignore numeric QTypes has been added + * GenericJMX plugin: the new, Java-based GenericJMX plugin allows to query arbitrary data from a Java process using the Java Management Extensions (JMX) + * MadWifi plugin: the new MadWifi plugin collects information about Atheros wireless LAN chipsets from the MadWifi driver + * network plugin: the receive- and send-buffer-sizes have been made configurable, allowing for bigger and smaller packets + * olsrd plugin: the new OLSR plugin queries routing information from the Optimized Link State Routing daemon + * RRDtool plugin: a new configuration option allows to define a random write delay when writing RRD files; this spreads the load created by writing RRD files more evenly + * Swap plugin: the possibility to collect swapped in/out pages has been added to the Swap plugin + * TokyoTyrant plugin: the new TokyoTyrant plugin reads the number of records and file size from a running Tokyo Tyrant server + * UnixSock plugin: add the GETTHRESHOLD command: this command can be used to query the thresholds configured for a particular identifier + * Write HTTP plugin: the new Write HTTP plugin sends the values collected by collectd to a web-server using HTTP POST requests + * Empty Counter match: the new Empty Counter match matches value lists, where at least one data source is of type COUNTER and the counter value of all counter data sources is zero + +------------------------------------------------------------------- +Sat Sep 26 00:00:00 CEST 2009 - kkaempf@suse.de + +- temporarily disable perl plugin for opensuse 11.2, must fix configure check first + +------------------------------------------------------------------- +Mon Jul 27 00:00:00 CEST 2009 - pascal.bleser@opensuse.org + +- update to 4.7.2: + * several bugs in the threshold and notification subsystems have been fixed + * portability of the “memcached” plug-in has been improved + +------------------------------------------------------------------- +Wed May 13 00:00:00 CEST 2009 - pascal.bleser@opensuse.org + +- update the in-tree libnetlink to 2.6.29-1 +- added missing ldconfig for libcollectclient0 +- update to 4.7.0: + * apache plugin: support to query multiple servers has been added + * apache plugin: handling of lighttpd's scoreboard statistics has been improved + * conntrack plugin: the new conntrack plugin collects the connection tracking table size + * fscache plugin: the new fscache plugin collects statistics about Linux' file-system based caching framework + * gmond plugin: the new gmond plugin can receive and interpret multicast traffic from Ganglia's gmond daemon + * java plugin: the new java plugin exports the collectd API to Java, making it possible to write extensions to collectd in Java + * memcachec plugin: the new memcachec plugin queries data from a memcached daemon and parses it similar to the cURL plugin + * memcached plugin: support for connections over UNIX domain sockets has been added + * mysql plugin: support to query multiple databases has been added + * mysql plugin: master/slave statistics have been added + * mysql plugin: lock statistics have been added + * network plugin: the possibility to sign or encrypt network traffic has been added + * protocols plugin: the new protocols plugin provides information about network protocols, such as IP, TCP and UDP + * snmp plugin: the intervals given in the configuration of the SNMP plugin must no longer be a multiple of the global interval + * table plugin: the new Table plugin provides parsing for table-like structured files, such as many files beneath /proc + * ted plugin: the new TED plugin reads power consumption measurements from “The Energy Detective” (TED) + * onewire plugin: the new Interval option allows collecting information from OneWire sensors at arbitrary intervals + * ping plugin: support for collecting the drop rate and standard deviation of round-trip times has been added + * uptime plugin: the new uptime plugin can collect the server's uptime + +------------------------------------------------------------------- +Thu Mar 19 00:00:00 CET 2009 - pascal.bleser@opensuse.org + +- update to 4.6.2: + * collection of the number of cached RR-sets has been fixed in the "BIND" plugin + * filter chains can now be configured without a default target + * portability fixes have been added to the "DNS" and "Oracle" plugins + * a typo that prevented the module from being used correctly has been + corrected in the "TimeDiff" match + * a possible race condition during startup has been fixed in the "RRDtool" plugin + +------------------------------------------------------------------- +Mon Feb 23 00:00:00 CET 2009 - pascal.bleser@opensuse.org + +- update to 4.6.1: + * fixes an off-by-one error in the IPMI plugin + * fixes smaller problems in the BIND plugin + * documentation fixes +- upgrade in-tree libnetlink (iproute2) library to latest (2.6.28) + +------------------------------------------------------------------- +Tue Feb 17 00:00:00 CET 2009 - guru@unixtech.be + +- fix build on 11.1, make rpmlint happy + +------------------------------------------------------------------- +Mon Oct 20 00:00:00 CEST 2008 - guru@unixtech.be + +- only expect the virt plugin on >=11.0 as collectd now requires a more + recent libvirt (>=0.4.0, for virDomainBlockStats) + +------------------------------------------------------------------- +Sat Oct 18 00:00:00 CEST 2008 - guru@unixtech.be + +- moved collectd-snmp manpage to -snmp subpackage +- update to 4.5.1: + * fix a memory leak in the global value cache and configuration handling + code + * fix an off-by-one error in the ignorelist functionality + * collectdmon: don't block SIGCHLD, fixes a potential portability problem + * collectd-nagios: fix handling of the -d option + * iptables plugin (4.5.1 only): fix an off-by-one error + * perl plugin: log an error message if bootstrapping Collectd fails + * postgresql plugin (4.5.1 only): don't reopen connection during + reinitialization + * snmp plugin (4.5.1 only): don't expect null-terminated strings from the + Net-SNMP library + * tail plugin: call clearerr(3) after reading an EOF + +------------------------------------------------------------------- +Fri Sep 12 00:00:00 CEST 2008 - guru@unixtech.be + +- added a patch to remove poisoning of strcpy on openSUSE < 11.0, + as it is replaced by a safe bounds-checking variant using a #define + +------------------------------------------------------------------- +Thu Sep 11 00:00:00 CEST 2008 - guru@unixtech.be + +- added postgresql subpackage +- moved mysql into own subpackage +- added libvirt, filecount, notify_desktop and thermal plugins +- bump the in-tree iproute2 to 2.6.26 +- update to 4.5.0: + * fix a memory leak in the threshold checking code + * memcached plugin: fix a too short timeout and a related file descriptor + leak + * memory plugin: a typo in the libstatgrab code has been fixed + * snmp plugin: fix a possible memory leak + +------------------------------------------------------------------- +Thu May 8 00:00:00 CEST 2008 - guru@unixtech.be + +- well-defined list of plugins to avoid unpredictable build results caused + by missing dependencies (i.e. missing plugins) +- added XMMS plugin (as a separate subpackage) +- added OpenIPMI plugin (as a separate subpackage) +- use bundled libnetlink (from iproute2) as the one that ships with openSUSE + is not build with -fPIC, which causes linking to fail on x86_64 +- split out a few plugins to avoid dependencies in the main package +- new upstream version + +------------------------------------------------------------------- +Thu Apr 24 00:00:00 CEST 2008 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Wed Apr 2 00:00:00 CEST 2008 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Wed Feb 20 00:00:00 CET 2008 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Tue Jan 22 00:00:00 CET 2008 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Tue Dec 18 00:00:00 CET 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Sat Nov 10 00:00:00 CET 2007 - guru@unixtech.be + +- new upstream version +- promoted beta to stable + +------------------------------------------------------------------- +Thu Oct 25 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Oct 1 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Thu Sep 13 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version +- forked off -beta + +------------------------------------------------------------------- +Wed Sep 12 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version +- moved to openSUSE Build Service + +------------------------------------------------------------------- +Thu Aug 30 00:00:00 CEST 2007 - guru@unixtech.be + +- added --disable-nut, made the build fail +- new upstream version + +------------------------------------------------------------------- +Tue Aug 14 00:00:00 CEST 2007 - guru@unixtech.be + +- fixed commented defaults in configuration file +- fixed init script +- dropped sysconfig +- fixed access rights on init script, thanks to Detlef for reporting + +------------------------------------------------------------------- +Sat Aug 4 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Jun 25 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Thu Jun 21 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Sun Jun 17 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Thu Jun 7 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Jun 4 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Wed May 30 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Wed Apr 11 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Apr 2 00:00:00 CEST 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Feb 12 00:00:00 CET 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Sat Feb 10 00:00:00 CET 2007 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Fri Nov 3 00:00:00 CET 2006 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Fri Jul 21 00:00:00 CEST 2006 - guru@unixtech.be + +- added %%{_sysconfdir}/collectd.conf +- new upstream version + +------------------------------------------------------------------- +Fri Jun 16 00:00:00 CEST 2006 - guru@unixtech.be + +- added mysql support on SUSE >= 9.3 (older versions don't have the required version >= 4.1.0) +- moved configure to build section +- new upstream version + +------------------------------------------------------------------- +Mon May 15 00:00:00 CEST 2006 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Thu Apr 20 00:00:00 CEST 2006 - guru@unixtech.be + +- added patch to fix a warning with a pointer diff being passed to printf +- added stripping of binaries on SUSE < 9.3 +- removed Packager and Distribution, injected by rpmmacros +- new upstream version + +------------------------------------------------------------------- +Tue Apr 11 00:00:00 CEST 2006 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Fri Apr 7 00:00:00 CEST 2006 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Tue Mar 14 00:00:00 CET 2006 - guru@unixtech.be + +- new upstream version +- added BuildRequires for suse-release +- removed explicit Requires that are found by AutoReqProv + +------------------------------------------------------------------- +Tue Jan 31 00:00:00 CET 2006 - guru@unixtech.be + +- new upstream version +- added manpage for collectd.conf +- added SMP flags to make + +------------------------------------------------------------------- +Tue Jan 24 00:00:00 CET 2006 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Dec 26 00:00:00 CET 2005 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Mon Dec 5 00:00:00 CET 2005 - guru@unixtech.be + +- small fixes to Requires section +- new upstream version + +------------------------------------------------------------------- +Wed Nov 9 00:00:00 CET 2005 - guru@unixtech.be + +- had to specify --enable-serial to build the serial collect module (only on Linux) +- sanitized spec file +- new upstream version + +------------------------------------------------------------------- +Fri Oct 28 00:00:00 CEST 2005 - guru@unixtech.be + +- new upstream version + +------------------------------------------------------------------- +Wed Oct 5 00:00:00 CEST 2005 - guru@unixtech.be + +- made rc-link in sbin conditional (SUSE) +- moved sysconfig file to fillup +- added debuginfo support +- new upstream version + +------------------------------------------------------------------- +Mon Sep 19 00:00:00 CEST 2005 - guru@unixtech.be + +- dropped no-chown patch +- added manpage +- added runtime dependency to libping-dping +- added build dependency to libstatgrab +- new upstream version: 2.1.0 + +------------------------------------------------------------------- +Mon Aug 22 00:00:00 CEST 2005 - guru@unixtech.be + +- version 1.6.0 + +------------------------------------------------------------------- +Mon Aug 8 00:00:00 CEST 2005 - guru@unixtech.be + +- new package + diff --git a/collectd.spec b/collectd.spec new file mode 100644 index 0000000..6740586 --- /dev/null +++ b/collectd.spec @@ -0,0 +1,833 @@ +# norootforbuild + +# TODO: +# libtokyotyrant (tcrdb.h) +# libkvm +# libupsclient (.pc) +# liboconfig +# libyajl (yajl/yajl_parse.h) +# ? oracle ($ORACLE_HOME) +# curl_json +# gmond +# rrdcached +# + +%if 0%{?_with_xmms:1}0 || 0%{?suse_version} <= 1020 +%define xmms 1 +%else +%define xmms 0 +%endif + +%if 0%{?_with_java:1} || 0%{?suse_version} > 1030 && ! 0%{?_without_java:1} && ! 0%{?sles_version} +%define java 1 +%else +%define java 0 +%endif + +%if 0%{?_with_virt:1} || 0%{?suse_version} > 1030 +%define virt 1 +%else +%define virt 0 +%endif + +%if ! 0%{?_without_dbi:1} +%define dbi 1 +%else +%define dbi 0 +%endif + +%if ! 0%{?_without_memcachec:1} +%define memcachec 1 +%else +%define memcachec 0 +%endif + +%if 0%{?suse_version} < 1000 || 0%{?suse_version} > 1130 +%define libnotify 0 +%else +%define libnotify 1 +%endif + +%if 0%{?suse_version} > 1020 +%define snmp 1 +%define ipmi 1 +%define ascent 1 +%define ascent_plugin ascent +%define iptables 1 +%define iptables_plugin iptables +%else +%define snmp 0 +%define ipmi 0 +%define ascent 0 +%define ascent_plugin %{nil} +%define iptables 0 +%define iptables_plugin %{nil} +%endif + +%if 0%{?suse_version} >= 1110 +%define madwifi_plugin madwifi +%else +%define madwifi_plugin %{nil} +%endif + +%if 0%{?suse_version} >= 1130 +%define rrdcached_plugin rrdcached +%else +%define rrdcached_plugin %{nil} +%endif + +%define libnetlink_version 2.6.34 + +%define plugins apache apcups battery bind curl curl_xml conntrack contextswitch cpu cpufreq csv df disk dns email entropy exec filecount fscache hddtemp interface ipvs irq load logfile match_empty_counter match_hashed match_regex match_timediff match_value mbmon memcached memory multimeter netlink network nfs nginx ntpd olsrd openvpn perl ping protocols powerdns processes rrdtool sensors serial swap syslog table tail target_notification target_replace target_scale target_set tcpconns teamspeak2 ted thermal unixsock uptime users uuid vmem vserver wireless write_http %{expand:%ascent_plugin} %{expand:%iptables_plugin} %{expand:%madwifi_plugin} %{expand:%rrdcached_plugin} + +Name: collectd +Version: 4.10.2 +Release: 0 +Summary: Statistics Collection Daemon for filling RRD Files +Source: http://collectd.org/files/collectd-%{version}.tar.bz2 +Source1: collectd.suse.init +Source2: collectd.apache2.conf +Source3: collectd-js.apache2.conf +# bundled/in-tree libnetlink.a, see http://mailman.verplant.org/pipermail/collectd/2007-October/001210.html +Source10: http://devresources.linux-foundation.org/dev/iproute2/download/iproute2-%{libnetlink_version}.tar.bz2 +# workaround for missing pthread.pc on openSUSE, required by OpenIPMIpthread.pc +# see https://bugzilla.novell.com/show_bug.cgi?id=388026 +Source20: collectd-pthread.pc +Patch4: collectd-lib64.patch +Patch7: collectd-fix-config.patch +Patch9: collectd-version.patch +Patch10: collectd-perl-vendor.patch +# see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=467072 +Patch11: collectd-fix_broken_perl-5.10.patch +Patch12: collectd-fix-warnings.patch +Patch14: collectd-iproute2-HZ.patch +Patch16: iproute2-optflags.patch +Patch17: collectd-fix_libltdl_autoreconf.patch +Patch18: collectd-fix_collection_cgi.patch +Patch19: collectd-fix_spamassassin_doc.patch +Patch20: collectd-split_README.patch +Patch21: collectd-fix_collectd_config_path_in_snmp_probe.patch +Patch22: collectd-collection3.patch +URL: http://collectd.org/ +Group: System/Monitoring +License: GNU General Public License (GPL) +BuildRoot: %{_tmppath}/build-%{name}-%{version} +Requires: sensors rrdtool +BuildRequires: sensors rrdtool libpng-devel zlib-devel perl +BuildRequires: libstatgrab-devel gettext gettext-devel intltool bind-devel +%if 0%{?suse_version} > 1020 +BuildRequires: libdb-4_5-devel +%else +BuildRequires: db-devel +%endif +%if 0%{?suse_version} > 910 +BuildRequires: libgcrypt-devel +%else +BuildRequires: libgcrypt +%endif +BuildRequires: liboping-devel +BuildRequires: make gcc autoconf automake libtool pkgconfig +BuildRequires: freetype2-devel libart_lgpl-devel +BuildRequires: python-devel +%if %libnotify +BuildRequires: libnotify-devel gtk2-devel +%endif +%if %java +BuildRequires: java-devel +%endif #java +# for /etc/apache2/... ownership (rpmlint): +BuildRequires: apache2 +%if %suse_version >= 1000 +BuildRequires: libesmtp-devel +%endif +BuildRequires: xfsprogs-devel +%if %suse_version >= 930 +BuildRequires: mysql-devel >= 4.1.0 +%endif +BuildRequires: postgresql-devel +%if %suse_version >= 1030 +BuildRequires: rrdtool-devel +BuildRequires: libcurl-devel +%else +BuildRequires: curl-devel +%endif +BuildRequires: libxml2-devel +%if %ipmi +# for ipmi: +BuildRequires: OpenIPMI-devel gdbm-devel +%endif #ipmi +%if %snmp +# for snmp: +BuildRequires: net-snmp-devel +%endif #snmp +# for ipvs and madwifi: +BuildRequires: linux-kernel-headers kernel-source +%if %suse_version >= 1030 +BuildRequires: libpcap-devel +%endif +BuildRequires: libpcap +%if %xmms +# for xmms: +BuildRequires: xmms-devel +%endif +%if %virt +# for libvirt: +BuildRequires: libvirt-devel +%endif +%if %dbi +BuildRequires: libdbi-devel +%endif +%if %memcachec +BuildRequires: libmemcached-devel +%endif +# in case we'd like to split it later: +Provides: collectd-perl = %{version}-%{release} +PreReq: %fillup_prereq +PreReq: %insserv_prereq +# play nice with collectd-beta: +Obsoletes: collectd-beta < %{version} +Provides: collectd-beta = %{version}-%{release} + +%description +collectd is a small daemon written in C for performance. It reads various +system statistics and updates RRD files, creating them if necessary. +Since the daemon doesn't need to startup every time it wants to update the +files it's very fast and easy on the system. Also, the statistics are very +fine grained since the files are updated every 10 seconds. + + + + +Authors: +-------- + Florian octo Forster + +%package web +Summary: Web Frontend for watching the %{name} Statistics +Group: System/Monitoring +Requires: perl apache2 rrdtool +Requires: perl(Data::Dumper) +Requires: perl(CGI) +Requires: perl(HTML::Entities) +Requires: perl(URI::Escape) +Requires: rrdtool + +%description web +Web frontend CGI for watching %{name} statistics from a browser. + +Please look at /etc/apache2/conf.d/%{name}.conf on how to enable. + +%package web-js +Summary: Web/JavaScript Frontend for watching %{name} Statistics +Group: System/Monitoring +Requires: perl apache2 rrdtool +Requires: perl(Data::Dumper) +Requires: perl(CGI) +Requires: perl(RRDs) +Requires: perl(HTML::Entities) +Requires: perl(JSON) +Requires: perl(Config::General) + +%description web-js +Web/JavaScript frontend CGI for watching %{name} statistics from +a browser. + +Please look at /etc/apache2/conf.d/%{name}-js.conf on how to +enable. + +%if %libnotify +%package plugin-notify-desktop +Summary: Desktop Notification Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-notify-desktop +Desktop Notification Support for %{name} +%endif #libnotify + +%if %ipmi +%package plugin-ipmi +Summary: OpenIPMI Monitoring Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-ipmi +Optional %{name} plugin to monitor sensors using the OpenIPMI +library, for IPMI enabled systems. +%endif #ipmi + +%if %snmp +%package plugin-snmp +Summary: SNMP Monitoring Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} +Requires: perl(SNMP) +Requires: perl(Socket6) +Requires: perl(Config::General) + +%description plugin-snmp +Optional %{name} plugin to monitor devices using SNMP. +%endif #snmp + +%if %suse_version >= 930 +%package plugin-mysql +Summary: MySQL Monitoring Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-mysql +Optional %{name} plugin to monitor MySQL server instances. +%endif + +%package plugin-postgresql +Summary: PostgreSQL Monitoring Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-postgresql +Optional %{name} plugin to monitor PostgreSQL server instances. + +%package plugin-python +Summary: Python API for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-python +Optional %{name} Python API in order to write %{name} plugins in +Python. + +%if %java +%package plugin-java +Summary: Java API for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-java +Optional %{name} Java API in order to write %{name} plugins in +Java. +%endif #java + +%if %virt +%package plugin-virt +Summary: Virtual Machine Statistics Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-virt +Optional %{name} plugin to gather statistics from virtual +machines using libvirt. +%endif + +%if %xmms +%package plugin-xmms +Summary: XMMS Monitoring Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-xmms +Optional %{name} plugin to gather sampling frequencies and file +bitrates of files played with XMMS. +%endif #xmms + +%if %dbi +%package plugin-dbi +Summary: DBI Storage Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-dbi +Optional %{name} plugin to store sampling results into +various databases as supported by libdbi. +%endif #dbi + +%if %memcachec +%package plugin-memcachec +Summary: Memcache Daemon Monitoring Plugin for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} + +%description plugin-memcachec +Optional %{name} plugin to sample memcached statistics. +%endif #memcachec + +%package plugins-all +Summary: All Monitoring Plugins for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} +%if %ipmi +Requires: %{name}-plugin-ipmi = %{version}-%{release} +%endif #ipmi +%if %snmp +Requires: %{name}-plugin-snmp = %{version}-%{release} +%endif #snmp +%if %suse_version >= 930 +Requires: %{name}-plugin-mysql = %{version}-%{release} +%endif #suse >= 930 +Requires: %{name}-plugin-postgresql = %{version}-%{release} +%if %java +Requires: %{name}-plugin-java = %{version}-%{release} +%endif #java +%if %virt +Requires: %{name}-plugin-virt = %{version}-%{release} +%endif #virt +Requires: %{name}-web = %{version}-%{release} +Requires: %{name}-web-js = %{version}-%{release} +%if %libnotify +Requires: %{name}-plugin-notify-desktop = %{version}-%{release} +%endif #libnotify +Requires: %{name}-plugin-python = %{version}-%{release} +%if %dbi +Requires: %{name}-plugin-dbi = %{version}-%{release} +%endif #dbi +%if %memcachec +Requires: %{name}-plugin-memcachec = %{version}-%{release} +%endif #memcachec + +%description plugins-all +Metapackage that installs %{name} and all the available +monitoring plugin subpackages, except %{name}-plugin-xmms + +%package spamassassin +Summary: Spamassassin Monitoring for %{name} +Group: System/Monitoring +Requires: %{name} = %{version}-%{release} +Requires: perl-spamassassin + +%description spamassassin +Plugin for filling %{name} with statistics from the +SpamAsssassin anti-spam engine. + +%package -n libcollectdclient0 +Summary: Library for %{name} clients +Group: System/Monitoring +Provides: libcollectdclient = %{version}-%{release} + +%description -n libcollectdclient0 +Library which abstracts communication with the %{name} +unixsock plugin for clients. + +%package -n libcollectdclient-devel +Summary: Development Environment for %{name} clients +Group: Development/Libraries/C and C++ +Requires: libcollectdclient0 = %{version}-%{release} + +%description -n libcollectdclient-devel +Library which abstracts communication with the %{name} +unixsock plugin for clients. +This package contains the required development environment +to write %{name} unixsock clients. + +%prep +%setup -q -n "collectd-%{version}" -a 10 +%if "%{_lib}"=="lib64" +%patch4 +%endif +%patch7 +%patch9 +%patch10 +%patch11 +%patch12 +%patch17 +pushd "iproute2-%{libnetlink_version}" +%patch14 +%patch16 +popd #iproute2 +%patch18 +%patch19 +%patch20 +%patch21 +%patch22 + +%__sed -i 's|@@VERSION@@|%{version}|g' configure.in + +# workaround for missing pthread.pc on openSUSE, required by OpenIPMIpthread.pc +%__install -D -m0644 "%{SOURCE20}" pkgconfig/pthread.pc +%__sed 's|@@LIB@@|%{_lib}|g' pkgconfig/pthread.pc + +# unneeded files: +%__rm -fr \ + contrib/fedora \ + contrib/solaris-smf \ + contrib/redhat \ + contrib/sles* + +# remove -Werror everywhere +find . -name 'configure*' -o -name 'Makefile*' -exec %__sed -i 's|-Werror||g' {} \; + +%build +export SUSE_ASNEEDED=0 + +# build in-tree libnetlink.a +pushd "iproute2-%{libnetlink_version}" +LIBNETLINK_CFLAGS="%{optflags}" +%ifarch x86_64 ia64 ppc64 ppc64 s390x +# only add -fPIC on 64bit, to avoid performance drawback on non-64bit archs: +LIBNETLINK_CFLAGS="$LIBNETLINK_CFLAGS -fPIC" +%endif +%__make %{?jobs:-j%{jobs}} \ + SUBDIRS="lib" \ + CC="%__cc" \ + OPTFLAGS="$LIBNETLINK_CFLAGS" +%__ln_s lib lib64 +popd #iproute2 + +autoreconf -fiv + +# set JAVA_HOME properly +[ -n "$JAVA_HOME" -a -d "$JAVA_HOME" ] || export JAVA_HOME="%{_usr}/%{_lib}/jvm/java" +[ -n "$JDK_HOME" -a -d "$JDK_HOME" ] || export JDK_HOME="$JAVA_HOME" +[ -n "$JRE_HOME" -a -d "$JRE_HOME" ] || export JRE_HOME="$JAVA_HOME" +export PATH="$JDK_HOME/bin:$JRE_HOME/bin:$JAVA_HOME/bin:$PATH" + +# add /usr/src/linux to include path to find net/ip_vs.h: +export CFLAGS="%{optflags} -I$PWD/iproute2-%{libnetlink_version}/include/ -fno-strict-aliasing" +export CXXFLAGS="$CFLAGS" +# workaround for missing pthread.pc on openSUSE, required by OpenIPMIpthread.pc +export PKG_CONFIG_PATH="$PWD/pkgconfig:$PKG_CONFIG_PATH" +export KERNEL_DIR=/usr/src/linux +%configure \ + --with-libstatgrab \ + --with-rrdtool \ + --disable-static \ + --enable-dns \ + --disable-nut \ + --enable-netlink \ + --enable-python \ +%if %iptables + --enable-iptables \ +%else + --disable-iptables \ + --without-iptc \ +%endif #iptables +%if %ascent + --enable-ascent \ +%else + --disable-ascent \ +%endif #ascent +%if %ipmi + --enable-ipmi \ +%else + --disable-ipmi \ +%endif #ipmi +%if %java + --enable-java \ + --with-java="$JAVA_HOME/" \ +%else + --disable-java \ +%endif #java +%if %dbi + --enable-dbi \ +%else + --disable-dbi \ +%endif #dbi +%if %memcachec + --enable-memcached \ +%else + --disable-memcached \ +%endif #memcachec + --with-libnetlink="$PWD/iproute2-%{libnetlink_version}/" \ +%if %suse_version < 930 + --disable-mysql \ +%endif +%ifos linux + --enable-serial +%else + --disable-serial +%endif #os linux + +%__make %{?jobs:-j%{jobs}} + +%install +%makeinstall + +# delete .la files +%__rm -f "%{buildroot}%{_libdir}"/*.{a,la} +%__rm -f "%{buildroot}%{_libdir}/collectd"/*.a + +%__sed -i '/^dependency_libs=/ s|-L'"${RPM_BUILD_DIR}/%{name}-%{version}"'/src||g' "%{buildroot}%{_libdir}/collectd/python.la" + +%if !%java +%__rm -f "%{buildroot}%{_mandir}/man5"/collectd-java.5* +%__rm -rf "%{buildroot}%{_datadir}/collectd/java" +%endif #!java +%__mkdir_p _rpmdoc_/java +%__mv contrib/GenericJMX.conf _rpmdoc_/java/ + +# fix bogus dependency in netlink.la, as it has been built against +# a static netlink library: +%__sed -i "/^dependency_libs=/s/=.*/=''/" \ + "%{buildroot}%{_libdir}/collectd/netlink.la" + +# fix permissions: +%__chmod 0755 "%{buildroot}%{_libdir}/collectd"/*.so +%__chmod 0644 "%{buildroot}%{_libdir}/collectd"/*.la + +# create /var/lib/collectd to add it to the %files section: +%__install -d -m 0755 "%{buildroot}%{_localstatedir}/lib/collectd" + +# init script: +%__install -D -m 0755 "%{SOURCE1}" "%{buildroot}/etc/init.d/collectd" +%__install -d -m 0755 "%{buildroot}/usr/sbin" +%__ln_s "../../etc/init.d/collectd" "%{buildroot}/usr/sbin/rccollectd" + +# Apache2 configuration for the CGI frontend: +%__install -D -m 0644 "%{SOURCE2}" "%{buildroot}/etc/apache2/conf.d/%{name}.conf" +%__install -D -m 0755 contrib/collection.cgi "%{buildroot}/srv/www/collectd/collection.cgi" +%__install -D -m 0644 contrib/collection.conf "%{buildroot}%{_sysconfdir}/collectd/collection.conf" +%__sed -i 's|@@LIBDIR@@|%{_libdir}|g' "%{buildroot}%{_sysconfdir}/collectd/collection.conf" +# remove it from contrib, to avoid having it end up in the main package as well: +%__rm contrib/collection.cgi contrib/collection.conf + +%perl_process_packlist + +# web-js CGI frontend (_must_ be installed _after_ perl_process_packlist) +%__install -d "%{buildroot}/srv/www/collectd-js" +%__mkdir_p _rpmdoc_/web-js +%__mv contrib/collection3/README _rpmdoc_/web-js/README +find contrib/collection3/ -name .htaccess -exec %__rm {} \; +%__cp -a \ + contrib/collection3/bin/* \ + contrib/collection3/share/* \ + "%{buildroot}/srv/www/collectd-js/" +%__mkdir_p "%{buildroot}%{_usr}/lib/collectd-js" +%__mv contrib/collection3/lib/* "%{buildroot}%{_usr}/lib/collectd-js/" + +%__install -D -m 0644 contrib/collection3/etc/collection.conf \ + "%{buildroot}%{_sysconfdir}/collectd/collection-js.conf" +%__rm -fr contrib/collection3/etc +%__install -D -m 0644 "%{SOURCE3}" "%{buildroot}/etc/apache2/conf.d/%{name}-js.conf" + +# spamassassin (_must_ be installed _after_ perl_process_packlist) +%__install -D -m0644 contrib/SpamAssassin/example.cf \ + "%{buildroot}%{_datadir}/spamassassin/99_%{name}.cf" +%__install -D -m0644 contrib/SpamAssassin/Collectd.pm \ + "%{buildroot}%{perl_vendorlib}/Mail/SpamAssassin/Plugin/Collectd.pm" +pod2man \ + contrib/SpamAssassin/Collectd.pm \ + > "%{buildroot}%{perl_man3dir}/Mail::SpamAssassin::Plugin::Collectd.%{perl_man3ext}" +%__rm -rf contrib/SpamAssassin + +# cussh script from contrib: +%__install -m0755 contrib/cussh.pl "%{buildroot}%{_bindir}/cussh" +%__install -d "%{buildroot}%{_mandir}/man1" +pod2man \ + -c "Collectd UNIX Socket Shell" \ + -n "CUSSH" \ + -s 1 \ + contrib/cussh.pl > "%{buildroot}%{_mandir}/man1/cussh.1" +%__rm contrib/cussh.pl + +# snmp: +%__mkdir_p _rpmdoc_/snmp +%__sed -n '/^snmp-data\.conf/,$ p' contrib/README > _rpmdoc_/snmp/README +%__sed -i '/^snmp-data\.conf/,$ d' contrib/README +%__mv contrib/snmp-data.conf _rpmdoc_/snmp/ +%__sed -i 's|\(\./\)snmp-probe-host\.px|collectd-snmp-probe-host|g' contrib/snmp-probe-host.px +pod2man \ + -c "Collectd SNMP Host Probe" \ + -n "COLLECTD-SNMP-PROBE-HOST" \ + -s 1 \ + contrib/snmp-probe-host.px \ + > "%{buildroot}%{_mandir}/man1/collectd-snmp-probe-host.1" +%__install -D -m0755 contrib/snmp-probe-host.px "%{buildroot}%{_bindir}/collectd-snmp-probe-host" +%__rm contrib/snmp-probe-host.px +%__install -d "%{buildroot}%{_mandir}/man1" + +find contrib/ -name '*.orig' -exec %__rm {} \; + +# plugin list: +echo -n > plugins.lst +for plugin in %{plugins}; do + for ext in so la; do + echo "%{_libdir}/collectd/${plugin}.${ext}" >> plugins.lst + done +done + +cat<README.plugins-all +This package is empty but depends on all collectd plugin subpackages. +EOF + +%preun +%stop_on_removal collectd + +%postun +%restart_on_update collectd +%insserv_cleanup + +%post +%{fillup_only collectd} + +%post -n libcollectdclient0 -p /sbin/ldconfig +%postun -n libcollectdclient0 -p /sbin/ldconfig + +%clean +%__rm -rf "%{buildroot}" + +%files -f plugins.lst +%defattr(-,root,root) +%doc AUTHORS ChangeLog COPYING README +%doc contrib +%config(noreplace) %{_sysconfdir}/collectd.conf +%dir %{_sysconfdir}/collectd +%{_bindir}/collectd-nagios +%{_bindir}/cussh +%{_sbindir}/collectd +%{_sbindir}/collectdmon +%dir %{_libdir}/collectd +%if %suse_version >= 1000 +%{_libdir}/collectd/notify_email.so +%{_libdir}/collectd/notify_email.la +%endif +%dir %{_datadir}/collectd +%{_datadir}/collectd/types.db +%{perl_vendorlib}/Collectd.pm +%dir %{perl_vendorlib}/Collectd +%{perl_vendorlib}/Collectd/* +%{perl_vendorarch}/auto/Collectd +%doc %{_mandir}/man1/collectd.1* +%doc %{_mandir}/man1/collectdmon.1* +%doc %{_mandir}/man1/collectd-nagios.1* +%doc %{_mandir}/man1/cussh.1* +%doc %{_mandir}/man5/collectd.conf.5* +%doc %{_mandir}/man5/collectd-email.5* +%doc %{_mandir}/man5/collectd-exec.5* +%doc %{_mandir}/man5/collectd-perl.5* +%doc %{_mandir}/man5/collectd-unixsock.5* +%doc %{_mandir}/man5/types.db.5* +%doc %{perl_man3dir}/Collectd::Unixsock.%{perl_man3ext}* +%dir %{_localstatedir}/lib/collectd +/etc/init.d/collectd +/usr/sbin/rccollectd +%if 0%{?suse_version} == 0 || 0%{?suse_version} <= 1130 +/var/adm/perl-modules/%{name} +%endif + +%files web +%defattr(-,root,root) +%config(noreplace) /etc/apache2/conf.d/%{name}.conf +%dir %{_sysconfdir}/collectd +%config(noreplace) %{_sysconfdir}/collectd/collection.conf +/srv/www/collectd + +%files web-js +%defattr(-,root,root) +%doc _rpmdoc_/web-js/README +%config(noreplace) /etc/apache2/conf.d/%{name}-js.conf +%dir %{_sysconfdir}/collectd +%config(noreplace) %{_sysconfdir}/collectd/collection-js.conf +/srv/www/collectd-js +%{_usr}/lib/collectd-js + +%if %libnotify +%files plugin-notify-desktop +%defattr(-,root,root) +%{_libdir}/collectd/notify_desktop.so +%{_libdir}/collectd/notify_desktop.la +%endif #libnotify + +%if %ipmi +%files plugin-ipmi +%defattr(-,root,root) +%{_libdir}/collectd/ipmi.so +%{_libdir}/collectd/ipmi.la +%endif #ipmi + +%if %snmp +%files plugin-snmp +%defattr(-,root,root) +%doc _rpmdoc_/snmp/* +%{_bindir}/collectd-snmp-probe-host +%{_libdir}/collectd/snmp.so +%{_libdir}/collectd/snmp.la +%doc %{_mandir}/man1/collectd-snmp-probe-host.1* +%doc %{_mandir}/man5/collectd-snmp.5* +%endif #snmp + +%if %suse_version >= 930 +%files plugin-mysql +%defattr(-,root,root) +%{_libdir}/collectd/mysql.so +%{_libdir}/collectd/mysql.la +%endif + +%files plugin-postgresql +%defattr(-,root,root) +%{_libdir}/collectd/postgresql.so +%{_libdir}/collectd/postgresql.la +%config %{_datadir}/collectd/postgresql_default.conf + +%files plugin-python +%defattr(-,root,root) +%{_libdir}/collectd/python.so +%{_libdir}/collectd/python.la +%doc %{_mandir}/man5/collectd-python.5* + +%if %java +%files plugin-java +%defattr(-,root,root) +%doc _rpmdoc_/java/GenericJMX.conf +%{_libdir}/collectd/java.so +%{_libdir}/collectd/java.la +%{_datadir}/collectd/java +%doc %{_mandir}/man5/collectd-java.5* +%endif #java + +%if %virt +%files plugin-virt +%defattr(-,root,root) +%{_libdir}/collectd/libvirt.so +%{_libdir}/collectd/libvirt.la +%endif #virt + +%if %xmms +%files plugin-xmms +%defattr(-,root,root) +%{_libdir}/collectd/xmms.so +%{_libdir}/collectd/xmms.la +%endif #xmms + +%if %dbi +%files plugin-dbi +%defattr(-,root,root) +%{_libdir}/collectd/dbi.so +%{_libdir}/collectd/dbi.la +%endif #dbi + +%if %memcachec +%files plugin-memcachec +%defattr(-,root,root) +%{_libdir}/collectd/memcachec.so +%{_libdir}/collectd/memcachec.la +%endif #memcachec + +%files spamassassin +%defattr(-,root,root) +%dir %{_datadir}/spamassassin +%config(noreplace) %{_datadir}/spamassassin/99_%{name}.cf +%dir %{perl_vendorlib}/Mail +%dir %{perl_vendorlib}/Mail/SpamAssassin +%dir %{perl_vendorlib}/Mail/SpamAssassin/Plugin +%{perl_vendorlib}/Mail/SpamAssassin/Plugin/Collectd.pm +%doc %{perl_man3dir}/Mail::SpamAssassin::Plugin::Collectd.%{perl_man3ext}* + +%files plugins-all +%defattr(-,root,root) +%doc README.plugins-all + +%files -n libcollectdclient0 +%defattr(-,root,root) +%{_libdir}/libcollectdclient.so.0 +%{_libdir}/libcollectdclient.so.0.*.* + +%files -n libcollectdclient-devel +%defattr(-,root,root) +%{_includedir}/collectd +%{_libdir}/libcollectdclient.so +%{_libdir}/pkgconfig/libcollectdclient.pc + +%changelog +# vim: set sw=3 ts=3 noet: +# Local Variables: +# mode: rpm-spec +# tab-width: 3 +# End: diff --git a/collectd.suse.init b/collectd.suse.init new file mode 100644 index 0000000..e68037b --- /dev/null +++ b/collectd.suse.init @@ -0,0 +1,95 @@ +#! /bin/sh +# Author: Pascal Bleser +# Please send feedback to guru@unixtech.be +# +# /etc/init.d/collectd +# and its symbolic link +# /usr/sbin/rccollectd +# +### BEGIN INIT INFO +# Provides: collectd +# Required-Start: $local_fs $remote_fs $network +# Required-Stop: $local_fs $remote_fs $network +# Default-Start: 3 5 +# Default-Stop: 0 1 2 6 +# Short-Description: Collectd daemon collecting system statistics +# Description: Start Collectd to collect system statistics +### END INIT INFO + +# Check for missing binaries (stale symlinks should not happen) +# Note: Special treatment of stop for LSB conformance +COLLECTD_BIN=/usr/sbin/collectd +test -x $COLLECTD_BIN || { echo "$COLLECTD_BIN not installed"; + if [ "$1" = "stop" ]; then exit 0; + else exit 5; fi; } + +# Check for existence of needed config file and read it +COLLECTD_CONFIG=/etc/collectd.conf +test -r $COLLECTD_CONFIG || { echo "$COLLECTD_CONFIG not existing"; + if [ "$1" = "stop" ]; then exit 0; + else exit 6; fi; } + +SERVICENAME=collectd + +. /etc/rc.status +# Reset status of this service +rc_reset + +case "$1" in + start) + echo -n "Starting $SERVICENAME " + /sbin/startproc "$COLLECTD_BIN" + rc_status -v + ;; + stop) + echo -n "Shutting down $SERVICENAME " + /sbin/killproc -TERM "$COLLECTD_BIN" + rc_status -v + ;; + try-restart|condrestart) + ## Do a restart only if the service was active before. + ## Note: try-restart is now part of LSB (as of 1.9). + ## RH has a similar command named condrestart. + if test "$1" = "condrestart"; then + echo "${attn} Use try-restart ${done}(LSB)${attn} rather than condrestart ${warn}(RH)${norm}" + fi + $0 status + if test $? = 0; then + $0 restart + else + rc_reset # Not running is not a failure. + fi + rc_status + ;; + restart) + $0 stop + $0 start + rc_status + ;; + force-reload) + echo -n "Reload service $SERVICENAME " + $0 try-restart + rc_status + ;; + reload) + rc_failed 3 + rc_status -v + ;; + status) + echo -n "Checking for service $SERVICENAME " + /sbin/checkproc $COLLECTD_BIN + rc_status -v + ;; + probe) + ## Optional: Probe for the necessity of a reload, print out the + ## argument to this init script which is required for a reload. + ## Note: probe is not (yet) part of LSB (as of 1.9) + + test "$COLLECTD_CONFIG" -nt "/var/run/collectd.pid" && echo reload + ;; + *) + echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}" + exit 1 + ;; +esac +rc_exit diff --git a/iproute2-2.6.34.tar.bz2 b/iproute2-2.6.34.tar.bz2 new file mode 100644 index 0000000..bcb5e9d --- /dev/null +++ b/iproute2-2.6.34.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f7feb3c34df4714cae0265f7629863af8b0a88550f4f38aba0ffc81a10c29bbb +size 385281 diff --git a/iproute2-optflags.patch b/iproute2-optflags.patch new file mode 100644 index 0000000..d5dc7dd --- /dev/null +++ b/iproute2-optflags.patch @@ -0,0 +1,14 @@ +--- Makefile.orig 2009-05-13 21:06:21.000000000 +0200 ++++ Makefile 2009-05-13 21:06:44.000000000 +0200 +@@ -22,8 +22,9 @@ + + CC = gcc + HOSTCC = gcc +-CCOPTS = -D_GNU_SOURCE -O2 -Wstrict-prototypes -Wall +-CFLAGS = $(CCOPTS) -I../include $(DEFINES) ++OPTFLAGS = -O2 -g ++CCOPTS = -D_GNU_SOURCE -Wstrict-prototypes -Wall ++CFLAGS = $(CCOPTS) -I../include $(DEFINES) $(OPTFLAGS) + YACCFLAGS = -d -t -v + + LDLIBS += -L../lib -lnetlink -lutil