[mrtg] Router uptime
G.Schlupkothen
g.schlupkothen at web-form-art.de
Wed Aug 15 17:22:47 CEST 2007
Stefano, I think Tolga only want to print the RouterUptime in the headline
of the site.
Therefore your script is not correct.
Regards
Guido
| -----Ursprüngliche Nachricht-----
| Von: mrtg-bounces at lists.oetiker.ch
| [mailto:mrtg-bounces at lists.oetiker.ch] Im Auftrag von Stefano Giraldo
| Gesendet: Mittwoch, 15. August 2007 14:40
| An: Schlupkothen, Guido; mrtg at lists.oetiker.ch
| Betreff: Re: [mrtg] Router uptime
|
| Hi,
| some routers release the uptime value in hours or worse in
| seconds, so your
| graphs could be a little bit wrong... ;)
|
| So, I wrote these scripts to get the uptime, it use the
| uptime value taken
| from a graph page (at which time <router> had been up for XX days).
|
| Retriving script
|
| #!/bin/bash
| UP=$(fgrep time /your_path/graph_page.html | fgrep day | awk
| '{print $9}' |
| sed 's/<B>//g')
| if [ -z $UP ]
| then
| echo 0
| echo 0
| echo
| echo
| else
| echo "$UP"
| echo "$UP"
| echo
| echo
| fi
|
| Graph generator script
|
| Target[gsr1_up]: `/var/STATS/rrd_cfg/sys/uptime/gsr1_up.sh`
| SetEnv[gsr1_up]: MRTG_INT_IP="62.196.4.1" MRTG_INT_DESCR="UPTIME"
| MaxBytes[gsr1_up]: 125000000
| Title[gsr1_up]: Uptime for gix-gsr-gw1.ita.tip.net.
| PageTop[gsr1_up]: <H1>Uptime for gix-gsr-gw1.ita.tip.net.</H1>
| Options[gsr1_up]: nopercent,growright,gauge,noinfo
| YLegend[gsr1_up]: Days
| ShortLegend[gsr1_up]: Days
| LegendI[gsr1_up]: Uptime:
| LegendO[gsr1_up]:
| Legend1[gsr1_up]: Uptime
|
| Here the result:
| http://swirl.netscalibur.it/rrd/gsr1_sys.html
|
| Bye.
|
| ----
| Stefano Giraldo
|
| Network Operation Center
| Netscalibur Italia S.p.A.
| Via Caldera, 21 Building E - 20153 Milan Italy
| ----
| ----- Original Message -----
| From: "Schlupkothen, Guido" <Guido.Schlupkothen at thyssenkrupp.com>
| To: <mrtg at lists.oetiker.ch>
| Sent: Wednesday, August 15, 2007 7:55 AM
| Subject: Re: [mrtg] Router uptime
|
|
|
| Hi Tolga,
|
| To solve your problem you need the SNMP-command
| getit at xxx.xxx.xxx.xxx, where
| the x´s are the IP-Address of your server i.e.
| This in combination with the RouterUptime parameter you will
| get what you
| want.
|
| Regards
| Guido
|
|
| ________________________________
|
| Von: mrtg-bounces at lists.oetiker.ch
| [mailto:mrtg-bounces at lists.oetiker.ch] Im
| Auftrag von Tolga
| Gesendet: Dienstag, 14. August 2007 15:42
| An: Wes Hegge
| Cc: mrtg at lists.oetiker.ch
| Betreff: Re: [mrtg] Router uptime
|
|
| When I click on an interface graph, I wish to see something like The
| statistics were last updated Tuesday, 14 August 2007 at
| 16:37, at which time
| 'USRobotics' had been up for <uptimehere>
|
| Wes Hegge wrote:
|
| Not exactly sure what you are looking for here.
|
| I understand router uptime but what is it you are trying to
| graph? That the
| router is up at the time MRTG checked?
|
| What is the RouterUptime parameter passing? Do you wish to
| graph that
| value?
|
| Sorry need so more info.
|
| Wes
|
|
| On 8/14/07, Tolga <tolga at ozses.net> wrote:
|
| Hi,
|
| I'm new to this list so please bear with me. How can I get MRTG to
| display router uptime? I got a page at http://mrtg.kunduz.org but it
| never displays the uptime. Googling, I found out about a RouterUptime
| parameter, which I thought would do the job, but it didn't. Your help
| with this would be appreciated.
|
| Regards,
|
| --
| Stay with *nix :)
|
| _______________________________________________
| mrtg mailing list
| mrtg at lists.oetiker.ch
| https://lists.oetiker.ch/cgi-bin/listinfo/mrtg
|
|
|
|
|
| --
| Wes Hegge
|
| - If the phone doesn'1 ring. It is me.
| -- Jimmy Buffet
|
|
| --
| Stay with *nix :)
|
| _______________________________________________
| mrtg mailing list
| mrtg at lists.oetiker.ch
| https://lists.oetiker.ch/cgi-bin/listinfo/mrtg
|
| _______________________________________________
| mrtg mailing list
| mrtg at lists.oetiker.ch
| https://lists.oetiker.ch/cgi-bin/listinfo/mrtg
|
More information about the mrtg
mailing list