[mrtg] HELP! -- Expected a Number for 'out' but nothing

Kirk Waingrow wkrik at yahoo.com
Thu Nov 22 20:13:52 CET 2007


I'm running mrtg and get the following warning errors below:

$ /usr/local/mrtg-2/bin/mrtg /home/mrtg/cfg/mrtg.cfg
2007-11-22 10:53:57: WARNING: Problem with External get '/tmp/foo':
   Expected a Number for 'out' but nothing'

2007-11-22 10:53:57: ERROR: Target[portal.aphroland.org.uptime][_OUT_] ' $target->[0]{$mod
e} ' did not eval into defined data
   Admin - System Engerring Server (811:1144-A.1)!  


It seems that any type of script I call (sh, bash, perl) from the mrtg.cfg file yeilds the above error. 
Target[portal.saphroland.org.uptime]: `/usr/local/bin/test.sh`

If I just put a number in the Target field it works fine:
Target[portal.saphroland.org.uptime]: "555"

The script(s):

/usr/local/bin/test.sh
#! /bin/bash
/usr/bin/uptime | awk '{ print $3 }'

or 

/usr/local/bin/test.sh

#! /bin/bash
/bin/date +%m

My mrtg.cfg files looks like:
------------------------------------------------------------------------------------------------------
EnableIPv6: no
WorkDir: /httpd/html/mrtg
Options[_]: bits,growright

Target[portal.saphroland.org.uptime]: `/usr/local/bin/test.sh`
Xsize[portal.saphroland.org.uptime]: 600
Ysize[portal.saphroland.org.uptime]: 200
Ytics[portal.saphroland.org.uptime]: 10
Options[portal.saphroland.org.uptime]: nopercent,gauge
Supress[portal.saphroland.org.uptime]: dw
Title[portal.saphroland.org.uptime]: (portal.saphroland.org) Uptime - in days
PageTop[portal.saphroland.org.uptime]: <h1>(portal.saphroland.org) Uptime - in days</h1>
Background[portal.saphroland.org.uptime]: #738AA6
MaxBytes[portal.saphroland.org.uptime]: 1000
YLegend[portal.saphroland.org.uptime]: days
ShortLegend[portal.saphroland.org.uptime]: days&nbsp;
LegendI[portal.saphroland.org.uptime]: &nbsp;Uptime:&nbsp;
LegendO[portal.saphroland.org.uptime]:
Legend1[portal.saphroland.org.uptime]: Uptime
Legend2[portal.saphroland.org.uptime]:


Any help is greatly appreciated! :)

-wk



      ____________________________________________________________________________________
Be a better sports nut!  Let your teams follow you 
with Yahoo Mobile. Try it now.  http://mobile.yahoo.com/sports;_ylt=At9_qDKvtAbMuh1G1SQtBI7ntAcJ
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/mrtg/attachments/20071122/c6e976c5/attachment.html 


More information about the mrtg mailing list