8
forks -Plugin to monitor the number of forks per second on the machine
25
#%# capabilities=autoconf
29
. $MUNIN_LIBDIR/plugins/plugin.sh
31
if [ "$1" = "autoconf" ]; then
32
if [ -r /proc/stat ]; then
36
echo "no (/proc/stat not readable)"
41
if [ "$1" = "config" ]; then
43
echo 'graph_title Fork rate'
44
echo 'graph_args --base 1000 -l 0 '
45
echo 'graph_vlabel forks / ${graph_period}'
46
echo 'graph_category processes'
47
echo 'graph_info This graph shows the number of forks (new processes started) per second.'
48
echo 'forks.label forks'
49
echo 'forks.type DERIVE'
51
echo 'forks.max 100000'
52
echo 'forks.info The number of forks per second.'
58
echo -n "forks.value "
59
awk '/processes/ {print $2}' /proc/stat