After installing hadoop 2.7.7 in standalone mode on a Raspberry Pi on a clean Raspbian Stretch Lite (plus java version 1.8.0_65), I get the following error:
Error: JAVA_HOME is not set and could not be found.
This is despite me having this line in /etc/bash.bashrc
:
export JAVA_HOME=$(readlink -f /usr/bin/java | sed "s:bin/java::")
printenv
outputs the following:
...
JAVA_HOME=/usr/lib/jvm/jdk-8-oracle-arm32-vfp-hflt/
....
I see lots of similar questions, but the answers seem to be that either the export
is commented out by mistake, or to put this in hadoop-env.sh
- however I don't seem to have this file.
I am trying to follow the instructions here, and all is well, until:
Start, stop and list running services
1. $cd $HADOOP_HOME/sbin
2. $./start-dfs.sh
How can I fix this please ?