Hi Martin,

      *Thank you very much for your reply.*

Now the script working is expected.But,it is trying to fire the same action
every 60 secs and writing the logs to log file .

Can we do ,if monit fires the action very first time and in next cycle the
status is same,then it should not fire the action.If status changes then
next action should fire, not repeatedly.


Thanks
Pratap

On Fri, Nov 4, 2011 at 5:04 PM, Martin Pala <[email protected]> wrote:

> Please can you stop monit and run it with the -v option + send the output
> again? The attached monit log excerpt doesn't show any error - the debug
> will show full trace.
>
>
> On Nov 4, 2011, at 8:24 AM, Pratap Kumar wrote:
>
> 1.) monit log
>
>
>
> On Thu, Nov 3, 2011 at 11:35 PM, Martin Pala <[email protected]>wrote:
>
>> Pratap,
>>
>> please can you provide the follwing informations?:
>>
>> 1.) monit log
>>
>
>   *[IST Nov  4 12:50:28] info     : Reinitializing monit daemon
> [IST Nov  4 12:50:28] info     : Awakened by the SIGHUP signal
> [IST Nov  4 12:50:28] info     : Reinitializing monit - Control file
> '/etc/monitrc'
> [IST Nov  4 12:50:28] info     : Shutting down monit HTTP server
> [IST Nov  4 12:50:29] info     : monit HTTP server stopped
> [IST Nov  4 12:50:29] info     : Starting monit HTTP server at
> [localhost:2812]
> [IST Nov  4 12:50:29] info     : monit HTTP server started
> [IST Nov  4 12:50:29] info     : 'system_sm1' Monit reloaded
> *
>
>>
>> 2.) output of:
>> ls -l /pratap/Service_mount.py
>>
>
> *[root@sm1 /]# ls -l /pratap/Likewise_mount.py
> -rwxrwxrwx 1 root root 1544 Nov  4 12:36 /pratap/Likewise_mount.py
> *
> *
> [root@sm1 pratap]# python Likewise_mount.py
> 1
>  *
>
>
>>
>> 3.) output of:
>> /pratap/Service_mount.py
>> echo $?
>>
>   *
> *
>
>> *[root@sm1 pratap]# echo $?
>> 1*
>>
>> Regards,
>> Martin
>>
>>
>> On Nov 3, 2011, at 3:01 PM, Pratap Kumar wrote:
>>
>> > Hi,
>> >
>> > Monit is not able to check the status of Pyhton script
>> >
>> > check program Service_mount with path "/pratap/Service_mount.py"
>> >        if status != 0 then
>> >        EXEC "/pratap/script-monit stop"
>> >        else if succeeded then
>> >        EXEC "/pratap/script-monit start"
>> >
>> >
>> > My script is returning a value 1.
>> >
>> >
>> > Please help me out.Thanks in advance for your precious support.
>> >
>> >
>> >
>> > Thanks
>> > Pratap
>> > --
>> > To unsubscribe:
>> > https://lists.nongnu.org/mailman/listinfo/monit-general
>>
>>
>> --
>> To unsubscribe:
>> https://lists.nongnu.org/mailman/listinfo/monit-general
>>
>
> --
> To unsubscribe:
> https://lists.nongnu.org/mailman/listinfo/monit-general
>
>
>
> --
> To unsubscribe:
> https://lists.nongnu.org/mailman/listinfo/monit-general
>
--
To unsubscribe:
https://lists.nongnu.org/mailman/listinfo/monit-general

Reply via email to