[Top][All Lists]

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

Re: Monitoring free space on a device

From: Martin Pala
Subject: Re: Monitoring free space on a device
Date: Tue, 7 Aug 2012 22:30:04 +0200

I'm sorry - you're right, the test checks the used space. The native free space 
test is not available - possible workarounds:

1.) you can either calculate the space usage limit to alert when just 15GB are 
available => "if space usage > 200 gb then alert"
2.) or you can use the "check program" with custom script which will return 
error in the case that the free space shrinks bellow the given limit

Another option would be to implement the free space test in Monit (should be 
easy) - i think it is however very special case if the percent-based space 
usage cannot be used, as even if you want to utilise the space as much as 
possible (let's say on 99%), it can be effective only in specific cases, as the 
filesystem performance degrades due to fragmentation when the space usage is 
high (usually > 80%) => unless the application is implemented so, that it can 
use the filesystem with respect to this feature (for example Google does this 
intentionally with specific data design to use the HW as much as possible), the 
percent-based test is sufficient, as the admin needs to be warned based on when 
the filesystem reaches some utilisation% to prevent performance problems.


On Aug 7, 2012, at 5:38 PM, Bernd Wurst <address@hidden> wrote:

> Hi.
> Am 07.08.2012 14:45, schrieb Martin Pala:
>> Yes, it's possible:
>>      if space usage > 15 gb then alert
>> See the manual for full syntax:
> This does not work for me.
> The output of "df -h":
> /dev/mapper/vg0-home                 215G    183G   22G   90% /home
> Monit says with the line given above:
> space usage 47829432 blocks matches resource limit [space usage>6553589
> blocks]
> I read the documentation but I thought this monitors the space used
> ("space usage") and not the free space. That also is what the monit
> alert message says. I need to configure a fixed amount of free space,
> regardless how big the file system is.
> (It would be great if one could monitor both: Some spool/temp partition
> should propably be alerted when it gets over a fixed amount of used space.)
> - Bernd
> --
> To unsubscribe:

reply via email to

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