linux – 安装monit后我做monit状态myproc我得到“错误连接到monit守护进程”

安装monit后我做monit status myproc我得到“错误连接到monit守护进程”

我读到了某个地方

The status command won’t work in the
case that monit is running indaemon
mode without its http support – the
command ‘monit status’ in such case
tries to get the status from the
daemon via http/tcp. To start the http
interface you need to add the ‘set
httpd …’ statement to
theconfiguration.

这还是正确的吗?该帖子来自2005年

解决方法

我正努力在我的ubuntu服务器上设置monit,这里有几件事要检查:

>确保在/ etc / default / monit中设置startup = 1
>确保取消注释/ etc / monit / monitrc中的httpd参数

/ etc / monit / monitrc中的最后一个“gotcha”:

set daemon  120           # check services at 2-minute intervals
#  with start delay 240  # optional: delay the first check by 4-minutes (by
#                           # default Monit check immediately after Monit start)

我首先没有注释“启动延迟240”行.如果使用此选项,httpd服务器似乎不会立即启动.我花了一段时间才意识到为什么monit正在运行但是httpd服务器没有运行.

相关文章

文章浏览阅读1.8k次,点赞63次,收藏54次。Linux下的目录权限...
文章浏览阅读1.6k次,点赞44次,收藏38次。关于Qt的安装、Wi...
本文介绍了使用shell脚本编写一个 Hello
文章浏览阅读1.5k次,点赞37次,收藏43次。【Linux】初识Lin...
文章浏览阅读3k次,点赞34次,收藏156次。Linux超详细笔记,...
文章浏览阅读6.8k次,点赞109次,收藏114次。【Linux】 Open...