[munin/innd_*] Connexions crans/exterieur, tabs
darcs-hash:20090330145223-ddb99-e5be7f6978efc83096afa15f8976432d36175c77.gz
This commit is contained in:
parent
af958a23d6
commit
26c25d26f7
2 changed files with 30 additions and 14 deletions
|
@ -23,20 +23,36 @@
|
|||
|
||||
## Configuration
|
||||
if [ "$1" = "config" ]; then
|
||||
echo 'host_name news.crans.org'
|
||||
echo 'graph_title Connexions par minute'
|
||||
echo "graph_args --base 1000 --lower-limit 0"
|
||||
echo "graph_vlabel connexions"
|
||||
echo 'host_name news.crans.org'
|
||||
echo 'graph_title Connexions par minute'
|
||||
echo "graph_args --base 1000 --lower-limit 0"
|
||||
echo "graph_vlabel connexions"
|
||||
echo "graph_period minute"
|
||||
echo "graph_category News"
|
||||
echo "graph_info Affiche le nombre de connexions par minute à InnD."
|
||||
echo "connects.label connexions"
|
||||
echo "connects.label Total"
|
||||
echo "connects.type DERIVE"
|
||||
exit 0
|
||||
echo "crans.label crans"
|
||||
echo "crans.type DERIVE"
|
||||
echo "crans.draw AREA"
|
||||
echo "ext.label exterieur"
|
||||
echo "ext.type DERIVE"
|
||||
echo "ext.draw STACK"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
TMPFILE=/tmp/munin_innd_connects_grep
|
||||
|
||||
## Sortie
|
||||
echo -n "connects.value "
|
||||
# Bon, ça fera une valeur négative (ramenée à 0 par le --lower-limit)
|
||||
# à chaque rotation des logs, mais bon ...
|
||||
egrep "connect$" /var/log/news/news.notice | wc -l
|
||||
egrep "connect$" /var/log/news/news.notice > $TMPFILE
|
||||
|
||||
echo -n "connects.value "
|
||||
cat $TMPFILE | wc -l
|
||||
echo -n "crans.value "
|
||||
cat $TMPFILE | egrep '\.crans\.org \(138\.231.*\) connect$' | wc -l
|
||||
echo -n "ext.value "
|
||||
cat $TMPFILE | egrep -v '\.crans\.org \(138\.231.*\) connect$' | wc -l
|
||||
|
||||
rm -f $TMPFILE &> /dev/null
|
||||
|
|
|
@ -23,14 +23,14 @@
|
|||
|
||||
## Configuration
|
||||
if [ "$1" = "config" ]; then
|
||||
echo 'host_name news.crans.org'
|
||||
echo 'graph_title Posts de moins de 24h'
|
||||
echo "graph_args --base 1000 --lower-limit 0"
|
||||
echo "graph_vlabel posts"
|
||||
echo 'host_name news.crans.org'
|
||||
echo 'graph_title Posts de moins de 24h'
|
||||
echo "graph_args --base 1000 --lower-limit 0"
|
||||
echo "graph_vlabel posts"
|
||||
echo "graph_category News"
|
||||
echo "graph_info Affiche le nombre de posts de moins de 24h."
|
||||
echo "posts.label posts"
|
||||
exit 0
|
||||
echo "posts.label posts"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
## Sortie
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue