[mrtg] problems with APC ups & mrtg

canderso at TTACS.TTU.EDU canderso at TTACS.TTU.EDU
Tue Dec 18 19:34:20 MET 2001

Hello, I've been using mrtg to graph my (Cisco) router and switch traffic
for over a year. I had no problems configuring the software after having
read the documentation. To this day, mrtg is still graphing my router and
switch traffic without any problems.

However, I have been trying without success to get mrtg to graph my (APC)
UPS stats. I re-read the docs and faqs and continue to run into the same

I would like to graph the voltage input. I have no problems getting this
data via snmpwalk:

# snmpwalk public .
enterprises.318. = Gauge32: 124

However, when I create a mrtg.cfg with the same oid, I get the following
errors when running mrtg:

# ./usr/local/mrtg-2/bin/mrtg /usr/local/mrtg-2/cfg/mrtg.cfg
SNMP Error:
Received SNMP response with error code
  error status: noSuchName
  index 1 (OID:
SNMPv1_Session (remote host: "" [].161)
                  community: "public"
                 request ID: 1011030818
                 PDU bufsize: 8000 bytes
                    timeout: 2s
                    retries: 5
                    backoff: 1)
 at /usr/local/mrtg-2/bin/../lib/mrtg2/SNMP_util.pm line 450
SNMPGET Problem for sysName on public at
 at ./usr/local/mrtg-2/bin/mrtg line 1485
WARNING: Expected a number but got ''
WARNING: Expected a number but got ''

I trimmed down my mrtg.cfg to almost nothing to try to isolate the
problem. Here is my full mrtg.cfg:

# cat mrtg.cfg
WorkDir: /usr/local/apache/htdocs/admin/mrtg
Options[_]: bits,growright
#Voltage In
Target[]: at
MaxBytes[]: 150
Title[]: SmartUPS 3000 RM
PageTop[]: <H2>Input Voltage</H2>
Options[]: gauge, nopercent, absolute
Unscaled[]: dwmy
XSize[]: 380
YSize[]: 175
YLegend[]: Input Voltage
ShortLegend[]: Volts
Legend1[]: Input Voltage
Legend2[]: Input Voltage

Perhaps I am missing something quite simple, I don't know. All I know is
it isn't working, I get the above errors and the log fills up with the
number "1". The resultant HTML claims "1 Volt" current and average.

Thank you in advance for any help.

Colin Anderson

Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi

More information about the mrtg mailing list