ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aonis...@apache.org
Subject [2/2] ambari git commit: AMBARI-15404. File resource timed out (aonishuk)
Date Tue, 15 Mar 2016 16:25:14 GMT
AMBARI-15404. File resource timed out (aonishuk)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/5a3155fd
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/5a3155fd
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/5a3155fd

Branch: refs/heads/branch-2.2
Commit: 5a3155fd2403a09b9ba11efa2573b5d4e4d8f9e6
Parents: cecacfc
Author: Andrew Onishuk <aonishuk@hortonworks.com>
Authored: Tue Mar 15 18:25:04 2016 +0200
Committer: Andrew Onishuk <aonishuk@hortonworks.com>
Committed: Tue Mar 15 18:25:04 2016 +0200

----------------------------------------------------------------------
 .../src/main/python/resource_management/core/providers/system.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/5a3155fd/ambari-common/src/main/python/resource_management/core/providers/system.py
----------------------------------------------------------------------
diff --git a/ambari-common/src/main/python/resource_management/core/providers/system.py b/ambari-common/src/main/python/resource_management/core/providers/system.py
index 81073bf..43f3474 100644
--- a/ambari-common/src/main/python/resource_management/core/providers/system.py
+++ b/ambari-common/src/main/python/resource_management/core/providers/system.py
@@ -67,8 +67,8 @@ def _ensure_metadata(path, user, group, mode=None, cd_access=None):
     if not re.match("^[ugoa]+$", cd_access):
       raise Fail("'cd_acess' value '%s' is not valid" % (cd_access))
     
-    dir_path = path
-    while not os.path.samefile(dir_path, os.sep):
+    dir_path = re.sub('/+', '/', path)
+    while dir_path != os.sep:
       if sudo.path_isdir(dir_path):
         sudo.chmod_extended(dir_path, cd_access+"+rx")
         


Mime
View raw message