【发布时间】:2020-03-19 06:22:30
【问题描述】:
我试图在我的 ubuntu 服务器上为 tomcat 配置 monit,但是当我执行时:
monit reload
它会抛出一个错误:
/etc/monit/monitrc:292: Program does not exist: 'if'
我不知道为什么会这样。
我在文件末尾添加了我的配置:
/etc/monit/monitrc
这是我的配置代码:
check process tomcat7 with pidfile "/usr/local/tomcat/tomcat.pid"
start program = "/etc/init.d/tomcat start"
stop program = " "/etc/init.d/tomcat stop"
if failed port 8080 for 5 cycles then restart
include /etc/monit/conf.d/*
include /etc/monit/conf-enabled/*
我做错了什么?为什么会抛出这个错误?
谢谢!
【问题讨论】:
标签: ubuntu tomcat server monit