【英文】为Hadoop配置Java环境
Preface
In general, the Java environment only needs to be configured in the system environment variables. In order to prevent errors, you can manually specify the Java environment in the Hadoop startup script.
Copy environment variables
- Copy the
JAVA_HOME
in the environment variables
1 | echo $JAVA_HOME |
Modify configuration
- Edit the configuration
1 | vim hadoop/etc/hadoop/hadoop-env.sh |
- Modify line 25 of the
hadoop-env.sh
configuration file
1 | export JAVA_HOME=/home/app/jdk1.8.0_65 |