Your message dated Sun, 15 Jul 2012 11:17:13 +0000 with message-id <e1sqmp7-0004ay...@franck.debian.org> and subject line Bug#681216: fixed in collectd 5.1.0-3 has caused the Debian Bug report #681216, regarding collectd: package fails to upgrade when collectd is disabled to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact ow...@bugs.debian.org immediately.) -- 681216: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=681216 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
--- Begin Message ---Package: collectd Version: 5.1.0-2 Severity: normal Hello there, collectd fails to upgrade when it is disabled by /etc/default/collectd, see the following abridged transcript: $ grep ^DISABLE /etc/default/collectd DISABLE=1 # aptitude # using the TUI [...] Preparing to replace collectd-core 5.1.0-1 (using .../collectd-core_5.1.0-2_amd64.deb) ... Stopping statistics collection and monitoring daemon: collectd. Unpacking replacement collectd-core ... Preparing to replace collectd 5.1.0-1 (using .../collectd_5.1.0-2_amd64.deb) ... Unpacking replacement collectd ... Preparing to replace collectd-dev 5.1.0-1 (using .../collectd-dev_5.1.0-2_all.deb) ... Unpacking replacement collectd-dev ... Preparing to replace libcollectdclient0 5.1.0-1 (using .../libcollectdclient0_5.1.0-2_amd64.deb) ... Unpacking replacement libcollectdclient0 ... Preparing to replace collectd-utils 5.1.0-1 (using .../collectd-utils_5.1.0-2_amd64.deb) ... Unpacking replacement collectd-utils ... [...] Setting up collectd-core (5.1.0-2) ... Installing new version of config file /etc/init.d/collectd ... [warn] Not starting statistics collection and monitoring daemon, disabled by /etc/default/collectd. ... (warning). Setting up libcollectdclient0 (5.1.0-2) ... Setting up collectd-utils (5.1.0-2) ... [...] Setting up collectd (5.1.0-2) ... [....] Restarting statistics collection and monitoring daemon: collectd disabled by /etc/default/collectdinvoke-rc.d: initscript collectd, action "restart" failed. dpkg: error processing collectd (--configure): subprocess installed post-installation script returned error exit status 2 Setting up collectd-dev (5.1.0-2) ... [...] Errors were encountered while processing: collectd E: Sub-process /usr/bin/dpkg returned an error code (1) A package failed to install. Trying to recover: Setting up collectd (5.1.0-2) ... [....] Restarting statistics collection and monitoring daemon: collectd disabled by /etc/default/collectdinvoke-rc.d: initscript collectd, action "restart" failed. dpkg: error processing collectd (--configure): subprocess installed post-installation script returned error exit status 2 Errors were encountered while processing: collectd Press Return to continue. This is due to its postinst calling invoke-rc.d with restart, but the initscript doesn't special case "restart" as it does with "start", see the following excerpts from the initscripts (nl -ba /etc/init.d/collectd): 53 if test "$DISABLE" != 0 -a "$1" == "start"; then 54 log_warning_msg "Not starting $DESC, disabled by /etc/default/$NAME." 55 exit 0 56 fi 57 58 if test ! -e "$CONFIGFILE" -a "$1" == "start"; then 59 log_warning_msg "Not starting $DESC, no configuration ($CONFIGFILE) found." 60 exit 0 61 fi Instead, "restart" triggers 79 d_start() { 80 if test "$DISABLE" != 0; then 81 # we get here during restart 82 log_progress_msg "disabled by /etc/default/$NAME" 83 return 2 84 fi 85 86 if test ! -e "$CONFIGFILE"; then 87 # we get here during restart 88 log_progress_msg "disabled, no configuration ($CONFIGFILE) found" 89 return 2 90 fi [...] 108 } via 164 restart|force-reload) 165 log_daemon_msg "Restarting $DESC" "$NAME" 166 check_config 167 rc="$?" 168 if test "$rc" -eq 1; then 169 log_progress_msg "not restarting, configuration error" 170 log_end_msg 1 171 exit 1 172 fi 173 d_stop 174 rc="$?" 175 case "$rc" in 176 0|1) 177 sleep 1 178 d_start 179 rc2="$?" 180 case "$rc2" in 181 0) log_end_msg 0 ;; 182 *) log_end_msg 1 ;; 183 esac 184 ;; 185 *) 186 log_end_msg 1 187 ;; 188 esac 189 ;; and consequently fails with "log_end_msg 1" due to the "return 2" in d_start. For now I temporarily patched line 53 to special case "restart" instead and finished package installation via "dpkg --configure -a", but this or just adding "restart" and "force-reload" OR'ed to the test won't do as a general solution. Hmm, the initscript already acknowledges that "restart" might encounter the "return 2" in lines 80-90. I feel like I'm filing to grasp some intention here, so I'm at a loss at how to best fix this ... I was tempted to file this bug at a higher severity (due to breaking package upgrade), but somehow couldn't find a corresponding policy paragraph to quote, so just filing at normal now. FWIW, it just affects a most probably not-so-common usecase of carrying around a disabled program. Cheers, Flo -- System Information: Debian Release: wheezy/sid APT prefers testing APT policy: (500, 'testing'), (50, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386 Kernel: Linux 3.2.0-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages collectd depends on: ii collectd-core 5.1.0-2 ii iptables 1.4.14-2 ii libc6 2.13-33 ii librrd4 1.4.7-1 Versions of packages collectd recommends: ii libc6 2.13-33 ii libcurl3-gnutls 7.26.0-1 ii libdbi1 0.8.4-6 ii libdbus-1-3 1.6.0-1 pn libesmtp6 <none> ii libgcrypt11 1.5.0-3 ii libgdk-pixbuf2.0-0 2.26.1-1 ii libglib2.0-0 2.32.3-1 pn libhal1 <none> ii libmemcached10 1.0.8-1 pn libmodbus5 <none> ii libmysqlclient18 5.5.24+dfsg-4 ii libnotify4 0.7.5-1 ii libopenipmi0 2.0.16-1.3 pn liboping0 <none> ii libpcap0.8 1.3.0-1 ii libperl5.14 5.14.2-12 ii libpq5 9.1.4-2 pn libprotobuf-c0 <none> ii libpython2.7 2.7.3~rc2-2.1 pn librabbitmq0 <none> ii librrd4 1.4.7-1 ii libsensors4 1:3.3.2-2 ii libsnmp15 5.4.3~dfsg-2.5 ii libssl1.0.0 1.0.1c-3 pn libtokyotyrant3 <none> pn libupsclient1 <none> pn libvarnishapi1 <none> ii libvirt0 0.9.12-3 ii libxml2 2.8.0+dfsg1-4 ii libyajl2 2.0.4-2 collectd suggests no packages. -- no debconf informationsignature.asc
Description: Digital signature
--- End Message ---
--- Begin Message ---Source: collectd Source-Version: 5.1.0-3 We believe that the bug you reported is fixed in the latest version of collectd, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to 681...@bugs.debian.org, and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Sebastian Harl <tok...@debian.org> (supplier of updated collectd package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing ftpmas...@debian.org) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Format: 1.8 Date: Sun, 15 Jul 2012 11:17:10 +0200 Source: collectd Binary: collectd-core collectd collectd-utils collectd-dbg collectd-dev libcollectdclient-dev libcollectdclient0 Architecture: source amd64 all Version: 5.1.0-3 Distribution: unstable Urgency: low Maintainer: Sebastian Harl <tok...@debian.org> Changed-By: Sebastian Harl <tok...@debian.org> Description: collectd - statistics collection and monitoring daemon collectd-core - statistics collection and monitoring daemon (core system) collectd-dbg - statistics collection and monitoring daemon (debugging symbols) collectd-dev - statistics collection and monitoring daemon (development files) collectd-utils - statistics collection and monitoring daemon (utilities) libcollectdclient-dev - client library for collectd's control interface (development file libcollectdclient0 - client library for collectd's control interface Closes: 681216 681363 Changes: collectd (5.1.0-3) unstable; urgency=low . * debian/patches/migrate-4-5-df.dpatch, debian/collectd-core.postinst: - Added patch to fix the migration of 'df' values in migrate-4-5.px; thanks to 'markuskaindl' for reporting this on IRC. - Pass --rrdfilter and --rrdtool parameters to migrate-4-5.px in order to let the script find those binaries/scripts. (Closes: #681363) * debian/collectd-core.collectd.init.d: - Catch disabled state in start and restart and don't exit with an error status. Amongst others, this fixes an upgrade of collectd when the daemon is disabled. Thanks to Florian Ernst for reporting this and Evgeni Golov for providing (an early) patch (Closes: #681216). - Don't use 'set -e' and 'exit 0' (at the end) in order to let return statuses propagate correctly. (cf. #681216) Checksums-Sha1: 9cac2eb59d3ad8f935a35260b202003e4f663399 2654 collectd_5.1.0-3.dsc 981813462157afbe7235897046b10069d20b3fd7 70852 collectd_5.1.0-3.diff.gz a1eff9833e0733e93c1af54489a5b77d5cd7aa06 916460 collectd-core_5.1.0-3_amd64.deb 71a5382dc04bb40ee9c92ac68ce58e6af75191db 75932 collectd_5.1.0-3_amd64.deb d33a386760823fb3e0c70da80c1b2d99c6e9dde2 87842 collectd-utils_5.1.0-3_amd64.deb 5c4ea69ee04840c3e061ba83669ad365d80b11c7 1347070 collectd-dbg_5.1.0-3_amd64.deb 90eb239ca44812285f603ca940d42b742d4ab97f 70970 libcollectdclient-dev_5.1.0-3_amd64.deb aeb2184a82349759a3cd45de2c7e60ef5aeb7d2a 76990 libcollectdclient0_5.1.0-3_amd64.deb 75166a2e53d40fe8e15a75e9cd0d37aa40256cec 111896 collectd-dev_5.1.0-3_all.deb Checksums-Sha256: fda92924298afc5027dd3383fbedc8413cdd73d5684262707e5dc9279e78184e 2654 collectd_5.1.0-3.dsc 3fef2c8857916b3286685549e1148ab1ee5eeacbe5327d972125c96babf74bc9 70852 collectd_5.1.0-3.diff.gz 6c970b929757215e3e93014d70fab3ec0e92cc031e78304fe1b1ca33688da7fd 916460 collectd-core_5.1.0-3_amd64.deb b0a7a95f97bb1664aa58f22e8334c6d645bed884510494400967942520846cea 75932 collectd_5.1.0-3_amd64.deb e6beb24e9e0f53c113f183bc6ea9856691575868f195f1a8fa9a30118f1a63f1 87842 collectd-utils_5.1.0-3_amd64.deb 8cd4ba3daf8d6cd7bc7404f5a03548395573d0d4ef8153cb7861678cd353a573 1347070 collectd-dbg_5.1.0-3_amd64.deb 03f89b9adfec50569f19d43495a883b21b6452ed94e91921aa8b46be1beeb843 70970 libcollectdclient-dev_5.1.0-3_amd64.deb 5a202425c5781c2ad1069a10ae804db8583b5feca16a6c59432829d8c6b64b68 76990 libcollectdclient0_5.1.0-3_amd64.deb 4e144514eb85c3869c2a6dc939de779eebcb9c9b8d9d5157ffd858f8bec3dc03 111896 collectd-dev_5.1.0-3_all.deb Files: 1784c72a1bbdd9e3b286a6799e5d7730 2654 utils optional collectd_5.1.0-3.dsc 41f00b968e2b2ba5d98e25d87779922f 70852 utils optional collectd_5.1.0-3.diff.gz 07bc75636650b556737d596302b89a58 916460 utils optional collectd-core_5.1.0-3_amd64.deb a08a146f6104285b4adede29a5ec4796 75932 utils optional collectd_5.1.0-3_amd64.deb 9c77354d837659b29500a350c7d76b78 87842 utils optional collectd-utils_5.1.0-3_amd64.deb 1f293e8286ac199bc9a571652a16e6d6 1347070 debug extra collectd-dbg_5.1.0-3_amd64.deb 35ff6aec14de924c140ac2833e69a047 70970 libdevel optional libcollectdclient-dev_5.1.0-3_amd64.deb b1455b159db36fca2ba5c4b39d438313 76990 libs optional libcollectdclient0_5.1.0-3_amd64.deb 6f27d773de63677c703bf482555f9b5f 111896 utils optional collectd-dev_5.1.0-3_all.deb -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAlACoQkACgkQEFEKc4UBx/zWjQCZASVTucBBUaqx1bvv96tavxSr NXUAnjm7ynC48D8CwfBtcELaB3VAwoIe =y0Dq -----END PGP SIGNATURE-----
--- End Message ---