Neither the JAVA_HOME nor the JRE_HOME environment variable is defined (tomcat error)

error: Linux下啓動和關閉tomcat報錯,如下圖所示: 原因: 因爲啓動tomcat會調用tomcat安裝文件中的startup.bat,而它調用了catalina.bat則調用了setclasspath.bat。因此需要在setclasspath.bat的開頭手動聲明環境變量。 解決方案: 用vim打開tomcat的bin目錄下的setclasspath.sh,添加JAVA_HOME
相關文章
相關標籤/搜索