Alon Bar-Lev has uploaded a new change for review. Change subject: packaging: add a method to reconfigure without init.d parameter ......................................................................
packaging: add a method to reconfigure without init.d parameter systemd does not support additional service commands[1], while there can be argue if this is good or bad this is the fact. CURRENT IMPLEMENTATION Current bootstrap implementation uses hybrid approach while trying to pass "reconfigure" to init.d, and when fails, access the init.d script directly. This is highly none expected behavior. NEW IMPLEMENTATION Add /var/lib/vdsm/reconfigure file, if exists perform reconfiguration. This will work with any init.d system without issues. The service will be reconfigure at next start. ** We cannot remove the code from the current vdsm-bootstrap, so it able to reconfigure previous versions of vdsm. [1] http://www.freedesktop.org/wiki/Software/systemd/Incompatibilities Change-Id: Id4a8d5939fbefc6d3857d8083dfcf2180b9ba110 Signed-off-by: Alon Bar-Lev <[email protected]> --- M vdsm/vdsmd.init.in 1 file changed, 4 insertions(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/25/8725/1 diff --git a/vdsm/vdsmd.init.in b/vdsm/vdsmd.init.in index 2b9ad11..453540d 100755 --- a/vdsm/vdsmd.init.in +++ b/vdsm/vdsmd.init.in @@ -28,6 +28,7 @@ GETCONFITEM=@VDSMDIR@/get-conf-item prog=vdsm PIDFILE=@VDSMRUNDIR@/vdsmd.pid +FORCE_RECONFIGURE=@VDSMLIBDIR@/reconfigure RESPAWNPIDFILE=@VDSMRUNDIR@/respawn.pid CORE_DUMP_PATH=/var/log/core/core.%p.%t.dump DOM_METADATA_BACKUP_DIR=/var/log/vdsm/backup @@ -271,6 +272,7 @@ # do not reconfigure, return 0, so that vdsm start can continue. if [ "$force_reconfigure" != "force" ] && + ! [ -r "$FORCE_RECONFIGURE" ] && grep -q "$by_vdsm_vers" $lconf && grep -q "$by_vdsm_vers" $qconf && \ grep -q "$by_vdsm_vers" $ldconf && grep -q "$by_vdsm_vers" $qlconf then @@ -367,6 +369,8 @@ ovirt_store_config "$lconf" "$qconf" "$ldconf" "$llogr" /sbin/initctl restart libvirtd 2>/dev/null || : + + [ -r "$FORCE_RECONFIGURE" ] && rm -f "$FORCE_RECONFIGURE" || : } -- To view, visit http://gerrit.ovirt.org/8725 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Id4a8d5939fbefc6d3857d8083dfcf2180b9ba110 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Alon Bar-Lev <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
