diff options
author | Alan Pevec <apevec@fedoraproject.org> | 2009-09-02 13:52:55 +0000 |
---|---|---|
committer | Alan Pevec <apevec@fedoraproject.org> | 2009-09-02 13:52:55 +0000 |
commit | 77da49cf74434a59b4b314e4449affb2990e00da (patch) | |
tree | 958223ae35b2abbc7bd1e1c29735ba67ec676d9f | |
parent | 37753d56edcb04ede9a3978e7826025b11f18711 (diff) | |
download | collectd-77da49cf74434a59b4b314e4449affb2990e00da.tar.gz collectd-77da49cf74434a59b4b314e4449affb2990e00da.tar.xz collectd-77da49cf74434a59b4b314e4449affb2990e00da.zip |
- fix condrestart: on upgrade collectd is not restarted, bz# 516273collectd-4_6_4-1_fc12
- collectd does not re-connect to libvirtd, bz# 480997
- fix unpackaged files
https://bugzilla.redhat.com/show_bug.cgi?id=516276#c4
- New upstream version 4.6.4 http://collectd.org/news.shtml#news69
-rw-r--r-- | .cvsignore | 3 | ||||
-rw-r--r-- | collectd-4.5.4-fix-condrestart.patch | 11 | ||||
-rw-r--r-- | collectd-4.5.4-libvirt-reconnect.patch | 61 | ||||
-rw-r--r-- | collectd.spec | 41 | ||||
-rw-r--r-- | sources | 3 |
5 files changed, 110 insertions, 9 deletions
@@ -1,2 +1 @@ -collectd-4.5.3.tar.bz2 -collectd-4.6.2.tar.bz2 +collectd-4.6.4.tar.bz2 diff --git a/collectd-4.5.4-fix-condrestart.patch b/collectd-4.5.4-fix-condrestart.patch new file mode 100644 index 0000000..3982a16 --- /dev/null +++ b/collectd-4.5.4-fix-condrestart.patch @@ -0,0 +1,11 @@ +--- contrib/fedora/init.d-collectd.orig 2009-08-11 01:50:15.000000000 +0200 ++++ contrib/fedora/init.d-collectd 2009-08-11 01:51:10.000000000 +0200 +@@ -54,7 +54,7 @@ + start + ;; + condrestart) +- [ -f /var/lock/subsys/$prog ] && restart || : ++ [ -f /var/lock/subsys/$prog ] && stop && start || : + ;; + *) + echo $"Usage: $0 {start|stop|status|restart|reload|condrestart}" diff --git a/collectd-4.5.4-libvirt-reconnect.patch b/collectd-4.5.4-libvirt-reconnect.patch new file mode 100644 index 0000000..a0de7ce --- /dev/null +++ b/collectd-4.5.4-libvirt-reconnect.patch @@ -0,0 +1,61 @@ +--- a/src/libvirt.c 2009-08-11 23:27:35.000000000 +0200 ++++ b/src/libvirt.c 2009-08-12 00:14:58.000000000 +0200 +@@ -49,6 +49,8 @@ + + /* Connection. */ + static virConnectPtr conn = 0; ++static char *conn_string = NULL; ++static int conn_count = 0; + + /* Seconds between list refreshes, 0 disables completely. */ + static int interval = 60; +@@ -153,14 +155,14 @@ + il_interface_devices = ignorelist_create (1); + + if (strcasecmp (key, "Connection") == 0) { +- if (conn != 0) { ++ if (conn_count++ != 0) { + ERROR ("Connection may only be given once in config file"); + return 1; + } +- conn = virConnectOpenReadOnly (value); +- if (!conn) { +- VIRT_ERROR (NULL, "connection failed"); +- return 1; ++ conn_string = strdup(value); ++ if (conn_string == NULL) { ++ ERROR ("libvirt plugin: Connection strdup failed."); ++ return -1; + } + return 0; + } +@@ -253,10 +255,11 @@ + int i; + + if (conn == NULL) { +- ERROR ("libvirt plugin: Not connected. Use Connection in " +- "config file to supply connection URI. For more information " +- "see <http://libvirt.org/uri.html>"); +- return -1; ++ conn = virConnectOpenReadOnly (conn_string); ++ if (conn == NULL) { ++ ERROR ("libvirt plugin: Not connected."); ++ return -1; ++ } + } + + time (&t); +@@ -264,8 +267,12 @@ + /* Need to refresh domain or device lists? */ + if ((last_refresh == (time_t) 0) || + ((interval > 0) && ((last_refresh + interval) <= t))) { +- if (refresh_lists () != 0) ++ if (refresh_lists () != 0) { ++ if (conn != NULL) ++ virConnectClose (conn); ++ conn = NULL; + return -1; ++ } + last_refresh = t; + } + diff --git a/collectd.spec b/collectd.spec index 86a1159..f18e1ba 100644 --- a/collectd.spec +++ b/collectd.spec @@ -1,15 +1,19 @@ Summary: Statistics collection daemon for filling RRD files Name: collectd -Version: 4.6.2 -Release: 5%{?dist} +Version: 4.6.4 +Release: 1%{?dist} License: GPLv2 Group: System Environment/Daemons URL: http://collectd.org/ Source: http://collectd.org/files/%{name}-%{version}.tar.bz2 -Patch0: %{name}-%{version}-include-collectd.d.patch +Patch0: %{name}-4.6.2-include-collectd.d.patch # bug 468067 "pkg-config --libs OpenIPMIpthread" fails -Patch1: %{name}-%{version}-configure-OpenIPMI.patch +Patch1: %{name}-4.6.2-configure-OpenIPMI.patch +# bug 516273 on upgrade collectd is not restarted +Patch2: %{name}-4.5.4-fix-condrestart.patch +# bug 480997 collectd does not re-connect to libvirtd +Patch3: %{name}-4.5.4-libvirt-reconnect.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root @@ -151,6 +155,8 @@ This plugin collects information from virtualized guests. %setup -q %patch0 -p1 %patch1 -p0 +%patch2 -p0 +%patch3 -p1 sed -i.orig -e 's|-Werror||g' Makefile.in */Makefile.in @@ -221,7 +227,7 @@ done # *.la files shouldn't be distributed. -rm -f %{buildroot}/%{_libdir}/collectd/*.la +rm -f %{buildroot}/%{_libdir}/{collectd/,}*.la %post @@ -310,6 +316,24 @@ fi %{_libdir}/collectd/wireless.so %{_datadir}/collectd/types.db +%{_libdir}/collectd/bind.so +%{_libdir}/collectd/curl.so +%{_libdir}/collectd/match_regex.so +%{_libdir}/collectd/match_timediff.so +%{_libdir}/collectd/match_value.so +%{_libdir}/collectd/openvpn.so +%{_libdir}/collectd/target_notification.so +%{_libdir}/collectd/target_replace.so +%{_libdir}/collectd/target_set.so + +# collectdclient - TBD reintroduce -devel subpackage? +%{_libdir}/libcollectdclient.so +%{_libdir}/libcollectdclient.so.0 +%{_libdir}/libcollectdclient.so.0.0.0 +%{_libdir}/pkgconfig/libcollectdclient.pc +%{_includedir}/collectd/client.h +%{_includedir}/collectd/lcc_features.h + %doc AUTHORS ChangeLog COPYING INSTALL README %doc %{_mandir}/man1/collectd.1* %doc %{_mandir}/man1/collectd-nagios.1* @@ -407,6 +431,13 @@ fi %changelog +* Wed Sep 02 2009 Alan Pevec <apevec@redhat.com> 4.6.4-1 +- fix condrestart: on upgrade collectd is not restarted, bz# 516273 +- collectd does not re-connect to libvirtd, bz# 480997 +- fix unpackaged files https://bugzilla.redhat.com/show_bug.cgi?id=516276#c4 +- New upstream version 4.6.4 + http://collectd.org/news.shtml#news69 + * Fri Aug 21 2009 Tomas Mraz <tmraz@redhat.com> - 4.6.2-5 - rebuilt with new openssl @@ -1,2 +1 @@ -f368200c4bedd64baba46094906e81ee collectd-4.5.3.tar.bz2 -ca1282372f15882ce07fdff6c61340d5 collectd-4.6.2.tar.bz2 +f4a1b16c57ba946d24c0db910febb950 collectd-4.6.4.tar.bz2 |