Leandro, When I create the target in mrtg.cfg using these parameters (the minimum it will accept):
### Interface 4 >> Get the uptime text for a separate file. # #Target[apollo_uptime]: 1:[EMAIL PROTECTED]: #Suppress[apollo_uptime]: ymwd #Title[apollo_uptime]: #PageTop[apollo_uptime]: #MaxBytes[apollo_uptime]: 10 then what I get is the complete webpage below: > >---------- >The statistics were last updated Friday, 17 October 2003 at 18:13, >at which time 'apollo.paiz.org' had been up for 1 day, 7:27:05. > >---------- > >GREEN ### Incoming Traffic in Bits per Second >BLUE ### Outgoing Traffic in Bits per Second > > >---------- > ><http://people.ee.ethz.ch/~oetiker/webtools/mrtg/> >MRTG > <http://people.ee.ethz.ch/~oetiker/webtools/mrtg/> >[] > <http://people.ee.ethz.ch/~oetiker/webtools/mrtg/> >Multi Router Traffic Grapher > >version 2.9.17 <http://people.ee.ethz.ch/~oetiker/>Tobias Oetiker ><mailto:[EMAIL PROTECTED]><[EMAIL PROTECTED]> >and <http://www.bungi.com/>Dave Rand <mailto:[EMAIL PROTECTED]><[EMAIL >PROTECTED]> Can you think of a way to eliminate this and keep just the text about the update time and uptime? I have found that the code to generate this is here in /usr/bin/mrtg: [EMAIL PROTECTED] rpaiz]$ grep -C 15 "statistics were last updated" /usr/bin/mrtg print HTML <<"TEXT"; $$rcfg{'addhead'}{$router} </HEAD> $$rcfg{bodytag}{$router} $$rcfg{'pagetop'}{$router}<BR> <HR> TEXT if (defined $$rcfg{'timezone'}{$router}){ print HTML &$LOC("The statistics were last updated <B>$Today $$rcfg{'timezone'}{$router}</B>"); } else { print HTML &$LOC("The statistics were last updated <B>$Today</B>"); } if ($uptime && ! $$rcfg{options}{noinfo}{$router}) { print HTML ",<BR>\n". &$LOC("at which time $namestring had been up for <B>$uptime</B>."). "\n<!-- End Head -->"; } Is there a way I can add a piece of simple code which will open (and overwrite if it previously existed) $WORKDIR/apollo_uptime.html and just add the statistics/uptime text, then close it? I am afraid my perl abilities _were_ born yesterday, and I can barely understand pieces of this let alone modify it. -- Rodolfo J. Paiz [EMAIL PROTECTED] -- Unsubscribe mailto:[EMAIL PROTECTED] 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
