Add some comments to help use munin plugin, add over limit detection

This commit is contained in:
Rodolphe Quiédeville
2014-01-14 23:50:22 +01:00
committed by Sarah Hoffmann
parent 10f3a4df23
commit 014f19ec68

View File

@@ -5,12 +5,26 @@
# Can be configured through libpq environment variables, for example # Can be configured through libpq environment variables, for example
# PGUSER, PGDATABASE, etc. See man page of psql for more information # PGUSER, PGDATABASE, etc. See man page of psql for more information
# #
# To configure munin for a default installation, add these lines to
# the file /etc/munin/plugin-conf.d/munin-node or in any file in the
# directory /etc/munin/plugin-conf.d/
#
# [nominatim_*]
# user www-data
# env.PGUSER www-data
# env.PGPORT 5432
# env.PGDATABASE nominatim
# env.age_warning 21600
# env.age_critical 86400
# Parameters: # Parameters:
# #
# config (required) # config (required)
# autoconf (optional - used by munin-config) # autoconf (optional - used by munin-config)
# #
. $MUNIN_LIBDIR/plugins/plugin.sh
if [ "$1" = "config" ]; then if [ "$1" = "config" ]; then
echo 'graph_title Data import lag' echo 'graph_title Data import lag'
@@ -20,6 +34,8 @@ if [ "$1" = "config" ]; then
echo 'age.label DB import age' echo 'age.label DB import age'
echo 'age.type GAUGE' echo 'age.type GAUGE'
echo 'age.cdef age,60,/' echo 'age.cdef age,60,/'
print_warning age
print_critical age
exit 0 exit 0
fi fi