Uploading files to hadoop2.x HDFS problem statistics using the Java API in the Win7 environment

Source: Internet
Author: User

Question one:

Org.apache.hadoop.security.AccessControlException:org.apache.hadoop.security. Accesscontrolexception:permission Denied:user=administrator, Access=write, inode= "Hadoop": Hadoop:supergroup: Rwxr-xr-x

Solution:

Add Hadoop_user_name to the Local System (WIN7) environment variable or Java JVM variable, which is exactly how much to look at your situation and later run the Linux username on Hadoop. (Changes to restart Eclipse may not take effect)

Resources:

Http://www.linuxidc.com/Linux/2014-08/105335.htm

Http://www.linuxidc.com/Linux/2014-08/105335p2.htm

Question two:

WIN7 running Hadoop Program: Failed to locate the winutils binary in the Hadoop binary path

2015-07-06 17:32:26,455 ERROR [main] util. Shell (Shell.java:getWinUtilsPath (336))- Failed to locate the winutils binary in the Hadoop binary pathJava.io.IOException:Could not locate executable null\bin\winutils.exe in the Hadoop binaries. At Org.apache.hadoop.util.Shell.getQualifiedBinPath (shell.java:318) at Org.apache.hadoop.util.Shell.getWinUtilsPath (shell.java:333) at org.apache.hadoop.util.shell.<clinit> ( shell.java:326)

Solution:

1. Download the winutils version of Windows

On GitHub, someone provided the winutils version of Windows, the project address is: https://github.com/srccodes/hadoop-common-2.2.0-bin, download the ZIP package for this item directly, After the download is the file name is Hadoop-common-2.2.0-bin-master.zip, arbitrarily extracted to a directory

2. Configure Environment variables

Add the user variable hadoop_home, the value is the downloaded Zip package unzipped directory, and then add $hadoop_home\bin in the system variable path.

Run the program again and execute normally.

Resources:

Http://www.tuicool.com/articles/iABZJj

Uploading files to hadoop2.x HDFS problem statistics using the Java API in the Win7 environment

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.