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 
這裏寫圖片描述圖片

相關文章
相關標籤/搜索