hadoop2.5.2 in execute $ bin/hdfs dfs-put etc/hadoop input encounters put: ' input ': No such file or directory solution

Source: Internet
Author: User
Tags mkdir hdfs dfs

Write more verbose, if you are eager to find the answer directly to see the bold part of the ....

(PS: What is written here is all the content in the official document of the 2.5.2, the problem I encountered when I did it)

When you execute a mapreduce job locally, you encounter the problem of No such file or directory, follow the steps in the official documentation:

1. Formatting Namenode

Bin/hdfs Namenode-format

2. Start the Namenode and Datanode daemon threads

sbin/start-dfs.sh

3. If the boot succeeds: Enter http://localhost:50070/in the browser then log on to Namenode

4. Establish the directory required to execute the MapReduce job

Bin/hdfs Dfs-mkdir/user (Note: There are spaces between-mkdir and/user

Bin/hdfs dfs-mkdir/user/User name 5. Copy the input file to DFS bin/hdfs dfs-put etc/hadoop input (Etc/hadoop is the input file Input is the destination folder)
error: Put: ' input ': No such file or directory Workaround: Add/in front of input and change to Bin/hdfs dfs-put etc/hadoop/input (here, "/" in front of input)

6. Running the provided example

Bin/hadoop jar share/hadoop/mapreduce/hadoop-mapreduce-examples-2.5.2.jar grep input Output ' dfs[a-z. +'

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.