I have a problem with running Netbeans for Java development..
When I try to run it I get
I checked the config located in <netbeans_dir>/etc/netbeans.conf
and found following setting:
netbeans_jdkhome="/usr/"
So, I checked java
and javac
:
>>java -version
openjdk version "1.8.0_151"
OpenJDK Runtime Environment (build 1.8.0_151-8u151-b12-0ubuntu0.16.04.2-b12)
OpenJDK 64-Bit Server VM (build 25.151-b12, mixed mode)
>>whereis java
java: /usr/bin/java /usr/share/java /usr/share/man/man1/java.1.gz
>>javac -version
javac 1.8.0_151
>>whereis javac
javac: /usr/bin/javac /usr/share/man/man1/javac.1.gz
So I updated netbeans_jdkhome
to /usr/bin/javac
. Now, when I try to run Netbeans I get
Cannot find java. Please use the --jdkhome switch.
I also tried to reinstall Java according to this instruction but once I did and changed jdkhome
to /usr/lib/jvm/java-8-openjdk
I still get Cannot find java
.
What should I enter to run Netbeans properly?