|
|
Subject: Re: is monit just a pain in the arse or what ? - msg#00064
List: monitoring.monit.general
Martin Pala wrote:
1.) RTFM
2.) post your config
3.) keep etiquette or get fired
Martin
andrew taylor wrote:
Normally, when I ask monit for status, I get this...
root@domU-12-31-36-00-34-62:~# monit summary
monit: cannot read status from the monit daemon
This happens constantly and is frustrating and useless.
When I do get data, it tells me something like this...
Process 'rails_mongrel_9200' Execution failed
Process 'rails_mongrel_9201' Execution failed
Process 'rails_job' running
Process 'rails_mailer' Execution failed
uhh...not quite, if I ps, all the processes are running, all the pids
are there, everything is fine.
When I ask monit to start/stop by group, it usually ignores me.
All these monit features, and to me, the basics are not even right.
I am running Ubuntu Feisty server with the apt-get monit installed,
so I did not screw anything up in the build/install.
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
1) already RTFM
2) posted my monitrc
3) make the daemon respond or get fired
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
Was this page helpful?
Thread at a glance:
Previous Message by Date:
click to view message preview
Re: is monit just a pain in the arse or what ?
Ryan Dooley wrote:
On 7/26/07 6:03 PM, "andrew taylor" <aktxyz@xxxxxxxxx> wrote:
Normally, when I ask monit for status, I get this...
root@domU-12-31-36-00-34-62:~# monit summary
monit: cannot read status from the monit daemon
This happens constantly and is frustrating and useless.
When I do get data, it tells me something like this...
Process 'rails_mongrel_9200' Execution failed
Process 'rails_mongrel_9201' Execution failed
Process 'rails_job' running
Process 'rails_mailer' Execution failed
uhh...not quite, if I ps, all the processes are running, all the pids
are there, everything is fine.
Would you mind posting your monitrc for your apps and your /etc/monitrc if
they are different? Properly sanitized of course :-)
For what it is worth, I do monitor puppet (well puppetmasterd) on a
particular host and it works quite well. Tomorrow, if it'd help any, I'll
filter mine back to this list.
Cheers,
Ryan
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
Sure, here is the monitrc.
#===== basic setup
set daemon 60
set httpd port 2812 and allow admin:test
set logfile /var/log/monit.log
#===== include other configs
include /etc/monit/includes/*
#===== mysql
check process mysql
with pidfile "/var/run/mysqld/mysqld.pid"
start program = "/etc/init.d/mysql start"
stop program = "/etc/init.d/mysql stop"
group system
if failed port 3306 protocol mysql then restart
#===== apache
check process apache
with pidfile "/var/run/apache2.pid"
start program = "/etc/init.d/apache2 start"
stop program = "/etc/init.d/apache2 stop"
group system
#===== sshd
check process sshd
with pidfile "/var/run/sshd.pid"
start program = "/etc/init.d/ssh start"
stop program = "/etc/init.d/ssh stop"
group system
if failed port 22 protocol ssh then restart
#===== cron
check process cron
with pidfile "/var/run/crond.pid"
start program = "/etc/init.d/cron start"
stop program = "/etc/init.d/cron stop"
group system
#===== samba
check process smbd
with pidfile /var/run/samba/smbd.pid
start program = "/etc/init.d/samba start"
stop program = "/etc/init.d/samba stop"
group system
if failed port 139 type TCP then restart
#===== samba
check process nmbd
with pidfile "/var/run/samba/nmbd.pid"
start program = "/etc/init.d/samba start"
stop program = "/etc/init.d/samba stop"
group system
if failed port 138 type UDP then restart
if failed port 137 type UDP then restart
#===== vmware
check process guestd
with pidfile "/var/run/vmware-guestd.pid"
start program = "/etc/init.d/vmware-tools start"
stop program = "/etc/init.d/vmware-tools stop"
group system
#==== rails_toucan_myfavcreditunion_mongrel_9200
check process rails_toucan_myfavcreditunion_mongrel_9200
with pidfile "/home/me/workspace/app1/log/mongrel.9200.pid"
start program = "/usr/bin/mongrel_rails start -P
/home/me/workspace/app1/log/mongrel.9100.pid -d -e production -p 9200 -c
/home/me/workspace/app1 -t 30" as uid me and gid me
stop program = "/usr/bin/mongrel_rails stop -P
/home/me/workspace/app1/log/mongrel.9100.pid"
group app1
if mem usage > 50% then restart
#==== app1_mongrel_9201
check process app1_mongrel_9201
with pidfile "/home/me/workspace/app1/log/mongrel.9201.pid"
start program = "/usr/bin/mongrel_rails start -P
/home/me/workspace/app1/log/mongrel.9101.pid -d -e production -p 9201 -c
/home/me/workspace/app1 -t 30" as uid me and gid me
stop program = "/usr/bin/mongrel_rails stop -P
/home/me/workspace/app1/log/mongrel.9101.pid"
group app1
if mem usage > 50% then restart
#==== app1_jobs
check app1_jobs
with pidfile "/home/me/workspace/app1/app/daemons/job_daemon.rb.pid"
start program = "/home/me/workspace/app1/app/daemons/job_control.rb
start -f" as uid me and gid me
stop program = "/home/me/workspace/app1/app/daemons/job_control.rb
stop -f"
group app1
if mem usage > 50% then restart
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
Next Message by Date:
click to view message preview
Re: 2 copies started at once
I've looked at the bs.sh script, there is no way for it to start 2
copies unless it is called twice. It's a lightly edited copy of the
standard /etc/init.d startup script.
The only times I've noticed this happen is under the following
sequence of events:
system boot up, monit starts up, bs starts up once , all ok
I do "monit stop bs1", even checked via ps that it's gone, all ok
I do "monit start bs1", 2 copies start running as shown by ps, the pid
values are only different by 7.
could I be seeing a problem with monit starting to monitor bs1 again
(so start 1) AND start bs1 (start 2) because I told it to, or
something like that.
On 27/07/07, Jan-Henrik Haukeland <hauk@xxxxxxxxxxxxxx> wrote:
> On 27. jul. 2007, at 14.22, Nick Upson wrote:
>
> > I use
> >
> > set daemon 120
> >
> > I wondered if it was related to using restart into the script, which,
> > standard behaviour, attempts to stop the pid and removes the pid file
> > anyway. I need this in case the process crashed as a simple "start"
> > stops if the pid file exists.
> > does monit distinguish between start and restart if the command?
>
> Monit just execute the command given in 'start program' and does not
> parse, read or investigate the command at all. So when you use
> restart and stop as arguments to /opt/unb/bin/bs.sh monit does not
> consider those arguments at all. It just does a exec("/opt/unb/bin/
> bs.sh 1 restart"). You should get someone to look at the script /opt/
> unb/bin/bs.sh since the problem you have with two processes most
> certainly is a bug in the script.
>
>
>
> --
> To unsubscribe:
> http://lists.nongnu.org/mailman/listinfo/monit-general
>
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
Previous Message by Thread:
click to view message preview
Re: is monit just a pain in the arse or what ?
1.) RTFM
2.) post your config
3.) keep etiquette or get fired
Martin
andrew taylor wrote:
Normally, when I ask monit for status, I get this...
root@domU-12-31-36-00-34-62:~# monit summary
monit: cannot read status from the monit daemon
This happens constantly and is frustrating and useless.
When I do get data, it tells me something like this...
Process 'rails_mongrel_9200' Execution failed
Process 'rails_mongrel_9201' Execution failed
Process 'rails_job' running
Process 'rails_mailer' Execution failed
uhh...not quite, if I ps, all the processes are running, all the pids
are there, everything is fine.
When I ask monit to start/stop by group, it usually ignores me.
All these monit features, and to me, the basics are not even right.
I am running Ubuntu Feisty server with the apt-get monit installed, so I
did not screw anything up in the build/install.
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
Next Message by Thread:
click to view message preview
Re: is monit just a pain in the arse or what ?
1) already RTFM
Apparently not, since I have a cluster of machines in denver which
are all maintenance free because of monit, and I'm running rails.
2) posted my monitrc
Only after someone who was _very_ polite didn't spank you and kindly
asked you to do so
3) make the daemon respond or get fired
They can fire you, you can't fire them - you didn't pay and it's
their mailing list.
Really, I'm quite tolerant on mailing lists because I know people
tend to "read the worst" into email, but your post was disrespectful
and you deserve much more abuse than you got.
Remember that in many circumstances, good suggestions (like the one
about clarifying the warnings for bad pid paths) can be lost if you
deliver them with language designed to antagonize.
good luck,
_alex
--
alex black, founder
the turing studio, inc.
510.666.0074
root@xxxxxxxxxxxxxxxx
http://www.turingstudio.com
800 jones street
berkeley, ca 94710
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general
|
|