[pve-devel] [PATCH cluster] Workaround for broken corosync-qdevice SysV config
Stefan Reiter
s.reiter at proxmox.com
Tue Jul 9 17:31:26 CEST 2019
Since we use only systemd, we can simply remove this file. Without
removing, the "systemd enable" command fails, complaining about unset
run-levels.
Signed-off-by: Stefan Reiter <s.reiter at proxmox.com>
---
The author of corosync-qdevice is aware of the issue:
https://bugs.launchpad.net/ubuntu/+source/corosync-qdevice/+bug/1809682
Until it is merged upstream, this patch allows creation and removal of qdevices
without issues.
data/PVE/CLI/pvecm.pm | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/data/PVE/CLI/pvecm.pm b/data/PVE/CLI/pvecm.pm
index 823130a..de6b21a 100755
--- a/data/PVE/CLI/pvecm.pm
+++ b/data/PVE/CLI/pvecm.pm
@@ -243,6 +243,11 @@ __PACKAGE__->register_method ({
my $outsub = sub { print "\nnode '$node': " . shift };
print "\nINFO: start and enable corosync qdevice daemon on node '$node'...\n";
run_command([@$ssh_cmd, $ip, 'systemctl', 'start', 'corosync-qdevice'], outfunc => \&$outsub);
+
+ # corosync-qdevice package ships with broken SysV file
+ # FIXME: Remove once fix is upstream
+ run_command([@$ssh_cmd, $ip, 'rm', '-f', '/etc/init.d/corosync-qdevice']);
+
run_command([@$ssh_cmd, $ip, 'systemctl', 'enable', 'corosync-qdevice'], outfunc => \&$outsub);
});
@@ -300,6 +305,11 @@ __PACKAGE__->register_method ({
$foreach_member->(sub {
my (undef, $ip) = @_;
run_command([@$ssh_cmd, $ip, 'systemctl', 'stop', 'corosync-qdevice']);
+
+ # corosync-qdevice package ships with broken SysV file
+ # FIXME: Remove once fix is upstream
+ run_command([@$ssh_cmd, $ip, 'rm', '-f', '/etc/init.d/corosync-qdevice']);
+
run_command([@$ssh_cmd, $ip, 'systemctl', 'disable', 'corosync-qdevice']);
});
--
2.20.1
More information about the pve-devel
mailing list