ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vbrodets...@apache.org
Subject ambari git commit: AMBARI-18274. Hive service check failed.(vbrodetskyi)
Date Fri, 02 Sep 2016 14:20:59 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 1f18805d3 -> 7c4fefe4e


AMBARI-18274. Hive service check failed.(vbrodetskyi)


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

Branch: refs/heads/trunk
Commit: 7c4fefe4ed2585bcace0ffe80ee62cc4f523a0fe
Parents: 1f18805
Author: Vitaly Brodetskyi <vbrodetskyi@hortonworks.com>
Authored: Fri Sep 2 17:17:06 2016 +0300
Committer: Vitaly Brodetskyi <vbrodetskyi@hortonworks.com>
Committed: Fri Sep 2 17:17:06 2016 +0300

----------------------------------------------------------------------
 .../BlueprintConfigurationProcessor.java        |  2 +-
 .../2.1.0.2.0/package/scripts/params_linux.py   |  3 +-
 .../HIVE/0.12.0.2.0/configuration/hcat-env.xml  |  2 +-
 .../HIVE/0.12.0.2.0/configuration/hive-env.xml  | 12 --------
 .../HIVE/0.12.0.2.0/package/scripts/hcat.py     |  6 ++--
 .../package/scripts/hcat_service_check.py       |  2 +-
 .../HIVE/0.12.0.2.0/package/scripts/hive.py     |  2 +-
 .../0.12.0.2.0/package/scripts/params_linux.py  |  3 +-
 .../HIVE/0.12.0.2.0/package/scripts/webhcat.py  |  4 +--
 .../BlueprintConfigurationProcessorTest.java    | 31 ++++++++++++--------
 10 files changed, 29 insertions(+), 38 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java
index ac698c1..822c1a4 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessor.java
@@ -2725,7 +2725,7 @@ public class BlueprintConfigurationProcessor {
 
     if (services.contains("HIVE")) {
       userProps.put("hive_user", "hive-env");
-      userProps.put("hcat_user", "hive-env");
+      userProps.put("webhcat_user", "hive-env");
     }
 
     if (services.contains("HBASE")) {

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/params_linux.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/params_linux.py
b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/params_linux.py
index f769114..d54c298 100644
--- a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/params_linux.py
+++ b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/params_linux.py
@@ -205,8 +205,7 @@ if has_ganglia_server:
 yarn_user = config['configurations']['yarn-env']['yarn_user']
 hbase_user = config['configurations']['hbase-env']['hbase_user']
 oozie_user = config['configurations']['oozie-env']['oozie_user']
-webhcat_user = config['configurations']['hive-env']['hcat_user']
-hcat_user = config['configurations']['hive-env']['hcat_user']
+webhcat_user = config['configurations']['hive-env']['webhcat_user']
 hive_user = config['configurations']['hive-env']['hive_user']
 smoke_user =  config['configurations']['cluster-env']['smokeuser']
 smokeuser_principal =  config['configurations']['cluster-env']['smokeuser_principal_name']

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hcat-env.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hcat-env.xml
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hcat-env.xml
index 4fc7198..70f73f0 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hcat-env.xml
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hcat-env.xml
@@ -49,7 +49,7 @@
       HADOOP_HOME=${HADOOP_HOME:-{{hadoop_home}}}
       #DBROOT is the path where the connector jars are downloaded
       DBROOT={{hcat_dbroot}}
-      USER={{hcat_user}}
+      USER={{webhcat_user}}
       METASTORE_PORT={{hive_metastore_port}}
     </value>
     <value-attributes>

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
index 150f629..de088dc 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/configuration/hive-env.xml
@@ -155,18 +155,6 @@
     <on-ambari-upgrade add="true"/>
   </property>
   <property>
-    <name>hcat_user</name>
-    <display-name>HCat User</display-name>
-    <value>hcat</value>
-    <property-type>USER</property-type>
-    <description>HCat User.</description>
-    <value-attributes>
-      <type>user</type>
-      <overridable>false</overridable>
-    </value-attributes>
-    <on-ambari-upgrade add="true"/>
-  </property>
-  <property>
     <name>webhcat_user</name>
     <display-name>WebHCat User</display-name>
     <value>hcat</value>

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat.py
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat.py
index 2cbc2a5..e952767 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat.py
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat.py
@@ -51,14 +51,14 @@ def hcat():
 
   Directory(params.hive_conf_dir,
             create_parents = True,
-            owner=params.hcat_user,
+            owner=params.webhcat_user,
             group=params.user_group,
   )
 
 
   Directory(params.hcat_conf_dir,
             create_parents = True,
-            owner=params.hcat_user,
+            owner=params.webhcat_user,
             group=params.user_group,
   )
 
@@ -76,7 +76,7 @@ def hcat():
             mode=0644)
 
   File(format("{hcat_conf_dir}/hcat-env.sh"),
-       owner=params.hcat_user,
+       owner=params.webhcat_user,
        group=params.user_group,
        content=InlineTemplate(params.hcat_env_sh_template)
   )

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_service_check.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_service_check.py
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_service_check.py
index 386a0a0..25d0c81 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_service_check.py
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hcat_service_check.py
@@ -32,7 +32,7 @@ def hcat_service_check():
   import params
   smoke_cmd = os.path.join(params.stack_root, "Run-SmokeTests.cmd")
   service = "HCatalog"
-  Execute(format("cmd /C {smoke_cmd} {service}"), user=params.hcat_user, logoutput=True)
+  Execute(format("cmd /C {smoke_cmd} {service}"), user=params.webhcat_user, logoutput=True)
 
 
 @OsFamilyFuncImpl(os_family=OsFamilyImpl.DEFAULT)

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py
index 4f53ea9..3249dd4 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py
@@ -122,7 +122,7 @@ def hive(name=None):
       params.HdfsResource(params.hcat_hdfs_user_dir,
                            type="directory",
                            action="create_on_execute",
-                           owner=params.hcat_user,
+                           owner=params.webhcat_user,
                            mode=params.hcat_hdfs_user_mode
       )
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
index 5e3e233..d5ad244 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/params_linux.py
@@ -424,7 +424,6 @@ init_metastore_schema = upgrade_direction is None
 ########## HCAT
 hcat_dbroot = hcat_lib
 
-hcat_user = config['configurations']['hive-env']['hcat_user']
 webhcat_user = config['configurations']['hive-env']['webhcat_user']
 
 hcat_pid_dir = status_params.hcat_pid_dir
@@ -542,7 +541,7 @@ templeton_jar = config['configurations']['webhcat-site']['templeton.jar']
 
 webhcat_server_host = config['clusterHostInfo']['webhcat_server_host']
 
-hcat_hdfs_user_dir = format("/user/{hcat_user}")
+hcat_hdfs_user_dir = format("/user/{webhcat_user}")
 hcat_hdfs_user_mode = 0755
 webhcat_hdfs_user_dir = format("/user/{webhcat_user}")
 webhcat_hdfs_user_mode = 0755

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/webhcat.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/webhcat.py
b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/webhcat.py
index 9140b02..a7feb60 100644
--- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/webhcat.py
+++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/webhcat.py
@@ -44,8 +44,8 @@ def webhcat():
   # Manually overriding service logon user & password set by the installation package
   ServiceConfig(params.webhcat_server_win_service_name,
                 action="change_user",
-                username = params.hcat_user,
-                password = Script.get_password(params.hcat_user))
+                username = params.webhcat_user,
+                password = Script.get_password(params.webhcat_user))
 
 
 @OsFamilyFuncImpl(os_family=OsFamilyImpl.DEFAULT)

http://git-wip-us.apache.org/repos/asf/ambari/blob/7c4fefe4/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessorTest.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessorTest.java
b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessorTest.java
index 2c32f7c..950ade5 100644
--- a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessorTest.java
+++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintConfigurationProcessorTest.java
@@ -18,6 +18,17 @@
 
 package org.apache.ambari.server.controller.internal;
 
+import static junit.framework.Assert.assertEquals;
+import static junit.framework.Assert.assertFalse;
+import static junit.framework.Assert.assertNotNull;
+import static junit.framework.Assert.assertNull;
+import static junit.framework.Assert.assertTrue;
+import static junit.framework.Assert.fail;
+import static org.easymock.EasyMock.anyObject;
+import static org.easymock.EasyMock.expect;
+import static org.easymock.EasyMock.replay;
+import static org.easymock.EasyMock.reset;
+
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
@@ -29,10 +40,9 @@ import java.util.List;
 import java.util.Map;
 import java.util.Set;
 
-import com.google.common.collect.*;
 import org.apache.ambari.server.controller.StackConfigurationResponse;
-import org.apache.ambari.server.state.PropertyInfo;
 import org.apache.ambari.server.state.PropertyDependencyInfo;
+import org.apache.ambari.server.state.PropertyInfo;
 import org.apache.ambari.server.state.ServiceInfo;
 import org.apache.ambari.server.state.ValueAttributesInfo;
 import org.apache.ambari.server.topology.AdvisedConfiguration;
@@ -58,16 +68,11 @@ import org.junit.Before;
 import org.junit.Rule;
 import org.junit.Test;
 
-import static junit.framework.Assert.assertEquals;
-import static junit.framework.Assert.assertFalse;
-import static junit.framework.Assert.assertNotNull;
-import static junit.framework.Assert.assertNull;
-import static junit.framework.Assert.assertTrue;
-import static junit.framework.Assert.fail;
-import static org.easymock.EasyMock.anyObject;
-import static org.easymock.EasyMock.expect;
-import static org.easymock.EasyMock.replay;
-import static org.easymock.EasyMock.reset;
+import com.google.common.collect.ImmutableList;
+import com.google.common.collect.ImmutableMap;
+import com.google.common.collect.ImmutableSet;
+import com.google.common.collect.Lists;
+import com.google.common.collect.Maps;
 
 /**
  * BlueprintConfigurationProcessor unit tests.
@@ -5633,7 +5638,7 @@ public class BlueprintConfigurationProcessorTest {
     oozieEnvProperties.put("oozie_user", "test-oozie-user");
 
     hiveEnvProperties.put("hive_user", "test-hive-user");
-    hiveEnvProperties.put("hcat_user", "test-hcat-user");
+    hiveEnvProperties.put("webhcat_user", "test-hcat-user");
 
     hbaseEnvProperties.put("hbase_user", "test-hbase-user");
 


Mime
View raw message