Ubuntu16.04 下解决“no java virtual machine was found after searching the following locations:” 方法

Ubuntu16.04 下解决“no java virtual machine was found after searching the following locations:” 方法

先装JDK(Oracle官网),以后检查安装是否成功java

如图: 
eclipse

下载好mars版的Eclipse后,发现没法正常打开,提示错误信息以下图所示: 
 spa

A Java Runtime Environment (JRE) or Java Development Kit (JDK)
must be available in order to run Eclipse. No Java virtual machine
was found after searching the following locations:
/home/leblancs/Software/eclipse/jre/bin/java
java in your current PATH.net

分析错误得知,Eclipse没有找到jre,因此报错。code

解决方法:

cd到eclipse的安装目录下,创建软链接,链接到 jre, 
ln -s /此处为jdk的安装目录/jre jre 便可。 
如图所示: 
blog

顺利启动eclipse 
这里写图片描述图片

相关文章
相关标签/搜索