Hadoop installation main steps:
(1) installation of the operating environment
(2) modify the host name and user name
(3) configure a static IP address
(4) arranged SSH connection without password
(5) Installation JDK
(6) arranged Hadoop
(7) formatting hdfs
(8) verify the installation and start hadoop
Explained in detail below
(1) installation of the operating environment, the paper used is ubuntu image file, the size of the 1.95G download link is:
https://ubuntu.com/download/desktop/thank-you?country=CN&version=18.04.3&architecture=amd64
Virtual machine Vmware, download address is:
https://www.virtualbox.org/wiki/Downloads
Configuration, the computer's memory is preferably larger than 1G, 2G-4G is better, if less than a certain value, will face out of the graphical interface loaded condition.
Second, allocate disk space is greater than 20G.
I allocate memory 2G, disk 64G, other configurations are adjusted according to demand, they are all by default.
Network configuration of three modes: (NAT is the default choice)
(2) modify the host name and user name
In this machine, we do not recommend using the administrator user directly, so we create another independent hadoop user.
In turn execute the following command in the terminal port:
For the first time to set permissions reference my other blog post " Linux Ubuntu 18 for the first time with root privileges " :
Open the root
its
Create a user "hadoop":
useradd hadoop
set password:
passwd hadoop
My password is: 123456
Next officially modify the host name, modify the host name is divided into two cases, one is a temporary modification (restart will disappear), the other is a permanent modification
a. temporary
hostname <hostname>
hostname hadoop
b. permanent (CentOS system configuration)
vim /etc/sysconfig/network
服务器重启
注:由于操作系统的不同,比如ubuntu下并无/etc/sysconfig路径,
查看我的另外一篇博客《》
/etc/network/interfaces
https://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
1.设置静态IP
a.图形化界面
b.命令行进行配置
vim /etc/sysconfig/network-scripts/ifcfg-eth0
service network restart
2.设置主机名
a.暂时性的
hostname <主机名>
b.永久性的
vim /etc/sysconfig/network
服务器重启
3.设置主机名与静态IP之间映射关系
vim /etc/hosts
IP地址 <主机名>