Poszedłem jeszcze inną drogą. Ale nadal jest coś nie tak. Niestety nie znam na tyle snmp, żeby stwierdzić gdzie w składni jest błąd.
Dla monitorowania ruchu poszczególnego hosta w sieci utworzyłem sobie taki wpis w configu mrtg:
Target[localhost_4]: /10.0.0.213:public@localhost:
SetEnv[localhost_4]: MRTG_INT_IP="10.0.0.213" MRTG_INT_DESCR="eth1"
MaxBytes[localhost_4]: 512000
Title[localhost_4]: Traffic Analysis for eth0 -- Alpha
Options[localhost_4]: growright, integer, nobanner, noborder
PageTop[localhost_4]: <h1>Traffic Analysis eth0 -- Alpha</h1>
YLegend[localhost_4]: Transfer
Niestety mrtg nadal sypie błędami:
Alpha:/etc/mrtg/bin# env LANG=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg
2010-03-17 10:46:18: WARNING: Could not match host:'public@localhost:' ref:'Ip' key:'10.0.0.213'
2010-03-17 10:46:18: ERROR: Target[localhost_4][_IN_] ' $target->[7]{$mode} ' did not eval into defined data
2010-03-17 10:46:18: ERROR: Target[localhost_4][_OUT_] ' $target->[7]{$mode} ' did not eval into defined data