rz -be
tar -xvzf hadoop-2.7.1.tar.gz
vi /etc/profile
export JAVA_HOME=/home/skinglzw/jdk1.8.0_101
export HADOOP_INSTALL=/home/skinglzw/hadoop-2.7.1
export PATH=$JAVA_HOME/bin:$PATH:$HADOOP_INSTALL/bin:$HADOOP_INSTALL/sbin
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
source /etc/profile
如果是配置用户环境变量,则在~/.bashrc 文件中添加ZK_HOME,执行如下命令:
vim ~/.bashrc
然后重新登录linux终端,便可生效
原创文章,作者:3628473679,如若转载,请注明出处:https://blog.ytso.com/185493.html