Linux installation (network configuration configuration hosts + + + Free secret landing configuration environment variable)

Network Configuration

# Configure ip 
vi / etc / sysconfig / Network-scripts / ifcfg- ens33 
BOOTPROTO = static 
ONBOOT = yes 
IPADDR = 192.168.92.130 # static ip 
GATEWAY = 192.168.92.2 # gateway 
NETMASK = 255.255.255.0  
DNS1 = 114.114.114.114
 # turn off the firewall 
STOP firewalld systemctl # temporarily turn off the firewall 
systemctl disable firewalld # prohibit boot 
# reboot network 
Service network restart> reboot 
the ping baidu.com

 

Configuring hosts

vim /etc/hosts
192.168.192.128 hadoop01
192.168.192.129 hadoop02
192.168.192.130 hadoop03
vim /etc/hostname
hadoop01~03
hostnamectl set-hostname  #另一种

Free secret landing

keygen-SSH   # continue to press Enter (three were executed) 
SSH-Copy-hadoop01 the above mentioned id -i ~ 03 # execute (input ip) on each machine 
SSH ip # landing specified ip 
scp -r / Home / * 192.168.192.129 : / home /

Configuration environment variable

# JDK
vi /etc/profile 
export JAVA_HOME=/usr/jdk
export PATH=$PATH:${JAVA_HOME}/bin
# Python
vi /etc/profile
export PYTHON_HOME=/usr/Python3
export PATH=$PATH:${PYTHON_HOME}/bin
source /etc/profile
echo $PATH

 

Guess you like

Origin www.cnblogs.com/jumpkin1122/p/11520302.html