1

I have installed JDK 9, downloaded and extracted and then installed. Now when I am adding the PATH variables in bashrc terminal is showing an error

bash: =/opt/jdk-9.0.1/: No such file or directory

Even though file is present. I have added only these lines

#JAVA_PATH
$JAVA_HOME=/opt/jdk-9.0.1
export PATH=$PATH:$JAVA_HOME/bin

at the end of the bashrc file.
I am using ubuntu 17.10.

2

To set a variable you need to omit the $, so in your case the line has to be:

JAVA_HOME=/opt/jdk-9.0.1
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.