# router interface sub-tree
#
# This is where we collect stats on the interfaces of our routers
# (i.e. Octets, Packets, Errors).  These are kept seperate from the
# routers themselves since they have quite different configuration needs.

Target	--default--
	inst		=	map(interface-name)
	# snmp-community	=	secret
	snmp-host	=	%router%
	target-type	=	standard-interface

datasource	--default--
	rrd-ds-type	=	COUNTER
	rrd-heartbeat	=	900
	rrd-min		=	undef
	rrd-max		=	undef

# ifInOctets and ifOutOctets come from above, since they
# are used by switch-ports as well

datasource ifSpeed
	ds-source	=	snmp://%snmp%/ifSpeed.%inst%
	rrd-ds-type	=	GAUGE

datasource ifInErrors
	ds-source	=	snmp://%snmp%/ifInErrors.%inst%

datasource ifOutErrors
	ds-source	=	snmp://%snmp%/ifOutErrors.%inst%

datasource ifInUcastPackets
	ds-source	=	snmp://%snmp%/ifInUcastPkts.%inst%

datasource ifOutUcastPackets
	ds-source	=	snmp://%snmp%/ifOutUcastPkts.%inst%

targetType  standard-interface
	ds	=	"ifInOctets, ifOutOctets, ifInErrors, ifInDiscards,
				ifOutErrors, ifInUcastPackets, 
				ifOutUcastPackets, ifInNUcastPackets,
				ifOutNUcastPackets, ifSpeed"
	view	=	"Octets: ifInOctets ifOutOctets,
		UcastPackets: ifInUcastPackets ifOutUcastPackets,
		Errors: ifInErrors ifOutErrors"

targetType  sub-interface
	ds	=	"ifInOctets, ifOutOctets"
    view		=	"Octets: ifInOctets ifOutOctets"

# likewise, graph params for ifInOctets and ifOutOctets come from above



graph   ifInDiscards
    color       =   red
    y-axis      =   "packets per second"
    units       =   "pkt/sec"
    legend      =   "Average num Packets Discarded"
 
graph   ifInNUcastPackets
    color       =   green
    y-axis      =   "packets per second"
    units       =   "pkt/sec"
    legend      =   "Average num Packets In"
 
graph   ifInUcastPackets
    color       =   dark-green
    draw-as     =   AREA
    y-axis      =   "packets per second"
    units       =   "pkt/sec"
    legend      =   "Average num Packets In"
 
graph   ifOutNUcastPackets
    color       =   skyblue
    y-axis      =   "packets per second"
    units       =   "pkt/sec"
    legend      =   "Average num Packets Out"
 
graph   ifOutUcastPackets
    color       =   blue
    y-axis      =   "packets per second"
    units       =   "pkt/sec"
    legend      =   "Average num Packets Out"
 
graph   ifInErrors
    color       =   dark-green
    draw-as     =   AREA
    y-axis      =   "errors per second"
    units       =   "err/sec"
    legend      =   "Average Errors In"

graph   ifOutErrors
    color       =   blue
    y-axis      =   "errors per second"
    legend      =   "Average Errors Out"
    units       =   "err/sec"