WIP > Working on some possible munin plugins
All checks were successful
continuous-integration/drone/push Build is passing
gitea/evobackup/pipeline/head This commit looks good

This commit is contained in:
Ludovic Poujol 2022-08-19 12:23:53 +02:00
parent e7b7f50d9d
commit cff9d7382f
3 changed files with 68 additions and 0 deletions

View file

@ -0,0 +1,14 @@
# Munin plugins for bkctld
This is a work-in-progress.
Plugins can be installed in /etc/munin/plugins/bkctld_incs (as executables)
and be run as root :
~~~
# cat /etc/munin/plugin-conf.d/bkctld
[bkctld_*]
user root
~~~
Don't forget to `systemctl restart munin-node`

View file

@ -0,0 +1,25 @@
#!/bin/bash
#
#
case $1 in
config)
cat <<'UNLIKELY_EOF'
graph_title bkctld incs
graph_vlabel Number of incs
graph_args --lower-limit 0
graph_scale no
graph_category bkctld
graph_info The total number of available incs on the server
incs.info Number of backup incs available
incs.label incs available
UNLIKELY_EOF
exit 0;;
esac
printf "incs.value "
ls -ld /backup/incs/*/* | wc -l

View file

@ -0,0 +1,29 @@
#!/bin/bash
#
#
case $1 in
config)
cat <<'UNLIKELY_EOF'
graph_title bkctld jails
graph_vlabel Number of jails
graph_args --lower-limit 0
graph_scale no
graph_category bkctld
graph_info The total number of configured jails on the server
jails.info Number of backup jails configured
jails.label Jails Configured
jails_active.info Number of backup jails active (running)
jails_active.label Jails active
UNLIKELY_EOF
exit 0;;
esac
printf "jails.value "
bkctld list | wc -l
printf "jails_active.value "
bkctld status all | grep ON | wc -l