hadoop-mapreduce-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acmur...@apache.org
Subject svn commit: r1184976 - in /hadoop/common/branches/branch-0.23/hadoop-mapreduce-project: CHANGES.txt hadoop-yarn/bin/yarn
Date Mon, 17 Oct 2011 02:14:55 GMT
Author: acmurthy
Date: Mon Oct 17 02:14:55 2011
New Revision: 1184976

URL: http://svn.apache.org/viewvc?rev=1184976&view=rev
Log:
Merge -c 1184975 from trunk to branch-0.23 to fix MAPREDUCE-3190.

Modified:
    hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/CHANGES.txt
    hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/hadoop-yarn/bin/yarn

Modified: hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/CHANGES.txt?rev=1184976&r1=1184975&r2=1184976&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/CHANGES.txt (original)
+++ hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/CHANGES.txt Mon Oct 17 02:14:55
2011
@@ -1586,6 +1586,10 @@ Release 0.23.0 - Unreleased
     MAPREDUCE-2840. mr279 TestUberAM.testSleepJob test fails. (jonathan eagles
     via mahadev)
 
+    MAPREDUCE-3190. Ensure bin/yarn fails early with a clear error message
+    when HADOOP_COMMON_HOME or HADOOP_HDFS_HOME are not set. (todd & acmurthy 
+    via acmurthy)
+
 Release 0.22.0 - Unreleased
 
   INCOMPATIBLE CHANGES

Modified: hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/hadoop-yarn/bin/yarn
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/hadoop-yarn/bin/yarn?rev=1184976&r1=1184975&r2=1184976&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/hadoop-yarn/bin/yarn (original)
+++ hadoop/common/branches/branch-0.23/hadoop-mapreduce-project/hadoop-yarn/bin/yarn Mon Oct
17 02:14:55 2011
@@ -24,12 +24,6 @@
 #
 #   YARN_CLASSPATH Extra Java CLASSPATH entries.
 #
-#   YARN_USER_CLASSPATH_FIRST      When defined, the YARN_CLASSPATH is 
-#                                    added in the beginning of the global
-#                                    classpath. Can be defined, for example,
-#                                    by doing 
-#                                    export YARN_USER_CLASSPATH_FIRST=true
-#
 #   YARN_HEAPSIZE  The maximum amount of heap to use, in MB. 
 #                    Default is 1000.
 #
@@ -107,10 +101,14 @@ if [ "$YARN_HEAPSIZE" != "" ]; then
 fi
 
 # CLASSPATH initially contains $HADOOP_CONF_DIR & $YARN_CONF_DIR
-CLASSPATH="${HADOOP_CONF_DIR}:${YARN_CONF_DIR}"
-if [ "$YARN_USER_CLASSPATH_FIRST" != "" ] && [ "$YARN_CLASSPATH" != "" ] ; then
-  CLASSPATH=${CLASSPATH}:${YARN_CLASSPATH}
+if [ ! -d "$HADOOP_CONF_DIR" ]; then
+  echo No HADOOP_CONF_DIR set. 
+  echo Please specify it either in yarn-env.sh or in the environment.
+  exit 1
 fi
+
+CLASSPATH="${HADOOP_CONF_DIR}:${YARN_CONF_DIR}"
+CLASSPATH=${CLASSPATH}:${YARN_CLASSPATH}
 CLASSPATH=${CLASSPATH}:$JAVA_HOME/lib/tools.jar
 
 # for developers, add Hadoop classes to CLASSPATH
@@ -147,12 +145,21 @@ fi
 IFS=
 
 # add hadoop-common libs to CLASSPATH
+if [ ! -d "$HADOOP_COMMON_HOME" ]; then
+  echo No HADOOP_COMMON_HOME set. 
+  echo Please specify it either in yarn-env.sh or in the environment.
+  exit 1
+fi
 
 CLASSPATH=${CLASSPATH}:$HADOOP_COMMON_HOME/share/hadoop/common'/*'
 CLASSPATH=${CLASSPATH}:$HADOOP_COMMON_HOME/share/hadoop/common/lib'/*'
 
 # add hadoop-hdfs libs to CLASSPATH
-
+if [ ! -d "$HADOOP_HDFS_HOME" ]; then
+  echo No HADOOP_HDFS_HOME set. 
+  echo Please specify it either in yarn-env.sh or in the environment.
+  exit 1
+fi
 CLASSPATH=${CLASSPATH}:$HADOOP_HDFS_HOME/share/hadoop/hdfs'/*'
 CLASSPATH=${CLASSPATH}:$HADOOP_HDFS_HOME/share/hadoop/hdfs/lib'/*'
 



Mime
View raw message