What George's suggested is more of a hack. If you want to write proper impersonation code that works despite the security toggle, follow http://hadoop.apache.org/docs/stable/Secure_Impersonation.html.
Or in your case, alternatively, create a local user "hdfs" and use that via "sudo -u hdfs" prefixes. On Wed, Mar 13, 2013 at 11:11 PM, Danfeng Li <[email protected]> wrote: > Hi, George, > > > > Thanks. It works great. > > > > For those who want more detail about it. You just need to add > > > > export HADOOP_USER_NAME=”user” > > > > in hadoop-env.sh under you hadoop conf directory. > > > > Dan > > > > From: George Datskos [mailto:[email protected]] > Sent: Tuesday, March 12, 2013 7:07 PM > To: [email protected] > Subject: Re: access hadoop cluster from ubuntu on laptop > > > > Dan, > > If you aren't using kerberos security, you can use the HADOOP_USER_NAME env > variable > > $ HADOOP_USER_NAME=hdfs hadoop fs -touchz /abc > > > George > > > > I’d like to access hadoop cluster from my laptop (through ubuntu). I put > configuration files under /etc/hadoop/cluster/conf and set up env variable > HADOOP_CONF_DIR=/etc/hadoop/cluster/conf > > > > However, my problem is that my ubuntu user name is different from my user > name on the cluster. I tried to find where I can specify my username in the > configuration files but unsuccessfully. > > > > Can anyone point me how to specify my username in the config files? > > > > Thanks. > > Dan > > -- Harsh J
