首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Monit Webmin服务未激活

Monit Webmin服务未激活
EN

Server Fault用户
提问于 2010-11-23 11:29:23
回答 2查看 1.2K关注 0票数 0

我已经用monit接口为Webmin服务编写了一个脚本。在无法重新启动服务的情况下,我可以执行进程。

代码语言:javascript
复制
check process webmin with pidfile /var/webmin/miniserv.pid
    start  = "/etc/init.d /webmin start"  
    stop   = "/etc/init.d /webmin stop"
    if failed host in1.miracletel.com port 10000 then restart
    if 5 restarts within 5 cycles then timeout
    #if changed pid 2 times within 2 cycles then alert

请你调查一下,让我知道,我是否认为这项服务是正确的?

EN

回答 2

Server Fault用户

发布于 2010-11-23 11:36:18

看上去和我的有点不同:

代码语言:javascript
复制
   root@wl183004:/home/marc.riera/scripts/admin/trunk/src/bin# cat ../etc/monit/conf.d/apache.conf 
   check process apache with pidfile /var/run/apache2.pid
   group www-data
   start program = "/etc/init.d/apache2 start"
   stop program  = "/etc/init.d/apache2 stop"
   if failed host server.org port 80 protocol http
      and request "/monit/token" then restart
   if cpu is greater than 60% for 2 cycles then alert
   if cpu > 80% for 5 cycles then restart
   if totalmem > 500 MB for 5 cycles then restart
   if children > 250 then restart
   if loadavg(5min) greater than 10 for 8 cycles then stop
   if 3 restarts within 5 cycles then timeout

可能是“开始程序”而不是“开始”??

票数 0
EN

Server Fault用户

发布于 2012-04-19 21:36:00

我的/etc/monit.d/webmin.monit.conf

注意,这些目录适用于CentOS (5.8,i 686/32位) w/ Webmin 1.580。根据您的系统进行更改&一如既往,YMMV。 check process webmin with pidfile /var/webmin/miniserv.pid group webmin start program = "/etc/init.d/webmin start" stop program = "/etc/init.d/webmin stop" if failed host localhost port 10000 then restart if failed host localhost port 10000 then restart if 5 restarts within 5 cycles then timeout if 5 restarts within 5 cycles then alert check file webmin_rc with path /etc/init.d/webmin group webmin if failed checksum then unmonitor if failed permission 755 then unmonitor if failed uid root then unmonitor if failed gid root then unmonitor

票数 0
EN
页面原文内容由Server Fault提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://serverfault.com/questions/205097

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档