[Xymon] Monitoring empty directory

J.C. Cleaver cleaver at terabithia.org
Wed Mar 2 17:45:01 CET 2016


On Tue, March 1, 2016 1:19 am, Bert Willekens wrote:
> Hi
>
> When I monitor a directory for file size I get " Could not determine size
> of directory" when it's empty.
> For me it's no problem that the directory is empty, I just want to TRACK
> the size of the directory.
> The directory is being cleaned automatically so I can't place a 1 KiB file
> there.
>
> How can I prevent the test from turning yellow?
>
> The configuration is as follows:
>
> ++ client-local.cfg
> [server.example.com]
> DIR:I:\watchfolder
>
> ++ analysis.cfg
> HOST=server.example.com
> DIR I:\watchfolder TRACK
>
> ++ client data
> [dir:I:\watchfolder]
> 0       I:\watchfolder
>
> ++ files test
> &yellow I:\watchfolder
> Could not determine size of directory I:\watchfolder
>
> Thanks


Hi Bret,

Indeed, this is a bug. "0" sized directories (rare on the unix side, since
you'll have dir entries) are flagged as errors.

The following patch should fix it.


HTH,

-jc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dirsize0.patch
Type: text/x-patch
Size: 922 bytes
Desc: not available
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20160302/c814f3f5/attachment.bin>


More information about the Xymon mailing list