Change in vdsm[ovirt-3.6]: net: netconf owner change should ignore gid

danken at redhat.com danken at redhat.com
Tue Dec 29 16:06:07 UTC 2015


Dan Kenigsberg has uploaded a new change for review.

Change subject: net: netconf owner change should ignore gid
......................................................................

net: netconf owner change should ignore gid

When changing ownership of the directories/files the group id
does not need to change.
It affects tests which run as non-root (they fail when attempting
to change the gid to root (0).

Change-Id: I059a443d39122490f085d4538c9adf353e17563e
Signed-off-by: Edward Haas <edwardh at redhat.com>
Reviewed-on: https://gerrit.ovirt.org/51148
Reviewed-by: Nir Soffer <nsoffer at redhat.com>
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg <danken at redhat.com>
Tested-by: Dan Kenigsberg <danken at redhat.com>
(cherry picked from commit e98cc411ac055f1e76e039237db2941883bcc52c)
---
M lib/vdsm/netconfpersistence.py
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/49/51149/1

diff --git a/lib/vdsm/netconfpersistence.py b/lib/vdsm/netconfpersistence.py
index 2b0cbd6..97f5518 100644
--- a/lib/vdsm/netconfpersistence.py
+++ b/lib/vdsm/netconfpersistence.py
@@ -172,9 +172,9 @@
 
         # Set owner to vdsm (required by ovirt-node)
         vdsm_uid = pwd.getpwnam(constants.VDSM_USER).pw_uid
-        os.chown(os.path.dirname(dirPath), vdsm_uid, 0)
-        os.chown(dirPath, vdsm_uid, 0)
-        os.chown(path, vdsm_uid, 0)
+        os.chown(os.path.dirname(dirPath), vdsm_uid, -1)
+        os.chown(dirPath, vdsm_uid, -1)
+        os.chown(path, vdsm_uid, -1)
 
     @staticmethod
     def _removeConfig(path):


-- 
To view, visit https://gerrit.ovirt.org/51149
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I059a443d39122490f085d4538c9adf353e17563e
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.6
Gerrit-Owner: Dan Kenigsberg <danken at redhat.com>
Gerrit-Reviewer: Edward Haas <edwardh at redhat.com>


More information about the vdsm-patches mailing list