You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ga...@apache.org on 2016/06/15 15:57:22 UTC

[1/2] ambari git commit: AMBARI-17250 : Use right principals for Hbase Master in Kerberos enabled Ranger Hbase Plugin(gautam)

Repository: ambari
Updated Branches:
  refs/heads/branch-2.4 471f1d921 -> fc77dcef1
  refs/heads/trunk b03e8d8e7 -> 010d600d5


AMBARI-17250 : Use right principals for Hbase Master in Kerberos enabled Ranger Hbase Plugin(gautam)


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

Branch: refs/heads/branch-2.4
Commit: fc77dcef19884364dd122cc5a51aea9e02c4e36d
Parents: 471f1d9
Author: Gautam Borad <ga...@apache.org>
Authored: Tue Jun 14 16:51:03 2016 +0530
Committer: Gautam Borad <ga...@apache.org>
Committed: Wed Jun 15 21:26:41 2016 +0530

----------------------------------------------------------------------
 .../HBASE/0.96.0.2.0/package/scripts/params_linux.py          | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/fc77dcef/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py b/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
index a5fbf16..5ce2bd5 100644
--- a/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
+++ b/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
@@ -326,6 +326,11 @@ if has_ranger_admin:
   previous_jdbc_jar = format("{stack_root}/current/{component_directory}/lib/{previous_jdbc_jar_name}") if stack_supports_ranger_audit_db else None
   sql_connector_jar = ''
 
+  if security_enabled:
+    hbase_master_hosts = default('/clusterHostInfo/hbase_master_hosts', [])
+    hbase_master_host = hbase_master_hosts[0] if len(hbase_master_hosts) > 0 else 'localhost'
+    master_principal = config['configurations']['hbase-site']['hbase.master.kerberos.principal'].replace('_HOST', hbase_master_host)
+
   hbase_ranger_plugin_config = {
     'username': repo_config_username,
     'password': repo_config_password,
@@ -335,7 +340,7 @@ if has_ranger_admin:
     'hbase.zookeeper.quorum': hbase_zookeeper_quorum,
     'zookeeper.znode.parent': zookeeper_znode_parent,
     'commonNameForCertificate': common_name_for_certificate,
-    'hbase.master.kerberos.principal': master_jaas_princ if security_enabled else ''
+    'hbase.master.kerberos.principal': master_principal if security_enabled else ''
   }
 
   hbase_ranger_plugin_repo = {


[2/2] ambari git commit: AMBARI-17250 : Use right principals for Hbase Master in Kerberos enabled Ranger Hbase Plugin(gautam)

Posted by ga...@apache.org.
AMBARI-17250 : Use right principals for Hbase Master in Kerberos enabled Ranger Hbase Plugin(gautam)


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

Branch: refs/heads/trunk
Commit: 010d600d5cdd7e409fd62466498b35d6c33b811e
Parents: b03e8d8
Author: Gautam Borad <ga...@apache.org>
Authored: Tue Jun 14 16:51:03 2016 +0530
Committer: Gautam Borad <ga...@apache.org>
Committed: Wed Jun 15 21:26:53 2016 +0530

----------------------------------------------------------------------
 .../HBASE/0.96.0.2.0/package/scripts/params_linux.py          | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/010d600d/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py b/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
index a5fbf16..5ce2bd5 100644
--- a/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
+++ b/ambari-server/src/main/resources/common-services/HBASE/0.96.0.2.0/package/scripts/params_linux.py
@@ -326,6 +326,11 @@ if has_ranger_admin:
   previous_jdbc_jar = format("{stack_root}/current/{component_directory}/lib/{previous_jdbc_jar_name}") if stack_supports_ranger_audit_db else None
   sql_connector_jar = ''
 
+  if security_enabled:
+    hbase_master_hosts = default('/clusterHostInfo/hbase_master_hosts', [])
+    hbase_master_host = hbase_master_hosts[0] if len(hbase_master_hosts) > 0 else 'localhost'
+    master_principal = config['configurations']['hbase-site']['hbase.master.kerberos.principal'].replace('_HOST', hbase_master_host)
+
   hbase_ranger_plugin_config = {
     'username': repo_config_username,
     'password': repo_config_password,
@@ -335,7 +340,7 @@ if has_ranger_admin:
     'hbase.zookeeper.quorum': hbase_zookeeper_quorum,
     'zookeeper.znode.parent': zookeeper_znode_parent,
     'commonNameForCertificate': common_name_for_certificate,
-    'hbase.master.kerberos.principal': master_jaas_princ if security_enabled else ''
+    'hbase.master.kerberos.principal': master_principal if security_enabled else ''
   }
 
   hbase_ranger_plugin_repo = {