Douglas Schilling Landgraf has uploaded a new change for review. Change subject: configurator: use sanlock group for sanlock check ......................................................................
configurator: use sanlock group for sanlock check During the check if sanlock service is running we look for the group id's from /proc/<sanlock pid>/status to finally do a last validation against DISKIMAGE_GROUP. However, DISKIMAGE_GROUP is a constant for qemu group not sanlock group. This patch will add a new constant and use it in configurator.py Change-Id: Ib1dc5f3b0678f4c6811c7c22287da2a1d4480164 Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1055153 Signed-off-by: Douglas Schilling Landgraf <[email protected]> --- M lib/vdsm/constants.py.in M lib/vdsm/tool/configurator.py 2 files changed, 3 insertions(+), 2 deletions(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/88/23788/1 diff --git a/lib/vdsm/constants.py.in b/lib/vdsm/constants.py.in index 6653d54..35d3386 100644 --- a/lib/vdsm/constants.py.in +++ b/lib/vdsm/constants.py.in @@ -40,6 +40,7 @@ METADATA_GROUP = '@METADATAGROUP@' QEMU_PROCESS_USER = '@QEMUUSER@' QEMU_PROCESS_GROUP = '@QEMUGROUP@' +SANLOCK_GROUP = '@SNLKGROUP@' # # The username of SASL authenticating for libvirt connection diff --git a/lib/vdsm/tool/configurator.py b/lib/vdsm/tool/configurator.py index dfc4115..7573797 100644 --- a/lib/vdsm/tool/configurator.py +++ b/lib/vdsm/tool/configurator.py @@ -24,7 +24,7 @@ from .. import utils from . import service, expose -from ..constants import P_VDSM_EXEC, DISKIMAGE_GROUP +from ..constants import P_VDSM_EXEC, SANLOCK_GROUP from ..constants import QEMU_PROCESS_GROUP, VDSM_GROUP @@ -159,7 +159,7 @@ break else: raise RuntimeError("Unable to find sanlock service groups") - configured = grp.getgrnam(DISKIMAGE_GROUP)[2] in groups + configured = grp.getgrnam(SANLOCK_GROUP)[2] in groups except IOError as e: if e.errno == os.errno.ENOENT: sys.stdout.write("sanlock service is not running\n") -- To view, visit http://gerrit.ovirt.org/23788 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ib1dc5f3b0678f4c6811c7c22287da2a1d4480164 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Douglas Schilling Landgraf <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
