[pve-devel] [PATCH corosync] remove problematic corosync-qdevice.init
Thomas Lamprecht
t.lamprecht at proxmox.com
Wed Mar 29 13:08:57 CEST 2017
without this we seemingly cannot install corosync-qdevice on PVE 5.0
While the programm and its systemd service file get installed
correctly the package configuration fails with:
----
Setting up corosync-qdevice (2.4.2-pve2) ...
insserv: Service corosync has to be enabled to start service corosync-qdevice
insserv: exiting now!
update-rc.d: error: insserv rejected the script header
dpkg: error processing package corosync-qdevice (--configure):
subprocess installed post-installation script returned error exit status 1
----
This error gets printed while corosync is enabled and started without
failure. So just remove the problematic file.
Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
---
...essary-and-problematic-corosync-qdevice.i.patch | 75 ++++++++++++++++++++++
patches/series | 1 +
2 files changed, 76 insertions(+)
create mode 100644 patches/0001-remove-unecessary-and-problematic-corosync-qdevice.i.patch
diff --git a/patches/0001-remove-unecessary-and-problematic-corosync-qdevice.i.patch b/patches/0001-remove-unecessary-and-problematic-corosync-qdevice.i.patch
new file mode 100644
index 0000000..726768f
--- /dev/null
+++ b/patches/0001-remove-unecessary-and-problematic-corosync-qdevice.i.patch
@@ -0,0 +1,75 @@
+From 9f7c883d8f84d17858d5e42b3b1c525399e3a4b6 Mon Sep 17 00:00:00 2001
+From: Thomas Lamprecht <t.lamprecht at proxmox.com>
+Date: Wed, 29 Mar 2017 09:35:19 +0200
+Subject: [PATCH] remove unecessary and problematic corosync-qdevice.init
+
+Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
+---
+ debian/corosync-qdevice.init | 55 --------------------------------------------
+ 1 file changed, 55 deletions(-)
+ delete mode 100755 debian/corosync-qdevice.init
+
+diff --git a/debian/corosync-qdevice.init b/debian/corosync-qdevice.init
+deleted file mode 100755
+index 344666a..0000000
+--- a/debian/corosync-qdevice.init
++++ /dev/null
+@@ -1,55 +0,0 @@
+-#!/bin/sh
+-# kFreeBSD do not accept scripts as interpreters, using #!/bin/sh and sourcing.
+-if [ true != "$INIT_D_SCRIPT_SOURCED" ] ; then
+- set "$0" "$@"; INIT_D_SCRIPT_SOURCED=true . /lib/init/init-d-script
+-fi
+-### BEGIN INIT INFO
+-# Provides: corosync-qdevice
+-# Required-Start: $remote_fs $syslog corosync
+-# Required-Stop: $remote_fs $syslog corosync
+-# Default-Start:
+-# Default-Stop: 0 1 6
+-# Short-Description: Corosync Qdevice daemon
+-# Description: Starts and stops Corosync Qdevice daemon.
+-### END INIT INFO
+-
+-NAME="corosync-qdevice"
+-DESC="Corosync Qdevice daemon"
+-DAEMON="/usr/sbin/$NAME"
+-PIDFILE="/run/$NAME/$NAME.pid"
+-
+-CONFIG="/etc/default/$NAME"
+-[ -f "$CONFIG" ] && . "$CONFIG"
+-
+-DAEMON_ARGS="$COROSYNC_QDEVICE_OPTIONS"
+-
+-do_start_prepare() {
+- if grep -q nocluster /proc/cmdline; then
+- log_failure_msg "not configured to run at boot"
+- exit 1
+- fi
+-}
+-
+-# do_{start,stop}_cmd from init-d-script, but without the --name option.
+-# corosync-qdevice is too long for a process name, it gets truncated,
+-# which makes it incompatible with the --name option. See #843419.
+-do_start_cmd() {
+- start-stop-daemon --start --quiet ${PIDFILE:+--pidfile ${PIDFILE}} \
+- $START_ARGS \
+- --startas $DAEMON --exec $DAEMON --test > /dev/null \
+- || return 1
+- start-stop-daemon --start --quiet ${PIDFILE:+--pidfile ${PIDFILE}} \
+- $START_ARGS \
+- --startas $DAEMON --exec $DAEMON -- $DAEMON_ARGS \
+- || return 2
+-}
+-do_stop_cmd() {
+- start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 \
+- $STOP_ARGS \
+- ${PIDFILE:+--pidfile ${PIDFILE}} --exec $DAEMON
+- RETVAL="$?"
+- [ "$RETVAL" = 2 ] && return 2
+- # Many daemons don't delete their pidfiles when they exit.
+- rm -f $PIDFILE
+- return $RETVAL
+-}
+--
+2.1.4
+
diff --git a/patches/series b/patches/series
index 0d2a8c7..01d7b7c 100644
--- a/patches/series
+++ b/patches/series
@@ -1,3 +1,4 @@
+0001-remove-unecessary-and-problematic-corosync-qdevice.i.patch
0001-add-Provides-Replaces-corosync-pve.patch
0002-don-t-install-default-corosync.conf.patch
0003-restart-after-package-upgrade-is-complete.patch
--
2.11.0
More information about the pve-devel
mailing list