Macos IntelliJ maven web项目tomcat8 启动时报错Cannot run program "apache-tomcat-8/bin/catalina.sh解决方法
程序员文章站
2022-05-12 21:33:28
...
错误信息
Non-managed pom.xml file found:
/Users/alanpan/java_code/ideacode/platform/pom.xml
Add as Maven Project or Disable notification
Frameworks Detected
Web framework is detected.
Configure
Compilation completed successfully with 41 warnings in 7 s 338 ms
Compilation completed successfully in 6 s 481 ms
Error running 'platfrom': Cannot run program "/Users/alanpan/java_tools/apache-tomcat-8.5.34/bin/catalina.sh" (in directory "/Users/alanpan/java_tools/apache-tomcat-8.5.34/bin"): error=13, Permission denied
问题原因:Tomcat 的catalina.sh 没有执行权限
解决方法 给 catalina.sh 文件授可执行权限
chmod a+x /Users/alanpan/java_tools/apache-tomcat-8.5.34/bin/catalina.sh
或者 在tomcat 目录 执行
chmod -R 777 *