Added interface plugin back, rewritten.

This commit is contained in:
Matthew Connelly 2015-02-20 04:08:55 +00:00
parent 4d4f65d1b0
commit 031406e82b
1 changed files with 23 additions and 0 deletions

23
plugins.d/if Executable file
View File

@ -0,0 +1,23 @@
#!/bin/sh
# this plugin was rewritten to avoid licensing conflicts.
if [ "$1" == "config" ];then
echo "graph_order up down
graph_title $2 traffic
graph_args --base 1000
graph_vlabel bps in/out
graph_category network
down.label bps
down.type DERIVE
down.min 0
down.negative up
down.cdef down,8,*
up.label bps
up.type DERIVE
up.min 0
up.graph no
up.cdef up,8,*"
exit 0
fi
/bin/grep "\b$1:" /proc/net/dev|awk '{print "down.value "$2"\nup.value "$10}'