1. 程式人生 > >Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

Neither the JAVA_HOME nor the JRE_HOME environment variable is defined

div bsp class entos har The var 啟動tomcat highlight

Centos7.5 啟動tomcat報錯

報錯:

Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program

原因:沒有安裝java

解決方法:安裝java

yum install java -y

  

Neither the JAVA_HOME nor the JRE_HOME environment variable is defined