monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Troubleshooting - verbose not verbose enough


From: Martin Pala
Subject: Re: Troubleshooting - verbose not verbose enough
Date: Tue, 1 Mar 2011 13:42:59 +0100

Monit purges the environment variables for security reasons and sets spartan path: PATH=/bin:/usr/bin:/sbin:/usr/sbin

You can log the output of executed script this way:

    start program = "/bin/bash -c '/usr/bin/myscript blabla >> /tmp/myscript.out 2>&1'"

Regards,
Martin



On Mar 1, 2011, at 2:17 AM, Adam Tucker wrote:

Hi. I'm attempting to troubleshoot a process that won't start under Monit. I'm using a system-wide install of RVM and have followed all the steps outlined in this thread:


None of the suggestions there worked for me, and I'm having trouble finding any useful output to figure out why. I started Monit in verbose mode and tailed the log, however the debug statements weren't very helpful. I got stuff like this (path has been truncated with ...) :

[EST Feb 28 20:13:26] info     : 'resque_PO0' trying to restart
[EST Feb 28 20:13:26] debug    : Monitoring disabled -- service resque_PO0
[EST Feb 28 20:13:26] debug    : monit: pidfile '/opt/.../current/tmp/pids/resque.PO0.pid' does not exist
[EST Feb 28 20:13:26] debug    : monit: pidfile '/opt/.../current/tmp/pids/resque.PO0.pid' does not exist
[EST Feb 28 20:13:26] info     : 'resque_PO0' start: /usr/local/bin/rvm-shell
[EST Feb 28 20:13:26] debug    : monit: pidfile '/opt/.../current/tmp/pids/resque.PO0.pid' does not exist
(previous line repeats about 20 times)
[EST Feb 28 20:13:56] error    : 'resque_PO0' failed to start
[EST Feb 28 20:13:56] debug    : -------------------------------------------------------------------------------
[EST Feb 28 20:13:56] debug    :     monit() [0x40f53d]
[EST Feb 28 20:13:56] debug    :     monit(LogError+0x9f) [0x40fc8f]
[EST Feb 28 20:13:56] debug    :     monit(Event_post+0x31d) [0x40cd3d]
[EST Feb 28 20:13:56] debug    :     monit() [0x40ac4a]
[EST Feb 28 20:13:56] debug    :     monit(control_service+0xff) [0x40aeef]
[EST Feb 28 20:13:56] debug    :     monit(Event_post+0x3d9) [0x40cdf9]
[EST Feb 28 20:13:56] debug    :     monit(check_process+0xa1) [0x420fd1]
[EST Feb 28 20:13:56] debug    :     monit(validate+0x1e4) [0x421464]
[EST Feb 28 20:13:56] debug    :     monit(main+0xac7) [0x412397]
[EST Feb 28 20:13:56] debug    :     /lib/libc.so.6(__libc_start_main+0xfd) [0x7f0473532c4d]
[EST Feb 28 20:13:56] debug    :     monit() [0x409e79]
[EST Feb 28 20:13:56] debug    : -------------------------------------------------------------------------------
[EST Feb 28 20:13:56] debug    : Monitoring enabled -- service resque_PO0

I'd like to see what the output was when Monit called the startup command. Any way to do that?

Thanks!
--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general


reply via email to

[Prev in Thread] Current Thread [Next in Thread]