You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hawq.apache.org by li...@apache.org on 2017/03/28 06:33:44 UTC
incubator-hawq git commit: Revert "HAWQ-1415. Set the default_value
of JAVA_HOME for running RPS"
Repository: incubator-hawq
Updated Branches:
refs/heads/master 22306b09a -> c2ba42026
Revert "HAWQ-1415. Set the default_value of JAVA_HOME for running RPS"
This reverts commit a803aab4eec4a71e83d2bd18bb72b93ba4be31a2.
Project: http://git-wip-us.apache.org/repos/asf/incubator-hawq/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-hawq/commit/c2ba4202
Tree: http://git-wip-us.apache.org/repos/asf/incubator-hawq/tree/c2ba4202
Diff: http://git-wip-us.apache.org/repos/asf/incubator-hawq/diff/c2ba4202
Branch: refs/heads/master
Commit: c2ba42026d4d462540e50c400f025d32c1ce735f
Parents: 22306b0
Author: Lili Ma <ic...@gmail.com>
Authored: Tue Mar 28 14:30:35 2017 +0800
Committer: Lili Ma <ic...@gmail.com>
Committed: Tue Mar 28 14:34:25 2017 +0800
----------------------------------------------------------------------
ranger-plugin/conf/rps.properties | 3 ---
ranger-plugin/scripts/enable-ranger-plugin.sh | 21 +--------------------
ranger-plugin/scripts/rps.sh | 1 -
3 files changed, 1 insertion(+), 24 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/c2ba4202/ranger-plugin/conf/rps.properties
----------------------------------------------------------------------
diff --git a/ranger-plugin/conf/rps.properties b/ranger-plugin/conf/rps.properties
index 7565885..81a6986 100644
--- a/ranger-plugin/conf/rps.properties
+++ b/ranger-plugin/conf/rps.properties
@@ -36,6 +36,3 @@ RPS_HEAP_SIZE=128m
# use CATALINA_HOME in default and use /usr/lib/bigtop-tomcat if CATALINA_HOME not set
CATALINA_HOME=${CATALINA_HOME:-/usr/lib/bigtop-tomcat}
-
-# use JAVA_HOME in default and use /usr/java/default if JAVA_HOME not set
-JAVA_HOME=${JAVA_HOME:-/usr/java/default}
http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/c2ba4202/ranger-plugin/scripts/enable-ranger-plugin.sh
----------------------------------------------------------------------
diff --git a/ranger-plugin/scripts/enable-ranger-plugin.sh b/ranger-plugin/scripts/enable-ranger-plugin.sh
index febaf81..05a0b1d 100755
--- a/ranger-plugin/scripts/enable-ranger-plugin.sh
+++ b/ranger-plugin/scripts/enable-ranger-plugin.sh
@@ -150,7 +150,7 @@ function validate_params() {
get_hawq_password
echo "RANGER URL = ${RANGER_URL}"
echo "RANGER User = ${RANGER_USER}"
- echo "RANGER Password = $(mask ${RANGER_PASSWORD})"
+ echo "RANGER Password = $(mask ${RANGER_PASSWORD})"
echo "HAWQ HOST = ${HAWQ_HOST}"
echo "HAWQ PORT = ${HAWQ_PORT}"
echo "HAWQ User = ${HAWQ_USER}"
@@ -211,24 +211,6 @@ function update_ranger_url() {
echo "Updated POLICY_MGR_URL to ${policy_mgr_url} in ${prop_file}"
}
-function update_java_home() {
- local java_base="/usr/jdk64"
- if [[ -d ${java_base} ]]; then
- local DIR_NAME=$(ls ${java_base} | sort -r | head -1)
-
- if [[ ${DIR_NAME} ]]; then
- JAVA_HOME_DIR="${java_base}/${DIR_NAME}"
- local prop_file=$(dirname ${SCRIPT_DIR})/etc/rps.properties
- sed -i -e "s|/usr/java/default|${JAVA_HOME_DIR}|g" ${prop_file}
- echo "Updated default value of JAVA_HOME to ${JAVA_HOME_DIR} in ${prop_file}"
- fi
- fi
-
- if [[ ! ${JAVA_HOME_DIR} && ! ${JAVA_HOME} ]]; then
- echo "Unable to locate JAVA_HOME on this machine. Please modify the default value of JAVA_HOME in ${prop_file}."
- fi
-}
-
main() {
if [[ $# -lt 1 ]]; then
usage
@@ -239,6 +221,5 @@ main() {
create_hawq_service_definition
create_hawq_service_instance
update_ranger_url
- update_java_home
}
main "$@"
http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/c2ba4202/ranger-plugin/scripts/rps.sh
----------------------------------------------------------------------
diff --git a/ranger-plugin/scripts/rps.sh b/ranger-plugin/scripts/rps.sh
index 70aa547..fa268c9 100755
--- a/ranger-plugin/scripts/rps.sh
+++ b/ranger-plugin/scripts/rps.sh
@@ -32,7 +32,6 @@ BASEDIR=$( dirname ${CWDIR} )
# read properties from the file
source ${BASEDIR}/etc/rps.properties
-export JAVA_HOME
export CATALINA_HOME
export CATALINA_BASE=${BASEDIR}/plugin-service
export CATALINA_PID=${CATALINA_BASE}/work/rps.pid