You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ab...@apache.org on 2014/10/24 21:46:05 UTC
[1/3] git commit: AMBARI-7851 - HCatalog and WebHCat components in
HDPWIN should be part of Hive service
Repository: ambari
Updated Branches:
refs/heads/branch-windows-dev 588a2cfc4 -> 28e157747
AMBARI-7851 - HCatalog and WebHCat components in HDPWIN should be part of Hive service
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/892ebe4f
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/892ebe4f
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/892ebe4f
Branch: refs/heads/branch-windows-dev
Commit: 892ebe4ff587bbec926fd01f9dd374495a52c1eb
Parents: 588a2cf
Author: Artem Baranchuk <ab...@hortonworks.com>
Authored: Tue Oct 21 23:53:05 2014 +0300
Committer: Artem Baranchuk <ab...@hortonworks.com>
Committed: Fri Oct 24 17:00:06 2014 +0300
----------------------------------------------------------------------
.../stacks/HDPWIN/2.1/role_command_order.json | 4 +-
.../services/HIVE/configuration/hive-site.xml | 2 +-
.../HIVE/configuration/webhcat-site.xml | 109 +++++++++++++++++++
.../HDPWIN/2.1/services/HIVE/metainfo.xml | 86 ++++++++++++---
.../HIVE/package/files/templetonSmoke.sh | 96 ++++++++++++++++
.../2.1/services/HIVE/package/scripts/params.py | 2 +
.../HIVE/package/scripts/service_check.py | 3 +
.../HIVE/package/scripts/service_mapping.py | 3 +-
.../services/HIVE/package/scripts/webhcat.py | 30 +++++
.../HIVE/package/scripts/webhcat_server.py | 48 ++++++++
.../package/scripts/webhcat_service_check.py | 27 +++++
.../HIVE/package/templates/webhcat-env.sh.j2 | 62 +++++++++++
.../WEBHCAT/configuration/webhcat-site.xml | 109 -------------------
.../HDPWIN/2.1/services/WEBHCAT/metainfo.xml | 85 ---------------
.../WEBHCAT/package/files/templetonSmoke.sh | 96 ----------------
.../services/WEBHCAT/package/scripts/params.py | 29 -----
.../WEBHCAT/package/scripts/service_check.py | 32 ------
.../WEBHCAT/package/scripts/service_mapping.py | 20 ----
.../services/WEBHCAT/package/scripts/webhcat.py | 30 -----
.../WEBHCAT/package/scripts/webhcat_server.py | 48 --------
.../WEBHCAT/package/templates/webhcat-env.sh.j2 | 62 -----------
.../app/controllers/wizard/step5_controller.js | 4 +-
22 files changed, 452 insertions(+), 535 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/role_command_order.json
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/role_command_order.json b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/role_command_order.json
index 549b6c7..47cd50d 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/role_command_order.json
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/role_command_order.json
@@ -21,10 +21,8 @@
"WEBHCAT_SERVER-START", "FLUME_HANDLER-START"],
"MAPREDUCE_SERVICE_CHECK-SERVICE_CHECK": ["JOBTRACKER-START", "TASKTRACKER-START"],
"OOZIE_SERVICE_CHECK-SERVICE_CHECK": ["OOZIE_SERVER-START", "MAPREDUCE2_SERVICE_CHECK-SERVICE_CHECK"],
- "WEBHCAT_SERVICE_CHECK-SERVICE_CHECK": ["WEBHCAT_SERVER-START"],
"HBASE_SERVICE_CHECK-SERVICE_CHECK": ["HBASE_MASTER-START", "HBASE_REGIONSERVER-START"],
- "HIVE_SERVICE_CHECK-SERVICE_CHECK": ["HIVE_SERVER-START", "HIVE_METASTORE-START"],
- "HCAT_SERVICE_CHECK-SERVICE_CHECK": ["HIVE_SERVER-START"],
+ "HIVE_SERVICE_CHECK-SERVICE_CHECK": ["HIVE_SERVER-START", "HIVE_METASTORE-START", "WEBHCAT_SERVER-START"],
"PIG_SERVICE_CHECK-SERVICE_CHECK": ["JOBTRACKER-START", "TASKTRACKER-START"],
"SQOOP_SERVICE_CHECK-SERVICE_CHECK": ["JOBTRACKER-START", "TASKTRACKER-START"],
"ZOOKEEPER_SERVICE_CHECK-SERVICE_CHECK": ["ZOOKEEPER_SERVER-START"],
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/hive-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/hive-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/hive-site.xml
index 01be0a3..3f90c76 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/hive-site.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/hive-site.xml
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
-<configuration>
+<configuration supports_final="true">
<!-- Hive Configuration can either be stored in this file or in the hadoop configuration files -->
<!-- that are implied by Hadoop setup variables. -->
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/webhcat-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/webhcat-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/webhcat-site.xml
new file mode 100644
index 0000000..bae9712
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/configuration/webhcat-site.xml
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+-->
+
+<!-- The default settings for Templeton. -->
+<!-- Edit templeton-site.xml to change settings for your local -->
+<!-- install. -->
+
+<configuration>
+
+ <property>
+ <name>templeton.port</name>
+ <value>50111</value>
+ <description>The HTTP port for the main server.</description>
+ </property>
+
+ <property>
+ <name>templeton.jar</name>
+ <value>c:\hdp\hive\hcatalog\share\webhcat\svr\lib\hive-webhca.jar</value>
+ <description>The path to the Templeton jar file.</description>
+ </property>
+
+ <property>
+ <name>templeton.override.enabled</name>
+ <value>false</value>
+ <description>
+ Enable the override path in templeton.override.jars
+ </description>
+ </property>
+
+ <property>
+ <name>templeton.hcat</name>
+ <value>${env.HCAT_HOME}/bin/hcat.py</value>
+ <description>The path to the hcatalog executable.</description>
+ </property>
+
+ <property>
+ <name>templeton.hadoop</name>
+ <value>${env.HADOOP_HOME}/bin/hadoop.cmd</value>
+ <description>The path to the Hadoop executable.</description>
+ </property>
+
+ <property>
+ <name>templeton.exec.envs</name>
+ <value>HADOOP_HOME,JAVA_HOME,HIVE_HOME,TEMP,HADOOP_BIN_PATH,PATH,SystemRoot,TEZ_CLASSPATH</value>
+ <description>The environment variables passed through to exec.</description>
+ </property>
+
+ <property>
+ <name>templeton.streaming.jar</name>
+ <value>file:///c:/hdp/hadoop/share/hadoop/tools/lib/hadoop-streaming.jar</value>
+ <description>The hdfs path to the Hadoop streaming jar file.</description>
+ </property>
+
+ <property>
+ <name>templeton.hive.properties</name>
+ <value>hive.metastore.local=false,hive.metastore.uris=thrift://WIN-QS1HDPKHRAM:9083</value>
+ <description>Properties to set when running hive.</description>
+ </property>
+
+ <property>
+ <name>templeton.libjars</name>
+ <value>file:///c:/hdp/hive/lib/zookeeper.jar</value>
+ <description>Jars to add to the classpath.</description>
+ </property>
+
+ <property>
+ <name>templeton.pig.path</name>
+ <value>${env.PIG_HOME}/bin/pig.cmd</value>
+ <description>The path to the Pig executable.</description>
+ </property>
+
+ <property>
+ <name>templeton.hive.path</name>
+ <value>${env.HIVE_HOME}/bin/hive.cmd</value>
+ <description>The path to the Hive executable.</description>
+ </property>
+
+
+ <property>
+ <name>templeton.hadoop.queue.name</name>
+ <value>joblauncher</value>
+ </property>
+
+ <property>
+ <name>templeton.zookeeper.hosts</name>
+ <value>localhost:2181</value>
+ </property>
+
+ <property>
+ <name>templeton.storage.class</name>
+ <value>org.apache.hive.hcatalog.templeton.tool.ZooKeeperStorage</value>
+ </property>
+</configuration>
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/metainfo.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/metainfo.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/metainfo.xml
index bd9c8e4..ed6be9e 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/metainfo.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/metainfo.xml
@@ -20,12 +20,14 @@
<services>
<service>
<name>HIVE</name>
+ <displayName>Hive</displayName>
<comment>Data warehouse system for ad-hoc queries & analysis of large datasets and table & storage management service</comment>
<version>0.12.0.2.0</version>
<components>
<component>
<name>HIVE_METASTORE</name>
+ <displayName>Hive Metastore</displayName>
<category>MASTER</category>
<cardinality>1</cardinality>
<auto-deploy>
@@ -41,6 +43,7 @@
<component>
<name>HIVE_SERVER</name>
+ <displayName>HiveServer2</displayName>
<category>MASTER</category>
<cardinality>1</cardinality>
<dependencies>
@@ -82,6 +85,7 @@
<component>
<name>MYSQL_SERVER</name>
+ <displayName>MySQL Server</displayName>
<category>MASTER</category>
<cardinality>1</cardinality>
<commandScript>
@@ -92,6 +96,7 @@
<component>
<name>HIVE_CLIENT</name>
+ <displayName>Hive Client</displayName>
<category>CLIENT</category>
<cardinality>0+</cardinality>
<commandScript>
@@ -99,41 +104,88 @@
<scriptType>PYTHON</scriptType>
</commandScript>
</component>
- </components>
-
- <commandScript>
- <script>scripts/service_check.py</script>
- <scriptType>PYTHON</scriptType>
- <timeout>1200</timeout>
- </commandScript>
- <configuration-dependencies>
- <config-type>hive-site</config-type>
- <config-type>hive-env</config-type>
- </configuration-dependencies>
- </service>
- <service>
- <name>HCATALOG</name>
- <comment>This is comment for HCATALOG service</comment>
- <version>0.12.0.2.0.6.0</version>
- <components>
<component>
<name>HCAT</name>
+ <displayName>HCat Client</displayName>
<category>CLIENT</category>
+ <cardinality>0+</cardinality>
<commandScript>
<script>scripts/hcat_client.py</script>
<scriptType>PYTHON</scriptType>
</commandScript>
</component>
+
+ <component>
+ <name>WEBHCAT_SERVER</name>
+ <displayName>WebHCat Server</displayName>
+ <category>MASTER</category>
+ <cardinality>1</cardinality>
+ <clientsToUpdateConfigs>
+ <client>HCAT</client>
+ </clientsToUpdateConfigs>
+ <dependencies>
+ <dependency>
+ <name>HDFS/HDFS_CLIENT</name>
+ <scope>host</scope>
+ <auto-deploy>
+ <enabled>true</enabled>
+ </auto-deploy>
+ </dependency>
+ <dependency>
+ <name>MAPREDUCE2/MAPREDUCE2_CLIENT</name>
+ <scope>host</scope>
+ <auto-deploy>
+ <enabled>true</enabled>
+ </auto-deploy>
+ </dependency>
+ <dependency>
+ <name>ZOOKEEPER/ZOOKEEPER_SERVER</name>
+ <scope>cluster</scope>
+ <auto-deploy>
+ <enabled>true</enabled>
+ <co-locate>HIVE/WEBHCAT_SERVER</co-locate>
+ </auto-deploy>
+ </dependency>
+ <dependency>
+ <name>ZOOKEEPER/ZOOKEEPER_CLIENT</name>
+ <scope>host</scope>
+ <auto-deploy>
+ <enabled>true</enabled>
+ </auto-deploy>
+ </dependency>
+ <dependency>
+ <name>YARN/YARN_CLIENT</name>
+ <scope>host</scope>
+ <auto-deploy>
+ <enabled>true</enabled>
+ </auto-deploy>
+ </dependency>
+ </dependencies>
+ <commandScript>
+ <script>scripts/webhcat_server.py</script>
+ <scriptType>PYTHON</scriptType>
+ <timeout>1200</timeout>
+ </commandScript>
+ </component>
</components>
+
<commandScript>
<script>scripts/service_check.py</script>
<scriptType>PYTHON</scriptType>
<timeout>1200</timeout>
</commandScript>
+
+ <requiredServices>
+ <service>ZOOKEEPER</service>
+ <service>YARN</service>
+ <service>TEZ</service>
+ </requiredServices>
+
<configuration-dependencies>
<config-type>hive-site</config-type>
<config-type>hive-env</config-type>
+ <config-type>webhcat-site</config-type>
</configuration-dependencies>
</service>
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/files/templetonSmoke.sh
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/files/templetonSmoke.sh b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/files/templetonSmoke.sh
new file mode 100644
index 0000000..2d07b8b
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/files/templetonSmoke.sh
@@ -0,0 +1,96 @@
+#!/usr/bin/env bash
+#
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#
+
+export ttonhost=$1
+export smoke_test_user=$2
+export smoke_user_keytab=$3
+export security_enabled=$4
+export kinit_path_local=$5
+export ttonurl="http://${ttonhost}:50111/templeton/v1"
+
+if [[ $security_enabled == "true" ]]; then
+ kinitcmd="${kinit_path_local} -kt ${smoke_user_keytab} ${smoke_test_user}; "
+else
+ kinitcmd=""
+fi
+
+export no_proxy=$ttonhost
+cmd="${kinitcmd}curl --negotiate -u : -s -w 'http_code <%{http_code}>' $ttonurl/status 2>&1"
+retVal=`su - ${smoke_test_user} -c "$cmd"`
+httpExitCode=`echo $retVal |sed 's/.*http_code <\([0-9]*\)>.*/\1/'`
+
+if [[ "$httpExitCode" -ne "200" ]] ; then
+ echo "Templeton Smoke Test (status cmd): Failed. : $retVal"
+ export TEMPLETON_EXIT_CODE=1
+ exit 1
+fi
+
+exit 0
+
+#try hcat ddl command
+echo "user.name=${smoke_test_user}&exec=show databases;" /tmp/show_db.post.txt
+cmd="${kinitcmd}curl --negotiate -u : -s -w 'http_code <%{http_code}>' -d \@${destdir}/show_db.post.txt $ttonurl/ddl 2>&1"
+retVal=`su - ${smoke_test_user} -c "$cmd"`
+httpExitCode=`echo $retVal |sed 's/.*http_code <\([0-9]*\)>.*/\1/'`
+
+if [[ "$httpExitCode" -ne "200" ]] ; then
+ echo "Templeton Smoke Test (ddl cmd): Failed. : $retVal"
+ export TEMPLETON_EXIT_CODE=1
+ exit 1
+fi
+
+# NOT SURE?? SUHAS
+if [[ $security_enabled == "true" ]]; then
+ echo "Templeton Pig Smoke Tests not run in secure mode"
+ exit 0
+fi
+
+#try pig query
+outname=${smoke_test_user}.`date +"%M%d%y"`.$$;
+ttonTestOutput="/tmp/idtest.${outname}.out";
+ttonTestInput="/tmp/idtest.${outname}.in";
+ttonTestScript="idtest.${outname}.pig"
+
+echo "A = load '$ttonTestInput' using PigStorage(':');" > /tmp/$ttonTestScript
+echo "B = foreach A generate \$0 as id; " >> /tmp/$ttonTestScript
+echo "store B into '$ttonTestOutput';" >> /tmp/$ttonTestScript
+
+#copy pig script to hdfs
+su - ${smoke_test_user} -c "hadoop dfs -copyFromLocal /tmp/$ttonTestScript /tmp/$ttonTestScript"
+
+#copy input file to hdfs
+su - ${smoke_test_user} -c "hadoop dfs -copyFromLocal /etc/passwd $ttonTestInput"
+
+#create, copy post args file
+echo -n "user.name=${smoke_test_user}&file=/tmp/$ttonTestScript" > /tmp/pig_post.txt
+
+#submit pig query
+cmd="curl -s -w 'http_code <%{http_code}>' -d \@${destdir}/pig_post.txt $ttonurl/pig 2>&1"
+retVal=`su - ${smoke_test_user} -c "$cmd"`
+httpExitCode=`echo $retVal |sed 's/.*http_code <\([0-9]*\)>.*/\1/'`
+if [[ "$httpExitCode" -ne "200" ]] ; then
+ echo "Templeton Smoke Test (pig cmd): Failed. : $retVal"
+ export TEMPLETON_EXIT_CODE=1
+ exit 1
+fi
+
+exit 0
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/params.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/params.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/params.py
index a91b82c..041669f 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/params.py
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/params.py
@@ -30,8 +30,10 @@ hive_lib_dir = os.environ["HIVE_LIB_DIR"]
hive_log_dir = os.environ["HIVE_LOG_DIR"]
hive_opts = os.environ["HIVE_OPTS"]
hcat_home = os.environ["HCAT_HOME"]
+hcat_config_dir = os.environ["WEBHCAT_CONF_DIR"]
hive_env_sh_template = config['configurations']['hive-env']['content']
hive_warehouse_dir = config['configurations']['hive-site']['hive.metastore.warehouse.dir']
hive_user = "hadoop"
hadoop_user = "hadoop"
+hcat_user = "hadoop"
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_check.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_check.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_check.py
index 8d8a9f2..619be7a 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_check.py
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_check.py
@@ -23,6 +23,7 @@ import socket
import sys
from hcat_service_check import hcat_service_check
+from webhcat_service_check import webhcat_service_check
class HiveServiceCheck(Script):
def service_check(self, env):
@@ -32,5 +33,7 @@ class HiveServiceCheck(Script):
service = "HIVE"
Execute(format("cmd /C {smoke_cmd} {service}"), user=params.hive_user, logoutput=True)
+ webhcat_service_check()
+
if __name__ == "__main__":
HiveServiceCheck().execute()
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_mapping.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_mapping.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_mapping.py
index 5ab9742..84dd897 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_mapping.py
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/service_mapping.py
@@ -19,4 +19,5 @@ limitations under the License.
hive_metastore_win_service_name = "metastore"
hive_client_win_service_name = "hwi"
-hive_server_win_service_name = "hiveserver2"
\ No newline at end of file
+hive_server_win_service_name = "hiveserver2"
+webhcat_server_win_service_name = "templeton"
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat.py
new file mode 100644
index 0000000..032ca79
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat.py
@@ -0,0 +1,30 @@
+"""
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+Ambari Agent
+
+"""
+from resource_management import *
+import sys
+
+
+def webhcat():
+ import params
+ XmlConfig("webhcat-site.xml",
+ conf_dir=params.config_dir,
+ configurations=params.config['configurations']['webhcat-site']
+ )
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_server.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_server.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_server.py
new file mode 100644
index 0000000..527efb8
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_server.py
@@ -0,0 +1,48 @@
+"""
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+Ambari Agent
+
+"""
+import sys
+from resource_management import *
+from webhcat import webhcat
+import service_mapping
+
+class WebHCatServer(Script):
+ def install(self, env):
+ if not check_windows_service_exists(service_mapping.webhcat_server_win_service_name):
+ self.install_packages(env)
+
+ def configure(self, env):
+ import params
+ env.set_params(params)
+ webhcat()
+
+ def start(self, env):
+ import params
+ self.configure(env) # FOR SECURITY
+ Service(service_mapping.webhcat_server_win_service_name, action="start")
+
+ def stop(self, env):
+ Service(service_mapping.webhcat_server_win_service_name, action="stop")
+
+ def status(self, env):
+ check_windows_service_status(service_mapping.webhcat_server_win_service_name)
+
+if __name__ == "__main__":
+ WebHCatServer().execute()
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_service_check.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_service_check.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_service_check.py
new file mode 100644
index 0000000..1fa08a3
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/scripts/webhcat_service_check.py
@@ -0,0 +1,27 @@
+"""
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+Ambari Agent
+
+"""
+from resource_management import *
+
+def webhcat_service_check():
+ import params
+ smoke_cmd = os.path.join(params.hdp_root,"Run-SmokeTests.cmd")
+ service = "WEBHCAT"
+ Execute(format("cmd /C {smoke_cmd} {service}"), user=params.hcat_user, logoutput=True)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/templates/webhcat-env.sh.j2
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/templates/webhcat-env.sh.j2 b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/templates/webhcat-env.sh.j2
new file mode 100644
index 0000000..220f420
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HIVE/package/templates/webhcat-env.sh.j2
@@ -0,0 +1,62 @@
+{#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#}
+
+#
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#
+#
+
+# The file containing the running pid
+PID_FILE={{pid_file}}
+
+TEMPLETON_LOG_DIR={{templeton_log_dir}}/
+
+
+WEBHCAT_LOG_DIR={{templeton_log_dir}}/
+
+# The console error log
+ERROR_LOG={{templeton_log_dir}}/webhcat-console-error.log
+
+# The console log
+CONSOLE_LOG={{templeton_log_dir}}/webhcat-console.log
+
+#TEMPLETON_JAR=templeton_jar_name
+
+#HADOOP_PREFIX=hadoop_prefix
+
+#HCAT_PREFIX=hive_prefix
+
+# Set HADOOP_HOME to point to a specific hadoop install directory
+export HADOOP_HOME=/usr/lib/hadoop
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/configuration/webhcat-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/configuration/webhcat-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/configuration/webhcat-site.xml
deleted file mode 100644
index bae9712..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/configuration/webhcat-site.xml
+++ /dev/null
@@ -1,109 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
-http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
--->
-
-<!-- The default settings for Templeton. -->
-<!-- Edit templeton-site.xml to change settings for your local -->
-<!-- install. -->
-
-<configuration>
-
- <property>
- <name>templeton.port</name>
- <value>50111</value>
- <description>The HTTP port for the main server.</description>
- </property>
-
- <property>
- <name>templeton.jar</name>
- <value>c:\hdp\hive\hcatalog\share\webhcat\svr\lib\hive-webhca.jar</value>
- <description>The path to the Templeton jar file.</description>
- </property>
-
- <property>
- <name>templeton.override.enabled</name>
- <value>false</value>
- <description>
- Enable the override path in templeton.override.jars
- </description>
- </property>
-
- <property>
- <name>templeton.hcat</name>
- <value>${env.HCAT_HOME}/bin/hcat.py</value>
- <description>The path to the hcatalog executable.</description>
- </property>
-
- <property>
- <name>templeton.hadoop</name>
- <value>${env.HADOOP_HOME}/bin/hadoop.cmd</value>
- <description>The path to the Hadoop executable.</description>
- </property>
-
- <property>
- <name>templeton.exec.envs</name>
- <value>HADOOP_HOME,JAVA_HOME,HIVE_HOME,TEMP,HADOOP_BIN_PATH,PATH,SystemRoot,TEZ_CLASSPATH</value>
- <description>The environment variables passed through to exec.</description>
- </property>
-
- <property>
- <name>templeton.streaming.jar</name>
- <value>file:///c:/hdp/hadoop/share/hadoop/tools/lib/hadoop-streaming.jar</value>
- <description>The hdfs path to the Hadoop streaming jar file.</description>
- </property>
-
- <property>
- <name>templeton.hive.properties</name>
- <value>hive.metastore.local=false,hive.metastore.uris=thrift://WIN-QS1HDPKHRAM:9083</value>
- <description>Properties to set when running hive.</description>
- </property>
-
- <property>
- <name>templeton.libjars</name>
- <value>file:///c:/hdp/hive/lib/zookeeper.jar</value>
- <description>Jars to add to the classpath.</description>
- </property>
-
- <property>
- <name>templeton.pig.path</name>
- <value>${env.PIG_HOME}/bin/pig.cmd</value>
- <description>The path to the Pig executable.</description>
- </property>
-
- <property>
- <name>templeton.hive.path</name>
- <value>${env.HIVE_HOME}/bin/hive.cmd</value>
- <description>The path to the Hive executable.</description>
- </property>
-
-
- <property>
- <name>templeton.hadoop.queue.name</name>
- <value>joblauncher</value>
- </property>
-
- <property>
- <name>templeton.zookeeper.hosts</name>
- <value>localhost:2181</value>
- </property>
-
- <property>
- <name>templeton.storage.class</name>
- <value>org.apache.hive.hcatalog.templeton.tool.ZooKeeperStorage</value>
- </property>
-</configuration>
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/metainfo.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/metainfo.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/metainfo.xml
deleted file mode 100644
index 390dc9a..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/metainfo.xml
+++ /dev/null
@@ -1,85 +0,0 @@
-<?xml version="1.0"?>
-<!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version 2.0
- (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<metainfo>
- <schemaVersion>2.0</schemaVersion>
- <services>
- <service>
- <name>WEBHCAT</name>
- <comment>This is comment for WEBHCAT service</comment>
- <version>0.12.0.2.0</version>
- <components>
- <component>
- <name>WEBHCAT_SERVER</name>
- <category>MASTER</category>
- <cardinality>1</cardinality>
- <dependencies>
- <dependency>
- <name>HDFS/HDFS_CLIENT</name>
- <scope>host</scope>
- <auto-deploy>
- <enabled>true</enabled>
- </auto-deploy>
- </dependency>
- <dependency>
- <name>MAPREDUCE2/MAPREDUCE2_CLIENT</name>
- <scope>host</scope>
- <auto-deploy>
- <enabled>true</enabled>
- </auto-deploy>
- </dependency>
- <dependency>
- <name>ZOOKEEPER/ZOOKEEPER_SERVER</name>
- <scope>cluster</scope>
- <auto-deploy>
- <enabled>true</enabled>
- <co-locate>WEBHCAT/WEBHCAT_SERVER</co-locate>
- </auto-deploy>
- </dependency>
- <dependency>
- <name>ZOOKEEPER/ZOOKEEPER_CLIENT</name>
- <scope>host</scope>
- <auto-deploy>
- <enabled>true</enabled>
- </auto-deploy>
- </dependency>
- <dependency>
- <name>YARN/YARN_CLIENT</name>
- <scope>host</scope>
- <auto-deploy>
- <enabled>true</enabled>
- </auto-deploy>
- </dependency>
- </dependencies>
- <commandScript>
- <script>scripts/webhcat_server.py</script>
- <scriptType>PYTHON</scriptType>
- <timeout>1200</timeout>
- </commandScript>
- </component>
- </components>
- <commandScript>
- <script>scripts/service_check.py</script>
- <scriptType>PYTHON</scriptType>
- <timeout>1200</timeout>
- </commandScript>
- <configuration-dependencies>
- <config-type>webhcat-site</config-type>
- </configuration-dependencies>
- </service>
- </services>
-</metainfo>
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/files/templetonSmoke.sh
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/files/templetonSmoke.sh b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/files/templetonSmoke.sh
deleted file mode 100644
index 2d07b8b..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/files/templetonSmoke.sh
+++ /dev/null
@@ -1,96 +0,0 @@
-#!/usr/bin/env bash
-#
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-#
-
-export ttonhost=$1
-export smoke_test_user=$2
-export smoke_user_keytab=$3
-export security_enabled=$4
-export kinit_path_local=$5
-export ttonurl="http://${ttonhost}:50111/templeton/v1"
-
-if [[ $security_enabled == "true" ]]; then
- kinitcmd="${kinit_path_local} -kt ${smoke_user_keytab} ${smoke_test_user}; "
-else
- kinitcmd=""
-fi
-
-export no_proxy=$ttonhost
-cmd="${kinitcmd}curl --negotiate -u : -s -w 'http_code <%{http_code}>' $ttonurl/status 2>&1"
-retVal=`su - ${smoke_test_user} -c "$cmd"`
-httpExitCode=`echo $retVal |sed 's/.*http_code <\([0-9]*\)>.*/\1/'`
-
-if [[ "$httpExitCode" -ne "200" ]] ; then
- echo "Templeton Smoke Test (status cmd): Failed. : $retVal"
- export TEMPLETON_EXIT_CODE=1
- exit 1
-fi
-
-exit 0
-
-#try hcat ddl command
-echo "user.name=${smoke_test_user}&exec=show databases;" /tmp/show_db.post.txt
-cmd="${kinitcmd}curl --negotiate -u : -s -w 'http_code <%{http_code}>' -d \@${destdir}/show_db.post.txt $ttonurl/ddl 2>&1"
-retVal=`su - ${smoke_test_user} -c "$cmd"`
-httpExitCode=`echo $retVal |sed 's/.*http_code <\([0-9]*\)>.*/\1/'`
-
-if [[ "$httpExitCode" -ne "200" ]] ; then
- echo "Templeton Smoke Test (ddl cmd): Failed. : $retVal"
- export TEMPLETON_EXIT_CODE=1
- exit 1
-fi
-
-# NOT SURE?? SUHAS
-if [[ $security_enabled == "true" ]]; then
- echo "Templeton Pig Smoke Tests not run in secure mode"
- exit 0
-fi
-
-#try pig query
-outname=${smoke_test_user}.`date +"%M%d%y"`.$$;
-ttonTestOutput="/tmp/idtest.${outname}.out";
-ttonTestInput="/tmp/idtest.${outname}.in";
-ttonTestScript="idtest.${outname}.pig"
-
-echo "A = load '$ttonTestInput' using PigStorage(':');" > /tmp/$ttonTestScript
-echo "B = foreach A generate \$0 as id; " >> /tmp/$ttonTestScript
-echo "store B into '$ttonTestOutput';" >> /tmp/$ttonTestScript
-
-#copy pig script to hdfs
-su - ${smoke_test_user} -c "hadoop dfs -copyFromLocal /tmp/$ttonTestScript /tmp/$ttonTestScript"
-
-#copy input file to hdfs
-su - ${smoke_test_user} -c "hadoop dfs -copyFromLocal /etc/passwd $ttonTestInput"
-
-#create, copy post args file
-echo -n "user.name=${smoke_test_user}&file=/tmp/$ttonTestScript" > /tmp/pig_post.txt
-
-#submit pig query
-cmd="curl -s -w 'http_code <%{http_code}>' -d \@${destdir}/pig_post.txt $ttonurl/pig 2>&1"
-retVal=`su - ${smoke_test_user} -c "$cmd"`
-httpExitCode=`echo $retVal |sed 's/.*http_code <\([0-9]*\)>.*/\1/'`
-if [[ "$httpExitCode" -ne "200" ]] ; then
- echo "Templeton Smoke Test (pig cmd): Failed. : $retVal"
- export TEMPLETON_EXIT_CODE=1
- exit 1
-fi
-
-exit 0
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/params.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/params.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/params.py
deleted file mode 100644
index 607d05d..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/params.py
+++ /dev/null
@@ -1,29 +0,0 @@
-"""
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Ambari Agent
-
-"""
-
-from resource_management import *
-import os
-
-# server configurations
-config = Script.get_config()
-hcat_user = "hadoop"
-hdp_root = os.path.abspath(os.path.join(os.environ["HADOOP_HOME"],".."))
-config_dir = os.environ["WEBHCAT_CONF_DIR"]
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_check.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_check.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_check.py
deleted file mode 100644
index 804c8b2..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_check.py
+++ /dev/null
@@ -1,32 +0,0 @@
-"""
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Ambari Agent
-
-"""
-from resource_management import *
-
-class WebHCatServiceCheck(Script):
- def service_check(self, env):
- import params
- env.set_params(params)
- smoke_cmd = os.path.join(params.hdp_root,"Run-SmokeTests.cmd")
- service = "WEBHCAT"
- Execute(format("cmd /C {smoke_cmd} {service}"), user=params.hcat_user, logoutput=True)
-
-if __name__ == "__main__":
- WebHCatServiceCheck().execute()
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_mapping.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_mapping.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_mapping.py
deleted file mode 100644
index 172886c..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/service_mapping.py
+++ /dev/null
@@ -1,20 +0,0 @@
-"""
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-"""
-
-webhcat_server_win_service_name = "templeton"
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat.py
deleted file mode 100644
index 032ca79..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat.py
+++ /dev/null
@@ -1,30 +0,0 @@
-"""
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Ambari Agent
-
-"""
-from resource_management import *
-import sys
-
-
-def webhcat():
- import params
- XmlConfig("webhcat-site.xml",
- conf_dir=params.config_dir,
- configurations=params.config['configurations']['webhcat-site']
- )
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat_server.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat_server.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat_server.py
deleted file mode 100644
index 527efb8..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/scripts/webhcat_server.py
+++ /dev/null
@@ -1,48 +0,0 @@
-"""
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-Ambari Agent
-
-"""
-import sys
-from resource_management import *
-from webhcat import webhcat
-import service_mapping
-
-class WebHCatServer(Script):
- def install(self, env):
- if not check_windows_service_exists(service_mapping.webhcat_server_win_service_name):
- self.install_packages(env)
-
- def configure(self, env):
- import params
- env.set_params(params)
- webhcat()
-
- def start(self, env):
- import params
- self.configure(env) # FOR SECURITY
- Service(service_mapping.webhcat_server_win_service_name, action="start")
-
- def stop(self, env):
- Service(service_mapping.webhcat_server_win_service_name, action="stop")
-
- def status(self, env):
- check_windows_service_status(service_mapping.webhcat_server_win_service_name)
-
-if __name__ == "__main__":
- WebHCatServer().execute()
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/templates/webhcat-env.sh.j2
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/templates/webhcat-env.sh.j2 b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/templates/webhcat-env.sh.j2
deleted file mode 100644
index 220f420..0000000
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/WEBHCAT/package/templates/webhcat-env.sh.j2
+++ /dev/null
@@ -1,62 +0,0 @@
-{#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#}
-
-#
-#
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-#
-#
-#
-
-# The file containing the running pid
-PID_FILE={{pid_file}}
-
-TEMPLETON_LOG_DIR={{templeton_log_dir}}/
-
-
-WEBHCAT_LOG_DIR={{templeton_log_dir}}/
-
-# The console error log
-ERROR_LOG={{templeton_log_dir}}/webhcat-console-error.log
-
-# The console log
-CONSOLE_LOG={{templeton_log_dir}}/webhcat-console.log
-
-#TEMPLETON_JAR=templeton_jar_name
-
-#HADOOP_PREFIX=hadoop_prefix
-
-#HCAT_PREFIX=hive_prefix
-
-# Set HADOOP_HOME to point to a specific hadoop install directory
-export HADOOP_HOME=/usr/lib/hadoop
http://git-wip-us.apache.org/repos/asf/ambari/blob/892ebe4f/ambari-web/app/controllers/wizard/step5_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/wizard/step5_controller.js b/ambari-web/app/controllers/wizard/step5_controller.js
index 6fb9ab1..13c6896 100644
--- a/ambari-web/app/controllers/wizard/step5_controller.js
+++ b/ambari-web/app/controllers/wizard/step5_controller.js
@@ -607,12 +607,12 @@ App.WizardStep5Controller = Em.Controller.extend(App.BlueprintMixin, {
multipleComponentHasBeenAdded[component.name] = true;
savedComponents.forEach(function(saved) {
- resultComponents.push(self.createComponentInstallationObject(fullComponent, host.fqdn, saved));
+ resultComponents.push(self.createComponentInstallationObject(fullComponent, host.fqdn.toLowerCase(), saved));
});
}
} else {
var savedComponent = masterHosts.findProperty('component', component.name);
- resultComponents.push(self.createComponentInstallationObject(fullComponent, host.fqdn, savedComponent));
+ resultComponents.push(self.createComponentInstallationObject(fullComponent, host.fqdn.toLowerCase(), savedComponent));
}
}
}
[3/3] git commit: AMBARI-7958 - Move MetricsSink properties and
Hadoop username/password properties from hadoop-env.xml to cluster-env.xml
Posted by ab...@apache.org.
AMBARI-7958 - Move MetricsSink properties and Hadoop username/password properties from hadoop-env.xml to cluster-env.xml
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/28e15774
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/28e15774
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/28e15774
Branch: refs/heads/branch-windows-dev
Commit: 28e1577470867da5cd2de15d11e546729aa93640
Parents: 95a13e0
Author: Artem Baranchuk <ab...@hortonworks.com>
Authored: Fri Oct 24 21:35:19 2014 +0300
Committer: Artem Baranchuk <ab...@hortonworks.com>
Committed: Fri Oct 24 21:40:11 2014 +0300
----------------------------------------------------------------------
.../libraries/script/script.py | 2 +-
.../libraries/script/script.py.orig | 2 +-
.../HDPWIN/2.1/configuration/cluster-env.xml | 111 +++++++++++++++++++
.../services/HDFS/configuration/hadoop-env.xml | 52 ---------
.../2.1/services/HDFS/package/scripts/params.py | 8 +-
ambari-web/app/data/HDP2/site_properties.js | 4 +-
6 files changed, 119 insertions(+), 60 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/28e15774/ambari-common/src/main/python/resource_management/libraries/script/script.py
----------------------------------------------------------------------
diff --git a/ambari-common/src/main/python/resource_management/libraries/script/script.py b/ambari-common/src/main/python/resource_management/libraries/script/script.py
index d3aa7df..c7e6121 100644
--- a/ambari-common/src/main/python/resource_management/libraries/script/script.py
+++ b/ambari-common/src/main/python/resource_management/libraries/script/script.py
@@ -49,7 +49,7 @@ USAGE = """Usage: {0} <COMMAND> <JSON_CONFIG> <BASEDIR> <STROUTPUT> <LOGGING_LEV
<TMP_DIR> temporary directory for executable scripts. Ex: /var/lib/ambari-agent/data/tmp
"""
-_PASSWORD_MAP = {"/configurations/hadoop-env/hadoop.user.name":"/configurations/hadoop-env/hadoop.user.password"}
+_PASSWORD_MAP = {"/configurations/cluster-env/hadoop.user.name":"/configurations/cluster-env/hadoop.user.password"}
def get_path_form_configuration(name, configuration):
subdicts = filter(None, name.split('/'))
http://git-wip-us.apache.org/repos/asf/ambari/blob/28e15774/ambari-common/src/main/python/resource_management/libraries/script/script.py.orig
----------------------------------------------------------------------
diff --git a/ambari-common/src/main/python/resource_management/libraries/script/script.py.orig b/ambari-common/src/main/python/resource_management/libraries/script/script.py.orig
index ba6775e..82860c5 100644
--- a/ambari-common/src/main/python/resource_management/libraries/script/script.py.orig
+++ b/ambari-common/src/main/python/resource_management/libraries/script/script.py.orig
@@ -42,7 +42,7 @@ USAGE = """Usage: {0} <COMMAND> <JSON_CONFIG> <BASEDIR> <STROUTPUT> <LOGGING_LEV
<LOGGING_LEVEL> log level for stdout. Ex:DEBUG,INFO
"""
-_PASSWORD_MAP = {"/configurations/hadoop-env/hadoop.user.name":"/configurations/hadoop-env/hadoop.user.password"}
+_PASSWORD_MAP = {"/configurations/cluster-env/hadoop.user.name":"/configurations/cluster-env/hadoop.user.password"}
def get_path_form_configuration(name, configuration):
subdicts = filter(None, name.split('/'))
http://git-wip-us.apache.org/repos/asf/ambari/blob/28e15774/ambari-server/src/main/resources/stacks/HDPWIN/2.1/configuration/cluster-env.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/configuration/cluster-env.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/configuration/cluster-env.xml
new file mode 100644
index 0000000..de38931
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/configuration/cluster-env.xml
@@ -0,0 +1,111 @@
+<?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
+<!--
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+
+<configuration>
+ <!-- metrics sink properties -->
+ <property>
+ <name>sink_database</name>
+ <value>Existing MSSQL Server database with sql auth</value>
+ </property>
+
+ <property>
+ <name>sink.dbservername</name>
+ <value/>
+ </property>
+
+ <property>
+ <name>sink.dblogin</name>
+ <value>hadoop</value>
+ <description>
+ DB user name.
+ </description>
+ </property>
+
+ <property>
+ <name>sink.dbpassword</name>
+ <value/>
+ <description>
+ DB password.
+ </description>
+ </property>
+
+ <property>
+ <name>sink.db.schema.name</name>
+ <value>HadoopMetrics</value>
+ </property>
+
+ <property>
+ <name>sink.jdbc.driver</name>
+ <value>com.microsoft.sqlserver.jdbc.SQLServerDriver</value>
+ <description>
+ JDBC driver class.
+ </description>
+ </property>
+
+ <property>
+ <name>sink.jdbc.url</name>
+ <value/>
+ <description>
+ JDBC URL.
+ </description>
+ </property>
+
+ <property>
+ <name>hadoop.user.name</name>
+ <value>hadoop</value>
+ </property>
+
+
+
+ <property>
+ <name>security_enabled</name>
+ <value>false</value>
+ <description>Hadoop Security</description>
+ </property>
+ <property>
+ <name>kerberos_domain</name>
+ <value>EXAMPLE.COM</value>
+ <description>Kerberos realm.</description>
+ </property>
+ <property>
+ <name>ignore_groupsusers_create</name>
+ <value>false</value>
+ <description>Whether to ignore failures on users and group creation</description>
+ </property>
+ <property>
+ <name>smokeuser</name>
+ <value>ambari-qa</value>
+ <property-type>USER</property-type>
+ <description>User executing service checks</description>
+ </property>
+ <property>
+ <name>smokeuser_keytab</name>
+ <value>/etc/security/keytabs/smokeuser.headless.keytab</value>
+ <description>Path to smoke test user keytab file</description>
+ </property>
+ <property>
+ <name>user_group</name>
+ <value>hadoop</value>
+ <property-type>GROUP</property-type>
+ <description>Hadoop user group.</description>
+ </property>
+</configuration>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/ambari/blob/28e15774/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
index 2380408..484235d 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
@@ -25,58 +25,6 @@
<!-- Put site-specific property overrides in this file. -->
<configuration>
- <!-- metrics sink properties -->
- <property>
- <name>sink_database</name>
- <value>Existing MSSQL Server database with sql auth</value>
- </property>
-
- <property>
- <name>sink.dbservername</name>
- <value></value>
- </property>
-
- <property>
- <name>sink.dblogin</name>
- <value>hadoop</value>
- <description>
- DB user name.
- </description>
- </property>
-
- <property>
- <name>sink.dbpassword</name>
- <value></value>
- <description>
- DB password.
- </description>
- </property>
-
- <property>
- <name>sink.db.schema.name</name>
- <value>HadoopMetrics</value>
- </property>
-
- <property>
- <name>sink.jdbc.driver</name>
- <value>com.microsoft.sqlserver.jdbc.SQLServerDriver</value>
- <description>
- JDBC driver class.
- </description>
- </property>
-
- <property>
- <name>sink.jdbc.url</name>
- <value></value>
- <description>
- JDBC URL.
- </description>
- </property>
-
- <property>
- <name>hadoop.user.name</name>
- <value>hadoop</value>
- </property>
<property>
<name>dfs.datanode.data.dir.mount.file</name>
http://git-wip-us.apache.org/repos/asf/ambari/blob/28e15774/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/package/scripts/params.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/package/scripts/params.py b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/package/scripts/params.py
index d3c6c4b..cd57f5f 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/package/scripts/params.py
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/package/scripts/params.py
@@ -50,10 +50,10 @@ if dfs_ha_enabled:
if hostname in nn_host:
namenode_id = nn_id
namenode_rpc = nn_host
-dbserver = config['configurations']['hadoop-env']['sink.dbservername'].replace('\\', '\\\\')
-dblogin = config['configurations']['hadoop-env']['sink.dblogin']
-dbpassword = config['configurations']['hadoop-env']['sink.dbpassword']
-dburl = config['configurations']['hadoop-env']['sink.jdbc.url'].replace('\\', '\\\\')
+dbserver = config['configurations']['cluster-env']['sink.dbservername'].replace('\\', '\\\\')
+dblogin = config['configurations']['cluster-env']['sink.dblogin']
+dbpassword = config['configurations']['cluster-env']['sink.dbpassword']
+dburl = config['configurations']['cluster-env']['sink.jdbc.url'].replace('\\', '\\\\')
if 'integratedSecurity=true' not in dburl:
dburl = dburl + ';user=' + dblogin + ';password=' + dbpassword;
http://git-wip-us.apache.org/repos/asf/ambari/blob/28e15774/ambari-web/app/data/HDP2/site_properties.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/data/HDP2/site_properties.js b/ambari-web/app/data/HDP2/site_properties.js
index 7800725..7485c5a 100644
--- a/ambari-web/app/data/HDP2/site_properties.js
+++ b/ambari-web/app/data/HDP2/site_properties.js
@@ -55,7 +55,7 @@ module.exports =
"isOverridable": false,
"isVisible": App.get('isHadoopWindowsStack'),
"serviceName": "MISC",
- "filename": "hadoop-env.xml",
+ "filename": "cluster-env.xml",
"category": "Users and Groups",
"belongsToService": ["HDFS"],
"index": 0
@@ -70,7 +70,7 @@ module.exports =
"isOverridable": false,
"isVisible": App.get('isHadoopWindowsStack'),
"serviceName": "MISC",
- "filename": "hadoop-env.xml",
+ "filename": "cluster-env.xml",
"category": "Users and Groups",
"belongsToService": ["HDFS"],
"index": 1
[2/3] git commit: AMBARI-7948 - Add new configs to HDPWIN 2.1 stack
and new configuration flags(Eugene Chekanskiy via abaranchuk)
Posted by ab...@apache.org.
AMBARI-7948 - Add new configs to HDPWIN 2.1 stack and new configuration flags(Eugene Chekanskiy via abaranchuk)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/95a13e03
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/95a13e03
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/95a13e03
Branch: refs/heads/branch-windows-dev
Commit: 95a13e03307e7ee4d20fd3bc9ed3343070891b8b
Parents: 892ebe4
Author: Artem Baranchuk <ab...@hortonworks.com>
Authored: Fri Oct 24 18:04:32 2014 +0300
Committer: Artem Baranchuk <ab...@hortonworks.com>
Committed: Fri Oct 24 18:06:43 2014 +0300
----------------------------------------------------------------------
.../services/HBASE/configuration/hbase-env.xml | 34 ++++++++++++++++++++
.../HBASE/configuration/hbase-policy.xml | 2 +-
.../services/HDFS/configuration/core-site.xml | 2 +-
.../services/HDFS/configuration/hadoop-env.xml | 6 ++++
.../HDFS/configuration/hadoop-policy.xml | 2 +-
.../services/HDFS/configuration/hdfs-site.xml | 2 +-
.../services/OOZIE/configuration/oozie-site.xml | 2 +-
.../YARN/configuration/capacity-scheduler.xml | 2 +-
.../services/YARN/configuration/yarn-site.xml | 28 +++++++++++++++-
9 files changed, 73 insertions(+), 7 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-env.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-env.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-env.xml
new file mode 100644
index 0000000..81ddd04
--- /dev/null
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-env.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0"?>
+<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
+<!--
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+-->
+
+<configuration>
+ <property>
+ <name>hbase_regionserver_xmn_max</name>
+ <value>512</value>
+ <description>HBase RegionServer maximum value for minimum heap size.</description>
+ </property>
+ <property>
+ <name>hbase_regionserver_xmn_ratio</name>
+ <value>0.2</value>
+ <description>HBase RegionServer minimum heap size is calculated as a percentage of max heap size.</description>
+ </property>
+</configuration>
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-policy.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-policy.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-policy.xml
index a49fb97..b0807b6 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-policy.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HBASE/configuration/hbase-policy.xml
@@ -20,7 +20,7 @@
*/
-->
-<configuration>
+<configuration supports_final="true">
<property>
<name>security.client.protocol.acl</name>
<value>*</value>
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/core-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/core-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/core-site.xml
index 29b78cc..2dbda14 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/core-site.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/core-site.xml
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<!-- Put site-specific property overrides in this file. -->
-<configuration xmlns:xi="http://www.w3.org/2001/XInclude">
+<configuration supports_final="true" xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- i/o properties -->
<property>
<name>io.file.buffer.size</name>
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
index 416c46b..2380408 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-env.xml
@@ -78,4 +78,10 @@
<value>hadoop</value>
</property>
+ <property>
+ <name>dfs.datanode.data.dir.mount.file</name>
+ <value>c:\hadoop\hdfs\dfs_data_dir_mount.hist</value>
+ <description>File path that contains the last known mount point for each data dir. This file is used to avoid creating a DFS data dir on the root drive (and filling it up) if a path was previously mounted on a drive.</description>
+ </property>
+
</configuration>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-policy.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-policy.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-policy.xml
index cc83bc5..1549b41 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-policy.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hadoop-policy.xml
@@ -24,7 +24,7 @@
<!-- Put site-specific property overrides in this file. -->
-<configuration>
+<configuration supports_final="true">
<property>
<name>security.client.protocol.acl</name>
<value>*</value>
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hdfs-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hdfs-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hdfs-site.xml
index 20231a9..f267e51 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hdfs-site.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/HDFS/configuration/hdfs-site.xml
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<!-- Put site-specific property overrides in this file. -->
-<configuration>
+<configuration supports_final="true">
<!-- file system properties -->
<property>
<name>dfs.namenode.name.dir</name>
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/OOZIE/configuration/oozie-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/OOZIE/configuration/oozie-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/OOZIE/configuration/oozie-site.xml
index 8df99c4..2051d01 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/OOZIE/configuration/oozie-site.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/OOZIE/configuration/oozie-site.xml
@@ -16,7 +16,7 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<configuration>
+<configuration supports_final="true">
<!--
Refer to the oozie-default.xml file for the complete list of
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/capacity-scheduler.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/capacity-scheduler.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/capacity-scheduler.xml
index cbe9f4f..c2be95b 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/capacity-scheduler.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/capacity-scheduler.xml
@@ -11,7 +11,7 @@
See the License for the specific language governing permissions and
limitations under the License. See accompanying LICENSE file.
-->
-<configuration>
+<configuration supports_final="false" supports_adding_forbidden="true">
<property>
<name>yarn.scheduler.capacity.maximum-applications</name>
<value>10000</value>
http://git-wip-us.apache.org/repos/asf/ambari/blob/95a13e03/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/yarn-site.xml
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/yarn-site.xml b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/yarn-site.xml
index 6b82601..7aecf01 100644
--- a/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/yarn-site.xml
+++ b/ambari-server/src/main/resources/stacks/HDPWIN/2.1/services/YARN/configuration/yarn-site.xml
@@ -1,7 +1,33 @@
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<!-- Put site-specific property overrides in this file. -->
-<configuration xmlns:xi="http://www.w3.org/2001/XInclude">
+<configuration supports_final="true" xmlns:xi="http://www.w3.org/2001/XInclude">
+ <property>
+ <name>yarn.nodemanager.resource.memory-mb</name>
+ <value>5120</value>
+ <description>Amount of physical memory, in MB, that can be allocated
+ for containers.</description>
+ </property>
+
+ <property>
+ <name>yarn.scheduler.minimum-allocation-mb</name>
+ <value>512</value>
+ <description>
+ The minimum allocation for every container request at the RM,
+ in MBs. Memory requests lower than this won't take effect,
+ and the specified value will get allocated at minimum.
+ </description>
+ </property>
+
+ <property>
+ <name>yarn.scheduler.maximum-allocation-mb</name>
+ <value>2048</value>
+ <description>
+ The maximum allocation for every container request at the RM,
+ in MBs. Memory requests higher than this won't take effect,
+ and will get capped to this value.
+ </description>
+ </property>
<property>
<name>yarn.nodemanager.pmem-check-enabled</name>
<value>true</value>