I use python 2.6 & python 2.7
len([listfiles(account_dir)])
returns everytime 1
The generator must be executed to get the corrent number of registed users.
This adds a plugin for tracking NFS client caching statistics. Because
the output for this segment of nfsstat was slightly different, the
parsing required some awk dancing to programatically make coherent
labels. It's basically a separate function anyway. Right?
I added a v3 to the title of the nfsd graph to reduce ambiguity.
This is also the initial commit of the nfs_client plugin. It is
essentially identical to server. The output of nfsstat for client is
somewhat different from server in the labeling of the cache entries.
As such, I've left them off here and will add a standalone plugin for
nfs_client_cache where the awful, terrible, hideous string parsing will
take place without sullying the triviality and simplicity of this
working plugin.
This is an initial commit of FreeBSD NFS plugins for the Munin
monitoring platform. The NFS plugins for Munin depend on the
/proc filesystem in Linux for statistics which does not exist in
FreeBSD by default. While one can add the linproc package to their
installation to emulate this functionality, I felt it would be better
to write plugins that made use of native tools.
I'm leveraging the nfsstat command to create these plugins. I'm sure
there is a better primary data source in FreeBSD to gather this output
from but for my purposes, using nfsstat is adequate and acceptable.
Unfortunately this means if the output of the nfsstat command changes
due to updates, these plugins will likely report inaccurate data.
These are the days of our lives, as they say. Someone with appropriate
levels of FreeBSD knowledge can probably improve these plugins
trivially.
I'm specifically targeting FreeNAS/NAS4Free, but the code should work
on any FreeBSD system with minimal package additions. Installing munin
on FreeNAS is not supported in general, but it's easy enough to do and
I wanted it monitored, ergo we are here.
Wildcard-plugin for tcp, udp and icmp traffic-accounting (IPv4 or IPv6) going through iptables. This plugin can monitor a single ip as well as a entire subnets. Lists tcp, udp and icmp separately.
In some cases it can be useful to know the maximum value of any row of an
aggregate (for example, the maximum number of logins by a single user), without
graphing each row separately (because there are too many or the rows change).
This change allows that by setting the "only" parameter to "max" or "min".
v0.7 - added critical thresholds to some graphs, and some descriptions below some of them
v0.6 - added wlan errors by type graph - useful to detect interferences on the same frequency; added CPU usage graph
v0.5 - added ping graph - ping times from the AirOS device to a configured address; other fixes
v0.4 - corrected memory size unit calculation and display, fixed query bug, fancier graphs for memory and link speed
v0.3 - added undefined values handling in case of connection timeout, corrected linefeed character handling
v0.2 - combined all the separate pugins into one multigraph plugin, a couple of charts separated
v0.1 - initial version, separate plugin for each graph, packaged 11 different plugins
I noticed a problem with date format on /var/log/auth.log (tested on debian and ubuntu)
$ date '+%b %d'
Jun 09
/var/log/auth.log
Jun 9 13:17:01
So grep "`date '+%b %d'`" can't works fine for day with 1 digit.
I suggest to factorize and change the grep's regex with my update.