Issue
I just downloaded hadoop and unzipped the file. but when I run hadoop version command from command prompt , I'm getting below error . I double check and JAVA_HOME is set to "C:\Program Files\Java\jdk1.8.0_45\bin" which looks ok to me .
C:\Users\shri-pc>hadoop version
The system cannot find the path specified.
Error: JAVA_HOME is incorrectly set.
Please update C:\JAVA\hadoop-2.6.0\conf\hadoop-env.cmd
'-Xmx512m' is not recognized as an internal or external command,
operable program or batch file.
Output of java -version command is coming properly . Please advice .
C:\Users\shri-pc>java -version
java version "1.8.0_51"
Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
Java HotSpot(TM) Client VM (build 25.51-b03, mixed mode)
Solution
Your JAVA_HOME
should not include bin
. Change it from
"C:\Program Files\Java\jdk1.8.0_45\bin"
to
"C:\Program Files\Java\jdk1.8.0_45"
And you can add it to your path (in Windows) like
set "PATH=%PATH%;%JAVA_HOME%\bin"
Answered By - Elliott Frisch
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.