Big data - install Hadoop, JDK and environment variables in xsell6

Empire my love 2022-05-14 14:54:28 阅读数:682

bigdatainstallhadoopjdk

One .  install JDK And environment variables

1. Get into Xshell6, Connecting virtual machines , Change ordinary users to root user  

2.cd Go to the root , And then again cd To usr/local In the folder

3. establish app Folder  

4. Get into app Folder , To install a rz Upload file component yum -y install lrzsz  and    install vim Editor yum -y install vim


5.(cd To usr/local In the folder ), Upload JDK( It's up to you to find the compressed package )

6. decompression JDK  tar -zxvf jdk-8u181-linux-x64.tar.gz

 7. Change the file name to jdk  mv jdk-1.8.0 jdk   And delete jdk-8u181-linux-x64.tar.gz The package

8.  add to jdk To environment variable ( Add... At the end )  vim /etc/profile  ( Don't change environment variables , Otherwise, all commands will be invalid )(I Key to insert text ;esc Exit the editor ;q sign out ;q! Forced exit ;wq Exit after saving )

#JDK

export JAVA_HOME=/usr/local/jdk
export PATH=$PATH:$JAVA_HOME/bin

 

 9. Call resources  source /etc/profile

Check if the configuration is successful  java -version

 

  Two .  install Hadoop And environment variables

1.(cd To usr/local In the folder ), Upload Hadoop ( It's up to you to find the compressed package )

 2. decompression JDK  tar -zxvf hadoop-2.7.6.tar.gz

 

 3. Change the file name to jdk  mv hadoop-2.7.6.tar.gz  hadoop And delete hadoop-2.7.6.tar.gz The package

 

4.  add to jdk To environment variable ( Add... At the end )  vim /etc/profile  ( Don't change environment variables , Otherwise, all commands will be invalid )(I Key to insert text ;esc Exit the editor ;q sign out ;q! Forced exit ;wq Exit after saving )

#HADOOP

export HADOOP_HOME=/usr/local/hadoop
export PATH=$PATH:$HADOOP_HOME/bin:$HADOOP_HOME/sbin

 5. Call resources  source /etc/profile

Check if the configuration is successful  hadoop version

 

Configuration complete ! 

版权声明:本文为[Empire my love]所创,转载请带上原文链接,感谢。 https://javamana.com/2022/134/202205141446235216.html