Change in vdsm[ovirt-3.5]: Fixed %post script error during upgrade

ybronhei at redhat.com ybronhei at redhat.com
Mon Dec 1 11:16:22 UTC 2014


Yaniv Bronhaim has uploaded a new change for review.

Change subject: Fixed %post script error during upgrade
......................................................................

Fixed %post script error during upgrade

During post script we initiates vdsm-tool set-saslpasswd call. On
upgrade we have mixed code that may lead to an error while calling
vdsm-tool script, as in the related bug.
In this patch we move the call to set-saslpasswd to init scripts. In
pre-script phase we can be sure that the newer code is running.

Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1168689
Change-Id: Ib7808f4f217ba3d6d30a60fab6233e36a29f0098
Signed-off-by: Yaniv Bronhaim <ybronhei at redhat.com>
---
M init/vdsmd_init_common.sh.in
M vdsm.spec.in
2 files changed, 5 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/44/35744/1

diff --git a/init/vdsmd_init_common.sh.in b/init/vdsmd_init_common.sh.in
index e637b59..9389e28 100644
--- a/init/vdsmd_init_common.sh.in
+++ b/init/vdsmd_init_common.sh.in
@@ -216,6 +216,10 @@
         [ "${ret}" -eq 0 ] && rm -f "${upgraded_ver_file}"
     fi
 }
+
+task_set_sasl_password() {
+    "$VDSM_TOOL" set-saslpasswd
+}
 #### pre-start tasks end ####
 
 
@@ -252,6 +256,7 @@
         # after load_needed_modules (modprobe bonding).
         # NetworkManager must not crash on nmcli conn delete.
         run_tasks " \
+            set_sasl_password \
             mkdirs \
             configure_coredump \
             configure_vdsm_logs \
diff --git a/vdsm.spec.in b/vdsm.spec.in
index 0a285c6..c1b1e1c 100644
--- a/vdsm.spec.in
+++ b/vdsm.spec.in
@@ -759,8 +759,6 @@
 
 %post
 %{_bindir}/vdsm-tool configure --module sanlock --force >/dev/null
-# set the vdsm "secret" password for libvirt
-%{_bindir}/vdsm-tool set-saslpasswd
 
 # After vdsm install we should create the logs files.
 # In the install session we create it but since we use


-- 
To view, visit http://gerrit.ovirt.org/35744
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ib7808f4f217ba3d6d30a60fab6233e36a29f0098
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.5
Gerrit-Owner: Yaniv Bronhaim <ybronhei at redhat.com>


More information about the vdsm-patches mailing list