Hi,
I've made a simple PMDA for CIFS, the kernel module that lets you
mount remote SMB share on your local file system.
The PMDA parses a virtual file in /proc/fs/cifs/Stats which is created
when the cifs module is loaded and a share is mounted.
There are system-wide metrics which only have 1 instance, there are
per-mount metric (1 instance per mount) which also have their
respective "total" (sum) metric (1 instance).
I have attached a example of the Stats file and `pminfo -df cifs` on a
system with 2 shares after few operations.
This is my first PMDA, I've used the PMDA Perl module. I've only made
the Install/Remove and pmdacifs scripts: it's really just 3 files. I'm
still working on it/discussing with other Samba devs but I was
thinking it could ultimately be merged back to the original repo.
I would like some feedback on what I already have and what I should do
next. If I understand this correctly I also need a PMID for my PMDA,
so how does that work?
I also have to add some documentation. Is documenting each metric in
the add_metric() call enough?
My git repo [1] and browseable version [2]. My work is on the pmda-cifs branch.
1: https://knarf@xxxxxxxxxxxxx/knarf/pcp.git
2: https://bitbucket.org/knarf/pcp/commits/branch/pmda-cifs
Stats
Description: Binary data
pminfo
Description: Binary data
|