Monit HTTP状态代码给出了语法错误

我的系统正在运行monit 5.19。 当我启动Monit时,我看到错误syntax error 'status'

状态似乎从5.8支持,所以我不知道是什么问题。

这是由以下指令引起的。

 check host nlb with address host if failed port 443 protocol HTTPS request "/healthcheck" ssl options {verify: disable} timeout 15 seconds status = 200 then restart 

status语句是proto http语句的一部分,因此需要在ssl行之前(这不是 proto http一部分)。 请参阅https://mmonit.com/monit/documentation/monit.html#HTTP中proto http的定义…

  PROTO(COL) HTTP [USERNAME "string"] [PASSWORD "string"] [REQUEST "string"] [STATUS operator number] [CHECKSUM checksum] [HTTP HEADERS list of headers] [CONTENT < "=" | "!=" > STRING] 

不给错误的文件的版本是

 check host nlb with address host if failed port 443 protocol HTTPS request "/healthcheck" status = 200 ssl options {verify: disable} timeout 15 seconds then restart