monit-general
[Top][All Lists]
Advanced

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

Re: Alert if file contents are greater than 40


From: Jenny Hopkins
Subject: Re: Alert if file contents are greater than 40
Date: Fri, 11 Jan 2013 10:10:59 +0000

On 10 January 2013 22:26, Dimitri Yioulos <address@hidden> wrote:
> On Thursday 10 January 2013 4:24:27 pm Jenny Hopkins wrote:
>> Hullo,
>>
>> I've been having an issue with memory hungry programs so
>> have written a script that takes a user and program
>> params and stuffs the memory usage into a file as an
>> integer. This is run by cron every ten minutes.
>> I want monit to keep an eye on the file contents and
>> alert if it exceeds a certain figure.
>> So far, I can only find evidence that monit supports text
>> file matches. I've tried
>>
>> "check file memfile.irssi with path /tmp/memfile.irssi
>> if  match "[4-9][0-9]" then alert"
>>
>> but this doesn't seem to work. I'm adding a \n to the end
>> of the file.
>>
>> Sorry if this has been asked before.
>>
>> Thanks,
>>
>> Jenny
>>
>
>
> Er, Jenny. not to diss the capabilities of Monit, but why
> don't you simply extend your script to send out an email
> alert based on a memory usage threshhold?
>
> -

That would be the easy option, but I just became determined that monit
could do it and I wanted to make it so.
Thanks,
Jenny



reply via email to

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