How to Install Hadoop

This wikiHow teaches you how to install Hadoop on a Windows computer. [[Use-WinRAR

Method 1 of 5:

Preparing to Install Hadoop

  1. Picture 1 of How to Install Hadoop
    Install WinRAR with TAR support. Since you'll need to extract a TAR file to install Hadoop, make sure that you check the "TAR" box when installing WinRAR.
  2. Picture 2 of How to Install Hadoop
    Install Java. To do so:
    1. Go to https://www.java.com/en/download/ and click Free Java Download.
    2. Click Agree and Start Free Download.
    3. Double-click the downloaded Java file.
    4. Click Yes when prompted.
    5. Click Install, then follow any on-screen prompts.
  3. Picture 3 of How to Install Hadoop
    Open the Hadoop page. Go to https://hadoop.apache.org/ in your computer's web browser.
  4. Picture 4 of How to Install Hadoop
    Click Download. It's at the top of the page.
  5. Picture 5 of How to Install Hadoop
    Click binary next to the top result. This will take you to the Binary mirror link page for the most recent version of Hadoop.
  6. Picture 6 of How to Install Hadoop
    Click the recommended link. It's the link below the "We suggest the following mirror site for your download:" line of text near the top of the page. Doing so prompts your computer to begin downloading the Hadoop TAR file.
  7. Picture 7 of How to Install Hadoop
    Open the Java Development Kit (JDK) site. Go to http://www.oracle.com/technetwork/java/javase/downloads/index.html in your browser.
  8. Picture 8 of How to Install Hadoop
    Click DOWNLOAD. You'll find this under the "JDK" heading on the right side of the page.
  9. Picture 9 of How to Install Hadoop
    Check the "Accept License Agreement" box. It's near the bottom of the page.
  10. Picture 10 of How to Install Hadoop
    Click the Windows "Download" link. This is the link under the "Downloads" heading and to the right of the "Windows" category near the bottom of the page. Doing so prompts the JDK setup file to download onto your computer.
  11. Picture 11 of How to Install Hadoop
    Install the JDK. Double-click the JDK's setup file, then do the following:
    1. Click Yes when prompted.
    2. Click Next twice.
    3. Allow the JDK to install, and follow any on-screen prompts if necessary.
Method 2 of 5:

Adding Hadoop to Your Hard Drive

  1. Picture 12 of How to Install Hadoop
    Open the Hadoop TAR file. Double-click the downloaded Hadoop TAR file to do so. It should open in WinRAR.
  2. Picture 13 of How to Install Hadoop
    Click Extract To. It's at the top of the WinRAR window. Doing so opens a pop-up window.
  3. Picture 14 of How to Install Hadoop
    Select your hard drive as the extraction location. In most cases, your hard drive should be labeled OS (C:); click it in the right-hand pane of the pop-up window to select it.
  4. Picture 15 of How to Install Hadoop
    Click OK. It's at the bottom of the window. Doing so will extract the Hadoop folder to your computer's "C" drive. Once the extraction is complete, you can proceed.
Method 3 of 5:

Adding Hadoop and Java Environment Variables

  1. Picture 16 of How to Install Hadoop
    Open This PC. Double-click the This PC app icon, which resembles a computer monitor.
    1. If you don't have This PC on your desktop, click File Explorer
      Picture 17 of How to Install Hadoop
      and then click This PC on the left side of the window.
  2. Picture 18 of How to Install Hadoop
    Open your hard drive. Double-click your hard drive's name (again, usually OS (C:)) below the "Devices and drives" heading.
  3. Picture 19 of How to Install Hadoop
    Open the Hadoop installation folder. Double-click the "hadoop" folder in the list of folders on your hard drive.
    1. You'll see the Hadoop version number after "hadoop" in the folder's name.
  4. Picture 20 of How to Install Hadoop
    Open the "bin" folder. Double-click the "bin" folder to do so.
  5. Picture 21 of How to Install Hadoop
    Copy the address. Click the address bar at the top of the File Explorer to highlight the address, then press Ctrl+C to copy it.
  6. Picture 22 of How to Install Hadoop
    Open Start
    Picture 23 of How to Install Hadoop
    . Click the Windows logo in the bottom-left corner of the screen.
  7. Picture 24 of How to Install Hadoop
    Open the System Variables window. Type in edit the system, then click Edit the system environment variables at the top of the Start menu.
  8. Picture 25 of How to Install Hadoop
    Click Environment Variables…. It's at the bottom of the System Variables window. A new window will appear.
  9. Picture 26 of How to Install Hadoop
    Click New… under the "User variables" section. Doing so opens yet another window.
  10. Picture 27 of How to Install Hadoop
    Name the variable. Type HADOOP_HOME into the "Variable name" text box.
  11. Picture 28 of How to Install Hadoop
    Enter the path to the Hadoop folder. Click the "Variable value" text box, then press Ctrl+V.
  12. Picture 29 of How to Install Hadoop
    Click OK. It's at the bottom of the window. You should now have a "HADOOP_HOME" variable listed in the top pane.
  13. Picture 30 of How to Install Hadoop
    Add Java to the "User variables" section. Go to your hard drive, open the "Program Files" folder, open the "Java" folder, open the "jdk" folder (this folder will have a number after it), and open the "bin" folder, then copy the address. You can then add Java to the environment by doing the following:
    1. Click New... under the "User variables" section.
    2. Type JAVA_HOME into the "Name" text box.
    3. Click the "Variable value" text box, then press Ctrl+V.
    4. Click OK.
  14. Picture 31 of How to Install Hadoop
    Add both addresses to the PATH variable. You can add both the Hadoop address and the Java address to the PATH variable by doing the following:
    1. Click the "Path" heading in the "System variables" section.
    2. Click Edit....
    3. Click New... on the right side of the window.
    4. Paste in the Java address by pressing Ctrl+V, then press Enter.
    5. Go back and copy the Hadoop "bin" folder's address, then click New..., paste it in, and press Enter.
  15. Picture 32 of How to Install Hadoop
    Save your changes to the environment variables. Click OK on all three open System Environment Variables windows to do so.
Method 4 of 5:

Configuring Hadoop

  1. Picture 33 of How to Install Hadoop
    Open the Hadoop installation folder. Go to your hard drive in This PC, then double-click the "hadoop" folder.
  2. Picture 34 of How to Install Hadoop
    Open the "etc" folder. Double-click it to do so.
  3. Picture 35 of How to Install Hadoop
    Open the "hadoop" folder. This should be the only folder in the "etc" folder.
  4. Picture 36 of How to Install Hadoop
    Open the "core-site" file in Notepad. To do so:
    1. Right-click the "core-site" file.
    2. Select Open with in the drop-down menu.
    3. Click Notepad.
  5. Picture 37 of How to Install Hadoop
    Add the proper configuration. Delete the "" tags at the end of the document, then copy and paste in the following code:
    <configuration>   <property>    <name>fs.defaultFS</name>   <value>hdfs://localhost:9000</value>   </property> </configuration> 
  6. Picture 38 of How to Install Hadoop
    Save the document. Press Ctrl+S, then click OK if prompted. You can then close the document.
  7. Picture 39 of How to Install Hadoop
    Open the "mapred-site" file in Notepad. You should see a file similar to the "core-site" file open.
  8. Picture 40 of How to Install Hadoop
    Add the proper configuration. Delete the "" tags at the end of the document, then copy and paste in the following code:
    <configuration>  <property>     <name>mapreduce.framework.name</name>     <value>yarn</value>  </property> </configuration> 
  9. Picture 41 of How to Install Hadoop
    Save the document. Press Ctrl+S, then click OK if prompted. You can then close the document.
  10. Picture 42 of How to Install Hadoop
    Go back to the "hadoop" installation folder. Click the "hadoop" folder which includes the Hadoop version number in the address bar.
  11. Picture 43 of How to Install Hadoop
    Create a new folder named "data". To do this, right-click a blank space in the window, select New, click Folder, type in data, and press Enter.
  12. Picture 44 of How to Install Hadoop
    Open the "data" folder. Double-click it to do so.
  13. Picture 45 of How to Install Hadoop
    Create two new folders named "datanode" and "namenode". When you're done, you should have a "data" folder that has one folder named "datanode" and one folder named "namenode".
  14. Picture 46 of How to Install Hadoop
    Open the "hdfs-site" file in Notepad. You'll find this file in the "hadoop" folder that's inside the "etc" folder from earlier.
  15. Picture 47 of How to Install Hadoop
    Add the proper configuration. Delete the "" tags at the end of the document, then copy and paste in the following code:
    <configuration>  <property>    <name>dfs.replication</name>    <value>1</value>  </property>  <property>    <name>dfs.namenode.name.dir</name>    <value>C:hadoop-2.8.0datanamenode</value>  </property>  <property>     <name>dfs.datanode.data.dir</name>    <value>C:hadoop-2.8.0datadatanode</value>  </property> </configuration> 
  16. Picture 48 of How to Install Hadoop
    Save the document. Press Ctrl+S, then click OK if prompted. You can then close the document.
  17. Picture 49 of How to Install Hadoop
    Open the "yarn-site" file in Notepad. This file is also in the "hadoop" folder.
  18. Picture 50 of How to Install Hadoop
    Add the proper configuration. Delete the "" tags at the end of the document, then copy and paste in the following code:
    <configuration>   <property>     <name>yarn.nodemanager.aux-services</name>     <value>mapreduce_shuffle</value>   </property>   <property>   <name>yarn.nodemanager.auxservices.mapreduce.shuffle.class</name>   <value>org.apache.hadoop.mapred.ShuffleHandler</value>   </property> </configuration> 
  19. Picture 51 of How to Install Hadoop
    Save the document. Press Ctrl+S, then click OK if prompted. You can then close the document.
  20. Picture 52 of How to Install Hadoop
    Open the "hadoop-env" file in Notepad. Simply right-click this file and then click Edit to do so.
  21. Picture 53 of How to Install Hadoop
    Update the Java path. Find the set JAVA_HOME=%JAVA_HOME% line, type @rem in front of it, and then type below it the phrase "set JAVA_HOME=" followed by your Java JDK folder's address (not the "bin" folder's address). For example, your line might resemble the following:
    @rem set JAVA_HOME=%JAVA_HOME% set JAVA_HOME=C:Program FilesJavajdk-10.0.2 
Method 5 of 5:

Applying the Hadoop Fix

  1. Picture 54 of How to Install Hadoop
    Download and extract the Hadoop fix file. Open the fix file's Google Drive page and click Download, then extract it by doing the following:
    1. Double-click the fix file.
    2. Click Extract To.
    3. Click Desktop.
    4. Click OK.
  2. Picture 55 of How to Install Hadoop
    Open the extracted fix file. Once the file finishes extracting, double-click it to open it.
  3. Picture 56 of How to Install Hadoop
    Copy the "bin" folder. Click once the "bin" folder to select it, then press Ctrl+C to copy it.
  4. Picture 57 of How to Install Hadoop
    Open the Hadoop installation folder. Go to your hard drive's folder, then double-click the "hadoop" folder there.
  5. Picture 58 of How to Install Hadoop
    Paste in the "bin" folder. Press Ctrl+V to do so.
  6. Picture 59 of How to Install Hadoop
    Click Replace the files in the destination when prompted. Once this process is complete, Hadoop should be installed on your computer.
Update 05 March 2020
Category

System

Mac OS X

Hardware

Game

Tech info

Technology

Science

Life

Application

Electric

Program

Mobile