Sandro Bonazzola has posted comments on this change. Change subject: WIP agent: store metadata on storage domain, sync with sanlock ......................................................................
Patch Set 1: (1 comment) .................................................... File ovirt_hosted_engine_ha/agent/hosted_engine.py Line 258: constants.LOCKSPACE_NAME, host_id, lease_file) Line 259: Line 260: ## BEGIN temp code to init lockspace Line 261: if host_id == 1: Line 262: if not os.access(self._metadata_dir, os.R_OK | os.W_OK): why checking access and if fails create dir? os.path.isdir is enough for saying if a directory exists and mkdir will fail if the dir exists but it's not writable Line 263: os.mkdir(self._metadata_dir) Line 264: if not os.access(lease_file, os.R_OK | os.W_OK): Line 265: open(lease_file, 'a').close() Line 266: os.chmod(lease_file, -- To view, visit http://gerrit.ovirt.org/17609 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I9f09e736f6556c0bf9a435d3a88035d9dbd53883 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-hosted-engine-ha Gerrit-Branch: master Gerrit-Owner: Greg Padgett <gpadg...@redhat.com> Gerrit-Reviewer: Ayal Baron <aba...@redhat.com> Gerrit-Reviewer: Federico Simoncelli <fsimo...@redhat.com> Gerrit-Reviewer: Greg Padgett <gpadg...@redhat.com> Gerrit-Reviewer: Itamar Heim <ih...@redhat.com> Gerrit-Reviewer: Martin Sivák <msi...@redhat.com> Gerrit-Reviewer: Oved Ourfali <oourf...@redhat.com> Gerrit-Reviewer: Sandro Bonazzola <sbona...@redhat.com> Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches