Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][tlug] Re: MRTG without SNMP: how-to?
- Date: Wed, 9 Oct 2002 08:13:22 +0200
- From: Tobias Diedrich <td@example.com>
- Subject: [tlug] Re: MRTG without SNMP: how-to?
- References: <F47ybizizjk9o1P0q5G00003161@example.com>
- User-agent: Mutt/1.4i
Jean-Christian Imbeault wrote: > Does anyone remember that posting, or better yet can the original poster > (Tobias maybe?) explain again how to get network usage stats without using > SNMP? /etc/mrtg.cfg: |###################################################################### |# Multi Router Traffic Grapher -- Sample Configuration File |###################################################################### |# This file is for use with mrtg-2.5.4c | |# Global configuration |WorkDir: /var/www/router/mrtg |WriteExpires: Yes | |#Title[^]: Traffic Analysis for | |Title[ppp0]: router ADSL connection Traffic |PageTop[ppp0]: <H1>Traffic analysis for ppp0</H1> |Target[ppp0]: `/usr/local/bin/routerstats` |MaxBytes1[ppp0]: 96000 |MaxBytes2[ppp0]: 16000 |WithPeak[ppp0]: wmy | |Title[temp]: CPU and GPU Temperature |PageTop[temp]: <H1>CPU and GPU temperature</H1> |Target[temp]: `/usr/local/bin/routertemp` |MaxBytes[temp]: 100 |WithPeak[temp]: wmy |Options[temp]: gauge |YLegend[temp]: Temperature in degree Celsius |ShortLegend[temp]: °C |Legend1[temp]: CPU Temperature |Legend2[temp]: GPU Temperature |Legend3[temp]: Maximal 5 Minute CPU Temperature |Legend4[temp]: Maximal 5 Minute GPU Temperature |LegendI[temp]: CPU: |LegendO[temp]: GPU: /usr/local/bin/routerstats: |#!/bin/sh |PATH=/bin:/usr/bin:/usr/local/bin |IN=`cat /proc/net/dev | awk 'index($1,"ppp0") != 0 { print substr($0,8) }' | awk '{ print $1}'` |OUT=`cat /proc/net/dev | awk 'index($1,"ppp0") != 0 { print substr($0,8) }' | awk '{ print $9}'` |if [ "$IN" = "" ]; then IN="0"; fi |if [ "$OUT" = "" ]; then OUT="0"; fi |echo "$IN" |echo "$OUT" |uptime |hostname -- Tobias PGP: 0x9AC7E0BC This mail is made of 100% recycled bits Now playing: hayashibaramegumi: bertemu 06 - matsuriutaAttachment: pgp00022.pgp
Description: PGP signature
- References:
- [tlug] MRTG without SNMP: how-to?
- From: Jean-Christian Imbeault
Home | Main Index | Thread Index
- Prev by Date: [tlug] Best online comp shops??
- Next by Date: [tlug] scp or mail w/ uuencode
- Previous by thread: [tlug] MRTG without SNMP: how-to?
- Next by thread: List Archives (was: Re: [tlug] MRTG without SNMP: how-to?)
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links