Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has uploaded a new change for review. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Avoiding automatically restart of sanlock service when starting vdsmd Init scripts are supposed to perform automatic restart to external services. This patch replace the restart with a print to user. For backward compatibility we keep the restart over old usages. Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Signed-off-by: Yaniv Bronhaim --- M init/systemd/systemd-vdsmd.in M init/sysvinit/vdsmd.init.in M init/vdsmd_init_common.sh.in 3 files changed, 12 insertions(+), 7 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/90/19890/1 diff --git a/init/systemd/systemd-vdsmd.in b/init/systemd/systemd-vdsmd.in index 692e5eb..d07980b 100644 --- a/init/systemd/systemd-vdsmd.in +++ b/init/systemd/systemd-vdsmd.in @@ -28,3 +28,5 @@ "@BINDIR@/vdsm-tool" libvirt-configure ${2:+--force} && "@BINDIR@/vdsm-tool" libvirt-configure-services-restart +"@BINDIR@/vdsm-tool" sanlock-check-service && +"@BINDIR@/vdsm-tool" service-restart sanlock diff --git a/init/sysvinit/vdsmd.init.in b/init/sysvinit/vdsmd.init.in index 2fb4d0d..2160668 100755 --- a/init/sysvinit/vdsmd.init.in +++ b/init/sysvinit/vdsmd.init.in @@ -112,6 +112,11 @@ "$VDSM_TOOL" libvirt-configure-services-restart } +reconfigure_sanlock() { +"$VDSM_TOOL" sanlock-check-service && +"$VDSM_TOOL" service-restart sanlock +} + start() { test_already_running && return 0 @@ -202,6 +207,7 @@ # Jump over 'reconfigure' shift 1 reconfigure_libvirt "$@" +reconfigure_sanlock RETVAL=$? ;; *) diff --git a/init/vdsmd_init_common.sh.in b/init/vdsmd_init_common.sh.in index 33094a0..7fc6287 100644 --- a/init/vdsmd_init_common.sh.in +++ b/init/vdsmd_init_common.sh.in @@ -50,20 +50,17 @@ } -task_reconfigure_sanlock() { -_reconfigure_sanlock -} - -_reconfigure_sanlock() { +task_check_sanlock_reconfigure() { # If sanlock was started before the *first* installation of vdsm # then it is probably missing the supplementary groups. # Here we attempt to restart the service (when needed) to refresh # the groups. "$VDSM_TOOL" sanlock-check-service if [ $? != 0 ]; then -echo -n "Attempting to restart sanlock service:" -"$VDSM_TOOL" service-restart sanlock || return 1 +echo "Perform 'vdsm-tool service-restart sanlock' and start vdsm again" +return 1 fi +return 0 } -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 1: Build Successful http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4716/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4792/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3907/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 1: this is no good, as host-deploy does not know what you want to reconfigure. please add vdsm-tool reconfigure verb to reconfigure whatever required, please add --force so it stop whatever service required for reconfigure. host-deploy will call this verb, and only this verb. we need it for 3.3.z upstream as well. -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Dan Kenigsberg has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 1: Code-Review-1 (3 comments) File init/systemd/systemd-vdsmd.in Line 28: Line 29: "@BINDIR@/vdsm-tool" libvirt-configure ${2:+--force} && Line 30: "@BINDIR@/vdsm-tool" libvirt-configure-services-restart Line 31: "@BINDIR@/vdsm-tool" sanlock-check-service && Line 32: "@BINDIR@/vdsm-tool" service-restart sanlock this is called by ovirt-host-deploy only on Fedora. For EL6 we must keep nasty restart on "reconfigure" verb. File init/vdsmd_init_common.sh.in Line 218: run_tasks " \ Line 219: configure_coredump \ Line 220: run_init_hooks \ Line 221: gencerts \ Line 222: check_libvirt_configure \ I think that the only change possible is to replace this with check_sanlock_configure Line 223: reconfigure_sanlock \ Line 224: syslog_available \ Line 225: nwfilter dummybr \ Line 226: load_needed_modules \ Line 229: test_conflicting_conf \ Line 230: " Line 231: ;; Line 232: --post-stop) Line 233: run_tasks " \ how have these evil tabs got here? Line 234: run_final_hooks \ Line 235: " Line 236: ;; Line 237: --help|*) -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 1: (1 comment) File init/systemd/systemd-vdsmd.in Line 28: Line 29: "@BINDIR@/vdsm-tool" libvirt-configure ${2:+--force} && Line 30: "@BINDIR@/vdsm-tool" libvirt-configure-services-restart Line 31: "@BINDIR@/vdsm-tool" sanlock-check-service && Line 32: "@BINDIR@/vdsm-tool" service-restart sanlock in EL6 we call "service vdsmd reconfigure" that does that -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 2: Build Successful http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4729/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4805/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3920/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 2: (2 comments) this patch if merge by its own breaks host-deploy. File init/sysvinit/vdsmd.init.in Line 207: reconfigure) Line 208: # Jump over 'reconfigure' Line 209: shift 1 Line 210: reconfigure_libvirt "$@" Line 211: reconfigure_sanlock what is the return if one fail? if two? Line 212: RETVAL=$? Line 213: ;; Line 214: *) Line 215: echo "Usage: $0 {start|stop|status|restart|force-reload|try-restart}" File init/vdsmd_init_common.sh.in Line 56 Line 57 Line 58 Line 59 Line 60 should be: if ! "$VDSM_TOOL" sanlock-check-service; then echo "Perform 'vdsm-tool service-restart sanlock' and start vdsm again" return 1 fi return 0 see bellow and above... -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 3: Build Successful http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4768/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4844/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3959/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 3: Code-Review+1 (1 comment) File init/systemd/systemd-vdsmd.in Line 28: Line 29: "@BINDIR@/vdsm-tool" libvirt-configure ${2:+--force} && Line 30: "@BINDIR@/vdsm-tool" libvirt-configure-services-restart Line 31: "@BINDIR@/vdsm-tool" sanlock-check-service && Line 32: "@BINDIR@/vdsm-tool" service-restart sanlock return value will be only of last command. -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 3: (1 comment) File init/systemd/systemd-vdsmd.in Line 28: Line 29: "@BINDIR@/vdsm-tool" libvirt-configure ${2:+--force} && Line 30: "@BINDIR@/vdsm-tool" libvirt-configure-services-restart Line 31: "@BINDIR@/vdsm-tool" sanlock-check-service && Line 32: "@BINDIR@/vdsm-tool" service-restart sanlock changing the call to reconfigure-all -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 4: Build Successful http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4786/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4862/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3977/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 4: (3 comments) File lib/vdsm/tool/configurator.py Line 29: Line 30: SANLOCK_PID = "/var/run/sanlock/sanlock.pid" Line 31: Line 32: PROC_STATUS_PATH = "/proc/%s/status" Line 33: PROC_STATUS_GROUPS = "Groups:\t" why not move these to the function that actually uses it? Line 34: PROC_STATUS_GROUPS_LEN = len(PROC_STATUS_GROUPS) Line 35: Line 36: Line 37: def exec_libvirt_configure(action, *args): Line 30: SANLOCK_PID = "/var/run/sanlock/sanlock.pid" Line 31: Line 32: PROC_STATUS_PATH = "/proc/%s/status" Line 33: PROC_STATUS_GROUPS = "Groups:\t" Line 34: PROC_STATUS_GROUPS_LEN = len(PROC_STATUS_GROUPS) this is stupid constant... Line 35: Line 36: Line 37: def exec_libvirt_configure(action, *args): Line 38: """ Line 111: if status_line.startswith(PROC_STATUS_GROUPS): Line 112: groups = [int(x) for x in Line 113: status_line[PROC_STATUS_GROUPS_LEN:].strip().split(" ")] Line 114: break Line 115: else: for/else? Line 116: raise RuntimeError("Unable to find sanlock service groups") Line 117: Line 118: diskimage_gid = grp.getgrnam(DISKIMAGE_GROUP)[2] Line 119: return 0 if diskimage_gid in groups else 1 -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 4: (2 comments) File lib/vdsm/tool/configurator.py Line 30: SANLOCK_PID = "/var/run/sanlock/sanlock.pid" Line 31: Line 32: PROC_STATUS_PATH = "/proc/%s/status" Line 33: PROC_STATUS_GROUPS = "Groups:\t" Line 34: PROC_STATUS_GROUPS_LEN = len(PROC_STATUS_GROUPS) agree... just moved it. I should take a look on the implantation I copy from time to time Line 35: Line 36: Line 37: def exec_libvirt_configure(action, *args): Line 38: """ Line 111: if status_line.startswith(PROC_STATUS_GROUPS): Line 112: groups = [int(x) for x in Line 113: status_line[PROC_STATUS_GROUPS_LEN:].strip().split(" ")] Line 114: break Line 115: else: http://docs.python.org/2/tutorial/controlflow.html#break-and-continue-statements-and-else-clauses-on-loops Line 116: raise RuntimeError("Unable to find sanlock service groups") Line 117: Line 118: diskimage_gid = grp.getgrnam(DISKIMAGE_GROUP)[2] Line 119: return 0 if diskimage_gid in groups else 1 -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 5: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4791/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4867/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3982/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_install_rpm_sanity_gerrit/146/ : FAILURE -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 6: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4803/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4879/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3994/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_install_rpm_sanity_gerrit/149/ : FAILURE -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 6 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 7: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4805/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4881/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3996/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_install_rpm_sanity_gerrit/150/ : FAILURE -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 7 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 8: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4885/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4000/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_install_rpm_sanity_gerrit/152/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4810/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 8: (6 comments) File lib/vdsm/tool/configurator.py Line 93: """ Line 94: sanlock_pid_file = "/var/run/sanlock/sanlock.pid" Line 95: proc_status_path = "/proc/%s/status" Line 96: proc_status_group_prefix = "Groups:\t" Line 97: group_prefix_len = len(proc_status_group_prefix) why do you need constant for string len? Line 98: Line 99: try: Line 100: sanlock_pid = open(sanlock_pid_file, "r").readline().strip() Line 101: sanlock_status = open(proc_status_path % sanlock_pid, "r") Line 96: proc_status_group_prefix = "Groups:\t" Line 97: group_prefix_len = len(proc_status_group_prefix) Line 98: Line 99: try: Line 100: sanlock_pid = open(sanlock_pid_file, "r").readline().strip() this leaks Line 101: sanlock_status = open(proc_status_path % sanlock_pid, "r") Line 102: except IOError as e: Line 103: if e.errno == os.errno.ENOENT: Line 104: return 0 # service is not running, returning Line 97: group_prefix_len = len(proc_status_group_prefix) Line 98: Line 99: try: Line 100: sanlock_pid = open(sanlock_pid_file, "r").readline().strip() Line 101: sanlock_status = open(proc_status_path % sanlock_pid, "r") this leaks Line 102: except IOError as e: Line 103: if e.errno == os.errno.ENOENT: Line 104: return 0 # service is not running, returning Line 105: raise Line 114: Line 115: diskimage_gid = grp.getgrnam(DISKIMAGE_GROUP)[2] Line 116: if diskimage_gid in groups: Line 117: sys.stdout.write("sanlock service requires restart\n") Line 118: return 0 again... I do not like return in middle of functions... Line 119: Line 120: sys.stdout.write("sanlock service is already configured\n") Line 121: return 1 Line 122: Line 120: sys.stdout.write("sanlock service is already configured\n") Line 121: return 1 Line 122: Line 123: Line 124: @vdsm.tool.expose("reconfigure-all") configure-all ? Line 125: def configure_all(*args): Line 126: """ Line 127: Configure related services for vdsm and restart them. --force for Line 128: forcing restart of related services after configure Line 130: if '--force' in args: Line 131: service.service_stop("supervdsmd") Line 132: service.service_stop("libvirtd") Line 133: Line 134: configure_libvirt(*args) don't you need to check rc? Line 135: if sanlock_check_service(*args): -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 8: (1 comment) File lib/vdsm/tool/configurator.py Line 130: if '--force' in args: Line 131: service.service_stop("supervdsmd") Line 132: service.service_stop("libvirtd") Line 133: Line 134: configure_libvirt(*args) not really , if it fails it raises RuntimeException, if not the rc is 0. but I'll add it just for future changes , if someone will decide to return instead of raising exception Line 135: if sanlock_check_service(*args): -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4891/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4006/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4816/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (8 comments) File init/sysvinit/vdsmd.init.in Line 61:initctl stop "${srv}" || : # stop fails when already down Line 62:initctl status "${srv}" | grep -q stop/waiting Line 63:elif [ -x "/etc/init.d/${srv}" ]; then Line 64: ! service "${srv}" status >/dev/null 2>&1 || Line 65: service "${srv}" stop something in the indent is wrong use: service status && service stop but we do want to have error of stop, so it should be: if service status; then service stop fi this way you will get rc=0 even if service status is failing Line 66:else Line 67:true Line 68:fi Line 69: fi File lib/vdsm/tool/configurator.py Line 90: """ Line 91: Check if sanlock service requires a restart to reload the relevant Line 92: supplementary groups. Line 93: """ Line 94: retval = 0 always assume failure. Line 95: sanlock_pid_file = "/var/run/sanlock/sanlock.pid" Line 96: proc_status_path = "/proc/%s/status" Line 97: proc_status_group_prefix = "Groups:\t" Line 98: Line 98: Line 99: try: Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") leak? Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: why not check if exist first then fail after? if os.path.exists(...): with open ... as Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 107: raise Line 108: Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning please avoid return at middle. Line 107: raise Line 108: Line 109: for status_line in sanlock_status: Line 110: if status_line.startswith(proc_status_group_prefix): Line 111: groups = [int(x) for x in Line 112: status_line[len(proc_status_group_prefix):]. Line 113: strip().split(" ")] Line 114: break Line 115: else: this is *UGLY*, close should be in finally anyway. Line 116: sanlock_status.close() Line 117: raise RuntimeError("Unable to find sanlock service groups") Line 118: Line 119: sanlock_status.close() Line 117: raise RuntimeError("Unable to find sanlock service groups") Line 118: Line 119: sanlock_status.close() Line 120: diskimage_gid = grp.getgrnam(DISKIMAGE_GROUP)[2] Line 121: if diskimage_gid in groups: not in... and in the success flow set retval = 0. Now... question... why not throw RuntimeException with the error message each time you have an error, and have proper positive flow? Line 122: sys.stdout.write("sanlock service requires restart\n") Line 123: else: Line 124: sys.stdout.write("sanlock service is already configured\n") Line 125: retval = 1 Line 137: service.service_stop("supervdsmd") Line 138: service.service_stop("libvirtd") Line 139: Line 140: if not configure_libvirt(*args): Line 141: sys.stderr.write("failed to run configure-libvirt\n") and exit/throw with error? you cannot continue as usual. Line 142: if sanlock_check_service(*args): -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (2 comments) File lib/vdsm/tool/configurator.py Line 98: Line 99: try: Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") no. I close it when stop using it Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 117: raise RuntimeError("Unable to find sanlock service groups") Line 118: Line 119: sanlock_status.close() Line 120: diskimage_gid = grp.getgrnam(DISKIMAGE_GROUP)[2] Line 121: if diskimage_gid in groups: qemu gid always appears in the "Groups:" line of sanlock's pid status file... also after reset.. is it a bug in sanlock or wrong check that we perform here? Line 122: sys.stdout.write("sanlock service requires restart\n") Line 123: else: Line 124: sys.stdout.write("sanlock service is already configured\n") Line 125: retval = 1 -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (1 comment) File lib/vdsm/tool/configurator.py Line 98: Line 99: try: Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") yes, in procedural like mean... which is invalid. either use: with open() as f: move all logic here so it will be closed when return/exit/exception whatever automatically. or use try and finally. Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Federico Simoncelli has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (2 comments) File lib/vdsm/tool/configurator.py Line 98: Line 99: try: Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") As soon as the object is deallocated (exit from this function) the file is closed. Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: because it's racy and you might get and ENOENT anyway Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 107: raise Line 108: -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (2 comments) File lib/vdsm/tool/configurator.py Line 98: Line 99: try: Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") I do not understand this comment... Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 100: with open(sanlock_pid_file, "r") as f: Line 101: sanlock_pid = f.readline().strip() Line 102: sanlock_status = open(proc_status_path % sanlock_pid, "r") Line 103: except IOError as e: Line 104: if e.errno == os.errno.ENOENT: oh... understood. Line 105: sys.stdout.write("sanlock service is not running\n") Line 106: return retval # service is not running, returning Line 107: raise Line 108: -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (1 comment) File init/sysvinit/vdsmd.init.in Line 61:initctl stop "${srv}" || : # stop fails when already down Line 62:initctl status "${srv}" | grep -q stop/waiting Line 63:elif [ -x "/etc/init.d/${srv}" ]; then Line 64: ! service "${srv}" status >/dev/null 2>&1 || Line 65: service "${srv}" stop done in http://gerrit.ovirt.org/20061 Line 66:else Line 67:true Line 68:fi Line 69: fi -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Dan Kenigsberg has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: Code-Review-1 (2 comments) -1 is a note to self about this requiring a rebase. Commit Message Line 10: services. This patch replace the restart with a print to user. Line 11: Line 12: For backward compatibility we keep the restart over old usages. Line 13: Line 14: To allow reconfiguration for both sanlock and libvirt we merge the I was easier on me if this had had been done in two steps. Line 15: configuration tools to configurator.py and add configure-all verb as Line 16: part of the patch. Line 17: Line 18: Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 File lib/vdsm/tool/configurator.py Line 126: Line 127: return retval Line 128: Line 129: Line 130: @vdsm.tool.expose("configure-all") nit: I think the command name should mention that it restarts the services, too. Line 131: def configure_all(*args): Line 132: """ Line 133: Configure related services for vdsm and restart them. --force for Line 134: forcing restart of related services after configure -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (1 comment) File lib/vdsm/tool/configurator.py Line 137: service.service_stop("supervdsmd") Line 138: service.service_stop("libvirtd") Line 139: Line 140: if not configure_libvirt(*args): Line 141: sys.stderr.write("failed to run configure-libvirt\n") errr now i recall. configure_libvirt already throws an RuntimeException if rc!=0 so it's not required here. leaving the call as it was in previous ps. Line 142: if sanlock_check_service(*args): -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (1 comment) Commit Message Line 10: services. This patch replace the restart with a print to user. Line 11: Line 12: For backward compatibility we keep the restart over old usages. Line 13: Line 14: To allow reconfiguration for both sanlock and libvirt we merge the it'll be hard to manage now ... but ill try Line 15: configuration tools to configurator.py and add configure-all verb as Line 16: part of the patch. Line 17: Line 18: Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 10: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4920/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4035/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4845/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 10 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 9: (1 comment) File lib/vdsm/tool/configurator.py Line 117: raise RuntimeError("Unable to find sanlock service groups") Line 118: Line 119: sanlock_status.close() Line 120: diskimage_gid = grp.getgrnam(DISKIMAGE_GROUP)[2] Line 121: if diskimage_gid in groups: first it should be "not in" as you say, so just to clarify, it was wrong all the way. second, the function is not returnning an error, it returns 0 if service is required a restart, or 1 if not, but it shouldn't be an exception Line 122: sys.stdout.write("sanlock service requires restart\n") Line 123: else: Line 124: sys.stdout.write("sanlock service is already configured\n") Line 125: retval = 1 -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Alon Bar-Lev has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 11: (1 comment) File init/vdsmd_init_common.sh.in Line 50: # If sanlock was started before the *first* installation of vdsm Line 51: # then it is probably missing the supplementary groups. Line 52: # Here we attempt to restart the service (when needed) to refresh Line 53: # the groups. Line 54: if "$VDSM_TOOL" sanlock-check-service; then the tool should return success (0) if service is ok, something is not right either in message and return or in vdsm tool. Line 55: echo "Perform 'vdsm-tool service-restart sanlock' and start vdsm again" Line 56: return 1 Line 57: fi Line 58: return 0 -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 11 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 11: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4950/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4064/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4874/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 11 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 12: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4963/ : ABORTED http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4077/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4887/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 12 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
oVirt Jenkins CI Server has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 13: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4969/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/4083/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4893/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 13 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Nir Soffer has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 13: (1 comment) Commit message title looks wrong Commit Message Line 3: AuthorDate: 2013-10-10 18:38:09 +0300 Line 4: Commit: Yaniv Bronhaim Line 5: CommitDate: 2013-10-13 19:05:06 +0300 Line 6: Line 7: Avoiding automatically restart of sanlock service when starting vdsmd s/automatically/automatic/ Line 8: Line 9: Init scripts are not supposed to perform automatic restart to external Line 10: services. This patch replace the restart with a print to user. Line 11: -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 13 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: Avoiding automatically restart of sanlock service when start...
Yaniv Bronhaim has posted comments on this change. Change subject: Avoiding automatically restart of sanlock service when starting vdsmd .. Patch Set 13: :) I didn't even notice.. thanks -- To view, visit http://gerrit.ovirt.org/19890 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I48658066f707632719df8d65799d26c7b239dcd5 Gerrit-PatchSet: 13 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Yaniv Bronhaim Gerrit-Reviewer: Alon Bar-Lev Gerrit-Reviewer: Dan Kenigsberg Gerrit-Reviewer: Federico Simoncelli Gerrit-Reviewer: Nir Soffer Gerrit-Reviewer: Yaniv Bronhaim Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches