hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1177036 - in /hadoop/common/branches/branch-0.20-security: CHANGES.txt src/packages/hadoop-setup-conf.sh
Date Wed, 28 Sep 2011 20:05:17 GMT
Author: mattf
Date: Wed Sep 28 20:05:16 2011
New Revision: 1177036

URL: http://svn.apache.org/viewvc?rev=1177036&view=rev
Log:
HADOOP-7685. Resolve issues with hadoop-common file hadoop-setup-conf.sh. Contributed by Eric
Yang and Devaraj K.

Modified:
    hadoop/common/branches/branch-0.20-security/CHANGES.txt
    hadoop/common/branches/branch-0.20-security/src/packages/hadoop-setup-conf.sh

Modified: hadoop/common/branches/branch-0.20-security/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.20-security/CHANGES.txt?rev=1177036&r1=1177035&r2=1177036&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.20-security/CHANGES.txt (original)
+++ hadoop/common/branches/branch-0.20-security/CHANGES.txt Wed Sep 28 20:05:16 2011
@@ -85,6 +85,9 @@ Release 0.20.205.0 - unreleased
 
   BUG FIXES
 
+    HADOOP-7685. Resolve issues with hadoop-common file hadoop-setup-conf.sh. 
+    (Eric Yang and Devaraj K, via mattf)
+
     HADOOP-7684. jobhistory server and secondarynamenode should have init.d script
     for rpm and deb. (Eric Yang via mattf)
 

Modified: hadoop/common/branches/branch-0.20-security/src/packages/hadoop-setup-conf.sh
URL: http://svn.apache.org/viewvc/hadoop/common/branches/branch-0.20-security/src/packages/hadoop-setup-conf.sh?rev=1177036&r1=1177035&r2=1177036&view=diff
==============================================================================
--- hadoop/common/branches/branch-0.20-security/src/packages/hadoop-setup-conf.sh (original)
+++ hadoop/common/branches/branch-0.20-security/src/packages/hadoop-setup-conf.sh Wed Sep
28 20:05:16 2011
@@ -60,9 +60,11 @@ check_permission() {
   OWNER="0"
   RESULT=0
   while [ "$TARGET" != "/" ]; do
-    PARENT=`dirname $TARGET`
-    NAME=`basename $TARGET`
-    OWNER=`ls -ln $PARENT | grep $NAME| awk '{print $3}'`
+    if [ "`uname`" = "Darwin" ]; then
+      OWNER=`stat -f %u $TARGET`
+    else
+      OWNER=`stat -c %u $TARGET`
+    fi
     if [ "$OWNER" != "0" ]; then
       RESULT=1
       break
@@ -247,6 +249,7 @@ AUTOSETUP=${AUTOSETUP:-1}
 JAVA_HOME=${JAVA_HOME:-/usr/java/default}
 HADOOP_GROUP=${HADOOP_GROUP:-hadoop}
 HADOOP_NN_HOST=${HADOOP_NN_HOST:-`hostname`}
+HADOOP_SNN_HOST=${HADOOP_SNN_HOST:-`hostname`}
 HADOOP_NN_DIR=${HADOOP_NN_DIR:-/var/lib/hadoop/hdfs/namenode}
 HADOOP_DN_DIR=${HADOOP_DN_DIR:-/var/lib/hadoop/hdfs/datanode}
 HADOOP_JT_HOST=${HADOOP_JT_HOST:-`hostname`}
@@ -272,7 +275,7 @@ if [ "${SECURITY_TYPE}" = "kerberos" ]; 
   SECURITY="true"
 else
   TASK_CONTROLLER="org.apache.hadoop.mapred.DefaultTaskController"
-  HADDOP_DN_ADDR="0.0.0.0:50010"
+  HADOOP_DN_ADDR="0.0.0.0:50010"
   HADOOP_DN_HTTP_ADDR="0.0.0.0:50075"
   SECURITY="false"
 fi



Mime
View raw message