Change in vdsm[master]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 9: -Verified Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4637/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4559/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3752/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Dan Kenigsberg has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 9: Code-Review+2 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Dan Kenigsberg has submitted this change and it was merged. Change subject: gluster: bug fix for listing and adding hook .. gluster: bug fix for listing and adding hook Earlier, with regard to gluster hooks there would be definitely a pre and post directory for each and every gluster command. But presently, if either pre or post script is not present there will be no pre or post directories also. Therefore, if there is no such directories available the gluster hook list will simply omit it. When a gluster hook is added if pre or post directories are absent, they will be created accordingly, then the hook will be added. Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=999795 Signed-off-by: Timothy Asir tjeya...@redhat.com Reviewed-on: http://gerrit.ovirt.org/18345 Reviewed-by: Dan Kenigsberg dan...@redhat.com --- M vdsm/gluster/hooks.py 1 file changed, 16 insertions(+), 0 deletions(-) Approvals: Timothy Asir: Verified Dan Kenigsberg: Looks good to me, approved -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 10 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: oVirt Jenkins CI Server ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 9: Verified+1 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 9: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4604/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4526/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3719/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 9 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Saggi Mizrahi has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 8: (3 comments) File vdsm/gluster/hooks.py Line 243: @checkArgs Line 244: @makePublic Line 245: def hookAdd(glusterCmd, hookLevel, hookName, hookData, hookMd5Sum, Line 246: enable=False): Line 247: hookPath = os.path.join(_glusterHooksPath, glusterCmd, hookLevel) Seems like something that should be in a function since you do the join() in multiple places. Line 248: if not os.path.isdir(hookPath): Line 249: try: Line 250: os.makedirs(hookPath) Line 251: except OSError as e: Line 244: @makePublic Line 245: def hookAdd(glusterCmd, hookLevel, hookName, hookData, hookMd5Sum, Line 246: enable=False): Line 247: hookPath = os.path.join(_glusterHooksPath, glusterCmd, hookLevel) Line 248: if not os.path.isdir(hookPath): use os.path.exists() since this is actually what you are checking Also, to avoid races. just remove the conditional and change it to: try: os.makedirs(path) except OSError as e: if e.errno != errno.EEXISTS: raise This will make sure you only create once Line 249: try: Line 250: os.makedirs(hookPath) Line 251: except OSError as e: Line 252: errMsg = [Errno %s] %s: '%s' % (e.errno, e.strerror, e.filename) Line 255:#silently ignore restorecon exceptios, when SELinux is disabled Line 256: try: Line 257: selinux.restorecon(hookPath, recursive=True) Line 258: except OSError: Line 259: logging.error('restorecon %s failed', hookPath, exc_info=True) Also, I'd prefer if you check if selinux is enabled or not so we don't have errors that aren't really errors in the logs Line 260: Line 261: try: Line 262: return _hookUpdateOrAdd(glusterCmd, hookLevel, hookName, hookData, Line 263: hookMd5Sum, update=False, enable=enable) -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com Gerrit-HasComments: Yes ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: gluster: bug fix for listing and adding hook
Dan Kenigsberg has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 8: Code-Review-1 Setting -1 per Sango's comments -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com Gerrit-HasComments: No ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 8: Verified+1 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 8: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4531/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4450/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3634/ : FAILURE -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 8: Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4533/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4452/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3636/ : FAILURE -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 8: Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4541/ : FAILURE http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3644/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4463/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 8 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Bala.FA has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 6: Code-Review-1 (2 comments) File vdsm/gluster/hooks.py Line 248: if not os.path.isdir(hookPath): Line 249: try: Line 250: os.makedirs(hookPath) Line 251: try: Line 252: selinux.restorecon(hookPath) why aren't you recursively doing restorecon? Line 253: except OSError: Line 254: lsetfilecon( Line 255: hookPath, Line 256: selinux.lgetfilecon(_glusterHooksPath)[1]) Line 252: selinux.restorecon(hookPath) Line 253: except OSError: Line 254: lsetfilecon( Line 255: hookPath, Line 256: selinux.lgetfilecon(_glusterHooksPath)[1]) I am not able understand from where you get lsetfilecon()? Line 257: except OSError as e: Line 258: errMsg = [Errno %s] %s: '%s' % (e.errno, e.strerror, e.filename) Line 259: raise ge.GlusterHookAddFailedException(err=[errMsg]) Line 260: -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 6 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 6: (2 comments) File vdsm/gluster/hooks.py Line 248: if not os.path.isdir(hookPath): Line 249: try: Line 250: os.makedirs(hookPath) Line 251: try: Line 252: selinux.restorecon(hookPath) I will add recursive flag (selinux.restorecon(hookPath, recursive=True)) Line 253: except OSError: Line 254: lsetfilecon( Line 255: hookPath, Line 256: selinux.lgetfilecon(_glusterHooksPath)[1]) Line 252: selinux.restorecon(hookPath) Line 253: except OSError: Line 254: lsetfilecon( Line 255: hookPath, Line 256: selinux.lgetfilecon(_glusterHooksPath)[1]) Oops!, its a typo. I will fix this! Line 257: except OSError as e: Line 258: errMsg = [Errno %s] %s: '%s' % (e.errno, e.strerror, e.filename) Line 259: raise ge.GlusterHookAddFailedException(err=[errMsg]) Line 260: -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 6 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 7: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4395/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3498/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4314/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 7 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 5: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4285/ : FAILURE http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3388/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4204/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 5 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 6: Verified-1 Build Failed http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4286/ : FAILURE http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3389/ : FAILURE http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4205/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 6 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 4: Verified+1 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 4: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4238/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3343/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4159/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 4: -Verified Code-Review-1 I will change this to use restorecon instead of xattr for setting SELinux security attribute. -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 4 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Dan Kenigsberg has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 3: Code-Review-1 (2 comments) File vdsm/gluster/hooks.py Line 245: enable=False): Line 246: hookPath = os.path.join(_glusterHooksPath, glusterCmd, hookLevel) Line 247: if not os.path.isdir(hookPath): Line 248: try: Line 249: # create directory if it doesn't exist I find this comment obvious. Line 250: os.makedirs(hookPath) Line 251: except OSError as e: Line 252: errMsg = [Errno %s] %s: '%s' % (e.errno, e.strerror, e.filename) Line 253: raise ge.GlusterHookAddFailedException(err=[errMsg]) Line 246: hookPath = os.path.join(_glusterHooksPath, glusterCmd, hookLevel) Line 247: if not os.path.isdir(hookPath): Line 248: try: Line 249: # create directory if it doesn't exist Line 250: os.makedirs(hookPath) is the directory created with the correct owner and selinux tags? Line 251: except OSError as e: Line 252: errMsg = [Errno %s] %s: '%s' % (e.errno, e.strerror, e.filename) Line 253: raise ge.GlusterHookAddFailedException(err=[errMsg]) Line 254: -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 3: Verified+1 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 3: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4085/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3190/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/4006/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Timothy Asir has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 1: (1 comment) Commit Message Line 12: Therefore, if there is no such directries available the gluster hook list Line 13: will simply omit it. Line 14: When a gluster hook is added if pre or post directories are absent, they Line 15: will be created accordingly, then the hook will be added. Line 16: Done Line 17: Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Line 18: Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=998514 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 2: Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4075/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3180/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/3996/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Federico Simoncelli fsimo...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com Gerrit-Reviewer: Timothy Asir tjeya...@redhat.com 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]: gluster: bug fix for listing and adding hook
Hello Ayal Baron, Bala.FA, Saggi Mizrahi, Dan Kenigsberg, I'd like you to do a code review. Please visit http://gerrit.ovirt.org/18345 to review the following change. Change subject: gluster: bug fix for listing and adding hook .. gluster: bug fix for listing and adding hook Earlier, with regard to gluster hooks there would be definitely a pre and post directory for each and every gluster command. But presently, if either pre or post script is not present there will be no pre or post directories also. Therefore, if there is no such directries available the gluster hook list will simply omit it. When a gluster hook is added if pre or post directories are absent, they will be created accordingly, then the hook will be added. Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=998514 Signed-off-by: Timothy Asir tjeya...@redhat.com --- M vdsm/gluster/hooks.py 1 file changed, 11 insertions(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/45/18345/1 diff --git a/vdsm/gluster/hooks.py b/vdsm/gluster/hooks.py index a78d22b..389da28 100644 --- a/vdsm/gluster/hooks.py +++ b/vdsm/gluster/hooks.py @@ -92,6 +92,8 @@ def _getHooks(gCmd, hookLevel): hooks = [] path = os.path.join(_glusterHooksPath, gCmd, hookLevel.lower()) +if not os.path.isdir(path): +return hooks for hookFile in os.listdir(path): status = getattr(HookStatus, hookFile[0], None) if status: @@ -241,6 +243,15 @@ @makePublic def hookAdd(glusterCmd, hookLevel, hookName, hookData, hookMd5Sum, enable=False): +hookPath = os.path.join(_glusterHooksPath, glusterCmd, hookLevel) +if not os.path.isdir(hookPath): +try: +# create directory if it doesn't exist +os.makedirs(hookPath) +except OSError as e: +errMsg = [Errno %s] %s: '%s' % (e.errno, e.strerror, e.filename) +raise ge.GlusterHookAddFailedException(err=[errMsg]) + try: return _hookUpdateOrAdd(glusterCmd, hookLevel, hookName, hookData, hookMd5Sum, update=False, enable=enable) -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com ___ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
Change in vdsm[master]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 1: Code-Review-1 Build Unstable http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4044/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3149/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/3959/ : UNSTABLE -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com 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]: gluster: bug fix for listing and adding hook
oVirt Jenkins CI Server has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 1: -Code-Review Build Successful http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit/4044/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_unit_tests_gerrit_el/3149/ : SUCCESS http://jenkins.ovirt.org/job/vdsm_pep8_gerrit/3964/ : SUCCESS -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com 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]: gluster: bug fix for listing and adding hook
Bala.FA has posted comments on this change. Change subject: gluster: bug fix for listing and adding hook .. Patch Set 1: Code-Review+1 (1 comment) Commit Message Line 12: Therefore, if there is no such directries available the gluster hook list Line 13: will simply omit it. Line 14: When a gluster hook is added if pre or post directories are absent, they Line 15: will be created accordingly, then the hook will be added. Line 16: please correct few spellings Line 17: Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Line 18: Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=998514 -- To view, visit http://gerrit.ovirt.org/18345 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I470470da153edef3fe7eb3a7d41a775bac208449 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Timothy Asir tjeya...@redhat.com Gerrit-Reviewer: Ayal Baron aba...@redhat.com Gerrit-Reviewer: Bala.FA barum...@redhat.com Gerrit-Reviewer: Dan Kenigsberg dan...@redhat.com Gerrit-Reviewer: Saggi Mizrahi smizr...@redhat.com 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