[collectd] df plugin and statfs/statvfs

Florian Forster octo at collectd.org
Fri Mar 11 21:45:22 CET 2011


Hi Martin,

On Fri, Mar 11, 2011 at 01:33:36PM -0500, Martin B. Smith wrote:
> Can anyone wager any other reason why this might not work? Any advice?

the "df" plugin reads a list of mountpoints (using getmntent(3) when on
Linux) and calls statvfs(2) only for returned directories. I assume that
unless the filesystem is in fact mounted, possible targets of
automounter are not returned by getmntent(3).

If you use the file system and it is actually mounted, collectd should
pick it up and report statistics. I don't know if this counts as "usage"
of the file system, so it might be that it these file systems are not
unmounted automatically when collectd is running [*].

Hope this helps,
regards,
—octo

[*] Given that nobody has complained about this yet, I guess this is not
    likely.
-- 
Florian octo Forster
Hacker in training
GnuPG: 0x0C705A15
http://octo.it/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 2567 bytes
Desc: not available
URL: <http://mailman.verplant.org/pipermail/collectd/attachments/20110311/2cf20215/attachment.bin>


More information about the collectd mailing list