VMware configuration hadoop to achieve pseudo-distributed graphic tutorial

VMware configuration hadoop to achieve pseudo-distributed graphic tutorial

1. Experimental Environment

serial number project Software and version
1 operating system CentOS6
2 Environmental Software VMware 12
3 jdk environment jdk1.8.0_181
4 Hadoop Hadoop 2.8.5
5 Native operating system Win10 Professional Edition

2. Prepare the Linux network environment

1.0 Click the VMware shortcut, right-click to open the file location -> double-click vmnetcfg.exe -> VMnet1 host-only -> modify subnet ip to set the network segment: 192.168.150.0 subnet mask: 255.255.255.0 -> apply -> ok

insert image description here

insert image description here

insert image description here

insert image description here

Go back to Windows --> Open Network and Sharing Center -> Change adapter settings -> Right click VMnet1 -> Properties -> Double-click IPv4 -> Set Windows IP: 192.168.150.110 Subnet mask: 255.255.255.0 -> Click OK

insert image description here

insert image description here

insert image description here

insert image description here

On the virtualization software--My Computer -> select the virtual machine -> right click -> settings -> network adapter -> host only -> ok

insert image description here

insert image description here

3. Configure hostname

Change the host name (permanently change)
Modify the hosts file

insert image description here

insert image description here

insert image description here

insert image description here

4. Modify the IP in centos

Modify through the Linux graphical interface (strongly recommended)

Enter the Linux graphical interface -> right click on the two small computers in the upper right corner -> click Edit connections -> select the current network System eth0 -> click the edit button -> select IPv4 -> select manual for method -> click the add button -> add IP: 192.168.150.110 Subnet mask: 255.255.255.0 Gateway: 192.168.150.1 -> apply

insert image description here

insert image description here

5. Permanently turn off the firewall

Check the firewall status

insert image description here

Stop the firewall

insert image description here

Permanently turn off the firewall

insert image description here

6. Unzip JDK

insert image description here

Modify the environment variables and source them

insert image description here

insert image description here

insert image description here

7. Unzip Hadoop

insert image description here

8. Modify configuration files (5)

First: hadoop-env.sh, under /cloud/hadoop-2.8.5/etc/hadoop

Modify about line 27. To see the line number, you can vi the file, press esc, enter a colon, enter set nu and press Enter, and the line number will be displayed.

export JAVA_HOME=/usr/java/jdk1.8.0_181 

insert image description here

insert image description here

Second: core-site.xml

<configuration>
		<!-- Specify the communication address of the HDFS boss (namenode) -->
		<property>
				<name>fs.defaultFS</name>
				<value>hdfs://itcast01:9000</value>
		</property>
		<!-- Specify the storage path for files generated by hadoop during runtime-->
		<property>
				<name>hadoop.tmp.dir</name>
				<value>/cloud/hadoop-2.8.5/tmp</value>
		</property>
	</configuration> 

insert image description here

Third: mapred-site.xml.template needs to be renamed: mv mapred-site.xml.template mapred-site.xml

	<configuration>
<!-- Notify the framework MR to use YARN -->
<property>
		<name>mapreduce.framework.name</name>
		<value>yarn</value>
</property>
		</configuration> 

insert image description here

insert image description here

After finishing here, enter and modify the name of the xml file

mv mapred-site.xml.template mapred-site.xml

Fourth: hdfs-site.xml

	<configuration>
<!-- Set the number of HDFS replicas -->
<property>
		<name>dfs.replication</name>
		<value>1</value>
</property>
		</configuration> 

insert image description here

Fifth: yarn-site.xml

	<configuration>
<!-- The way reducer gets data is mapreduce_shuffle -->
<property>
	<name>yarn.nodemanager.aux-services</name>
	<value>mapreduce_shuffle</value>
</property>
		</configuration> 

insert image description here

insert image description here

9. Add hadoop to environment variables

vim /etc/profile
	export JAVA_HOME=/usr/java/jdk1.8.0_181
export HADOOP_HOME=/cloud/hadoop-2.8.5
export PATH=$PATH:$JAVA_HOME/bin:$HADOOP_HOME/bin
	
		source /etc/profile 

insert image description here

10. Format HDFS (namenode) when using it for the first time (forgot to take a screenshot)

hadoop namenode -format

11. Start Hadoop

Start start-all
Enter ./start-all.sh in /cloud/hadoop/sbin/

insert image description here

Then keep entering the password and yes

insert image description here

12. Enter jps to check whether the configuration is successful

There are 6 things in the red box, and none of them can be missing, otherwise something is not configured properly. According to the experience of my classmates, either the network is not configured properly, or the 5 configuration files above are not written properly. If you can't find them, the simplest, crudest, troublesome but effective method is to install the machine from the beginning. I succeeded in one go.

insert image description here

Enter the browser in centos

Enter the centos ip port number 50070 from the browser to see the following picture

insert image description here

Enter the centos ip port number 8088 from the browser and the following picture will appear, success

insert image description here

The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM.

You may also be interested in:
  • How to install hadoop1.x under VMware virtual machine
  • Detailed explanation of VMware12 using three virtual machines Ubuntu16.04 system to build hadoop-2.7.1+hbase-1.2.4 (fully distributed)

<<:  JavaScript to achieve a simple carousel effect

>>:  Detailed explanation of MySQL combined index and leftmost matching principle

Recommend

A brief analysis of Linux resolv.conf

1. Introduction resolv.conf is the configuration ...

Detailed explanation of Mysql self-join query example

This article describes the Mysql self-join query....

Summary of MySQL 8.0 Online DDL Quick Column Addition

Table of contents Problem Description Historical ...

Basic usage of wget command under Linux

Table of contents Preface 1. Download a single fi...

Detailed tutorial for downloading and installing mysql8.0.21

Official website address: https://www.mysql.com/ ...

MySQL master-slave replication principle and practice detailed explanation

Table of contents Introduction effect principle f...

JDBC Exploration SQLException Analysis

1. Overview of SQLException When an error occurs ...

Solve the problem of yum installation error Protected multilib versions

Today, when installing nginx on the cloud server,...

How to write the introduction content of the About page of the website

All websites, whether official, e-commerce, socia...

Highly recommended! Setup syntax sugar in Vue 3.2

Table of contents Previous 1. What is setup synta...

Detailed example of MySQL (5.6 and below) parsing JSON

MySQL (5.6 and below) parses json #json parsing f...

How to install mysql5.6 in docker under ubuntu

1. Install mysql5.6 docker run mysql:5.6 Wait unt...