Page 1 of 1

NagiosXI mrtg errors?!

Posted: Tue Jan 14, 2020 12:16 pm
by xpertech
when using command(LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg) to check network switch/route bindwidth monitoring, there're a lot of errors?! (see attachment mrtg.out)

what could be the problems? (configure? device? MRTG?)

Re: NagiosXI mrtg errors?!

Posted: Tue Jan 14, 2020 6:59 pm
by Box293
It has to do with specific ports that the mrtg config is having issues with. Your error log shows double the errors because one error is the stderr from the snmp command and the second error is the normal mrtg error.

For example:

Code: Select all

SNMPGET Problem for ifInOctets.18 ifOutOctets.18 on [email protected]:161::::2:v4only: Received noSuchName(2) error-status at error-index 1 at /usr/bin/../lib/mrtg2/Net_SNMP_util.pm line 594.
        Net_SNMP_util::snmpget('[email protected]:161::::2:v4only', 'HASH(0x2fa7938)', 'ifInOctets.18', 'ifOutOctets.18') called at /usr/bin/mrtg line 2330
        main::getsnmparg('HASH(0x28a62e8)', 'HASH(0x2c6c5c8)', 'HASH(0x2791300)', 'HASH(0x2c36710)') called at /usr/bin/mrtg line 2510
        main::readtargets('HASH(0x28a62e8)', 'ARRAY(0x292a718)', 'HASH(0x2791300)') called at /usr/bin/mrtg line 403
        main::main called at /usr/bin/mrtg line 143

2020-01-14 10:36:03: ERROR: Target[twtpewadmdn01p.hq.intra.acer.com_18][_IN_] ' $target->[14]{$mode} ' did not eval into defined data
These two errors are both referencing port 18 for twtpewadmdn01p.hq.intra.acer.com.

There is a KB article that explains how to mute the errors simply by commenting these ports out of the config file. This is assuming you are not needing to monitor these ports.
https://support.nagios.com/kb/article/n ... s-510.html

From memory this config file will be /etc/mrtg/conf.d/twtpewadmdn01p.hq.intra.acer.com.cfg

If these are actual ports that you require to monitor then let us know and we'll troubleshoot further. Otherwise comment out the ports in the config and run the command again to see if the errors disappear.