【问题标题】:Monit all files in directory监视目录中的所有文件
【发布时间】:2014-11-07 22:48:22
【问题描述】:

是否有可能使用 monit 对目录中的所有文件进行检查,而不单独提及该目录中的每个文件?

例如:

/etc/configurations-to-monitor/

配置1

配置2

配置3

现在我在 /etc/monit/conf.d/myconfigs 中使用它:

检查目录 myconfigs 路径 /etc/configurations-to-monitor/

如果更改了时间戳,则发出警报

但是这个结构有一些绕过的可能性。所以我想在这个目录上运行时间戳和校验和检查。目标是在此目录中添加更多配置,而无需再次接触 monit 配置。

提前致谢

【问题讨论】:

    标签: monit


    【解决方案1】:

    monit 中所有缺失功能的解决方案是创建一个脚本来完成这项工作,monit 只会检查其返回码。

    【讨论】:

      【解决方案2】:

      来自 monit-general@nongnu.org,2014 年 11 月 19 日

        Hello, using pattern for multiple files monitoring is not supported currently.
        We plan to add this feature.
      

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2016-07-30
        • 2013-07-09
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2017-02-14
        • 2013-10-02
        相关资源
        最近更新 更多