Projet

Général

Profil

Paste
Télécharger au format
Statistiques
| Branche: | Révision:

root / plugins / ftp / proftpd @ 6a28f5a2

Historique | Voir | Annoter | Télécharger (617 octets)

1 6a28f5a2 Stig Sandbeck Mathisen
#! /bin/sh
2
# configuration :
3
#
4
# env.LOGFILE /var/log/proftpd/proftpd.log
5
6
if [ "$1" = 'config' ]; then
7
        echo "graph_args --base 1000 -l 0"
8
        echo "graph_title Serveur FTP"
9
        echo "graph_category Ftp"
10
        echo "graph_vlabel Stats Proftpd"
11
        echo "succes.label Login succes"
12
        echo "succes.draw AREA"
13
        echo "failed.label Login failed"
14
        echo "failed.draw AREA"
15
fi
16
17
LOGFILE=${LOGFILE:-"/var/log/proftpd/proftpd.log"}
18
19
succes=$(grep -c "successful" "$LOGFILE" )
20
failed=$(grep -c "Login failed" "$LOGFILE" )
21
22
echo "succes.value $succes"
23
echo "failed.value $failed"
24
25
exit 0