You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by sm...@apache.org on 2015/06/02 20:55:24 UTC

ambari git commit: AMBARI-11548. DN Decommission does not work when default file system is not hdfs (smohanty)

Repository: ambari
Updated Branches:
  refs/heads/trunk 8dcade74e -> 79437ef2b


AMBARI-11548. DN Decommission does not work when default file system is not hdfs (smohanty)


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

Branch: refs/heads/trunk
Commit: 79437ef2b9a6a85f5f7f5e9c0839e50c5cfe883c
Parents: 8dcade7
Author: Sumit Mohanty <sm...@hortonworks.com>
Authored: Tue Jun 2 11:54:05 2015 -0700
Committer: Sumit Mohanty <sm...@hortonworks.com>
Committed: Tue Jun 2 11:54:05 2015 -0700

----------------------------------------------------------------------
 .../HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py              | 2 +-
 ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/79437ef2/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py
index 2ab3178..874cc6a 100644
--- a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py
+++ b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/hdfs_namenode.py
@@ -335,7 +335,7 @@ def decommission():
       # need to execute each command scoped to a particular namenode
       nn_refresh_cmd = format('dfsadmin -fs hdfs://{namenode_rpc} -refreshNodes')
     else:
-      nn_refresh_cmd = format('dfsadmin -refreshNodes')
+      nn_refresh_cmd = format('dfsadmin -fs {namenode_address} -refreshNodes')
     ExecuteHadoop(nn_refresh_cmd,
                   user=hdfs_user,
                   conf_dir=conf_dir,

http://git-wip-us.apache.org/repos/asf/ambari/blob/79437ef2/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py b/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py
index e9f7829..ddab048 100644
--- a/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py
+++ b/ambari-server/src/test/python/stacks/2.0.6/HDFS/test_namenode.py
@@ -780,7 +780,7 @@ class TestNamenode(RMFTestCase):
                               group = 'hadoop',
                               )
     self.assertResourceCalled('Execute', '', user = 'hdfs')
-    self.assertResourceCalled('ExecuteHadoop', 'dfsadmin -refreshNodes',
+    self.assertResourceCalled('ExecuteHadoop', 'dfsadmin -fs hdfs://c6401.ambari.apache.org:8020 -refreshNodes',
                               user = 'hdfs',
                               conf_dir = '/etc/hadoop/conf',
                               bin_dir = '/usr/bin',
@@ -841,7 +841,7 @@ class TestNamenode(RMFTestCase):
     self.assertResourceCalled('Execute', '/usr/bin/kinit -kt /etc/security/keytabs/nn.service.keytab nn/c6401.ambari.apache.org@EXAMPLE.COM;',
         user = 'hdfs',
     )
-    self.assertResourceCalled('ExecuteHadoop', 'dfsadmin -refreshNodes',
+    self.assertResourceCalled('ExecuteHadoop', 'dfsadmin -fs hdfs://c6401.ambari.apache.org:8020 -refreshNodes',
         bin_dir = '/usr/bin',
         conf_dir = '/etc/hadoop/conf',
         kinit_override = True,