error: Linux下启动和关闭tomcat报错,如下图所示: 而在windows下用cmd启动startup.bat也会报如上的错误: Neither the JAVA_HOME nor the JRE_HOME environment variable is defined 双击startup.bat则是一闪而过,浏览器访问localhost:8080无法访问tomcat的主页 原因: 因为启动tomcat会调用tomcat安装文件中的startup.bat,而它调用了catalina.…