The installation method of Hadoop, and the configuration of the Eclipse authoring MapReduce,

Source: Internet
Author: User
Tags hdfs dfs

Using Eclipse to write MapReduce configuration tutorial Online There are many, not to repeat, configuration tutorial can refer to the Xiamen University Big Data Lab blog, written very easy to understand, very suitable for beginners to see, This blog details the installation of Hadoop (Ubuntu version and CentOS Edition) and the way to configure Eclipse to run the MapReduce program.

With eclipse configured, we can start writing the MapReduce code, and the code is written, and you need to configure the input file (the default Hadoop run pseudo-distribution mode in this article).

To create a user directory on HDFs:

$./bin/hdfs dfs-mkdir-p/user/hadoop

This is the creation of a user directory on HDFs, which can be uploaded to the directory when it is developed. The commands for uploading files are:

./bin/hdfs dfs-put Local File/directory HDFs file/directory

After the upload is successful, refresh DFS locations in eclipse to see the upload directory or file. This can also be done directly in DFS Locations via create new directory or upload file to Dfs.

The code is written, and the files that need to be processed are uploaded, so you can prepare to run the code. Specific operating methods are given in the Eclipse Configuration tutorial and are not described. Here's how to write the running parameters directly. The simplest way to find the file you need to work with in Eclipse DFS Locatios is to double-click on it to show the path to the file at the top of the Eclipse file preview, and MapReduce generally takes the entire folder as input. Fill in the Eclipse's entry with the address given in the preview. Configure the following out-of-place directories as well.

Another is based on their own configuration to fill in the entry and exit parameters, the above gives the method of creating the HDFs user directory, the file needs to be processed to upload to this directory, such as uploaded to the user directory under the input directory, the entry can be set to: hdfs://localhost:9000/user/ Hadoop/input, the same can be set to Hdfs://localhost:9000/user/hadoop/output, so the entire entry needs to be filled in as: dfs://localhost:9000/user/hadoop/ The middle of input hdfs://localhost:9000/user/hadoop/output is separated by a space. It is important to note that the hdfs://localhost:9000 should correspond to your core-site.xml configuration.

Related Article

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.