LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-02-2003, 01:02 AM   #1
Infynite
LQ Newbie
 
Registered: Sep 2003
Posts: 2

Rep: Reputation: 0
Mrtg


I've setup MRTG on RH9 and it's been working well to monitor the traffic usage on my router.

I want to set it up to monitor other things like CPU & disk space usage on the local machine. For some reason I can't get it to graph the output from a script.

To take my other scripts out of the equation I used a simple perl script to output 4 values for mrtg.

#!/usr/bin/perl
print "5\n";
print "4\n";
print "Uptime\n"
print "Server\n"

I then setup mrtg to us this script as the target:
Target[test]: `/etc/mrtg/scripts/test
MaxBytes[test]: 100
Title[test]: test
PageTop[test]: test


In the html page that mrtg creates, the "Uptime" & "Server" values are there but the other values are all zero.

Any help would be appreciated.

Last edited by Infynite; 10-02-2003 at 01:03 AM.
 
Old 10-02-2003, 01:14 AM   #2
td_miles
Member
 
Registered: Sep 2003
Location: Australia
Distribution: RedHat
Posts: 51

Rep: Reputation: 15
I think you need to set the "guage" option. By default MRTG is to meaure the increment between an ever increasing counter. In the context of a network interface this works as follows:

time0: 1000000 bytes
time(0+5): 1500000 bytes

MRTG takes the difference between the two (500000 bytes) and then says that there was 500000 bytes transferred in that 5 minute interval.

So in what you have done it is seeing:

time0: 5
time(0+5): 5

so it takes the difference between the two, which is ZERO.

read the doc at:
http://people.ee.ethz.ch/~oetiker/we...reference.html

regards,
Tony.
 
Old 10-02-2003, 01:40 AM   #3
Infynite
LQ Newbie
 
Registered: Sep 2003
Posts: 2

Original Poster
Rep: Reputation: 0
Thanks for the reply, I have tried adding:

Options[test]: gauge

and I have tried changing the values in the script between running mrtg. I am still having no luck, the values are still zero.
 
Old 10-02-2003, 01:49 AM   #4
td_miles
Member
 
Registered: Sep 2003
Location: Australia
Distribution: RedHat
Posts: 51

Rep: Reputation: 15
suggest looking through some of the examples. Plenty of people have already done exactly what you are attempting.

http://www.geek.net.au/mrtg.html

http://mrtg.xidus.net/info.shtml

http://people.ee.ethz.ch/~oetiker/we...rtg/links.html


I only use MRTG to monitor/graph network links (on routers), so unfortunately I can't really be any more help than this.


regards,
Tony.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
rrd mrtg & mrtg-rrd.cgi ducati620 Linux - Newbie 0 06-03-2004 07:29 PM
can I use mrtg for this? ziggie216 Linux - Software 1 04-14-2004 01:34 PM
What do I need for MRTG? ivanatora Linux - Software 3 02-28-2004 04:22 PM
mrtg jcb_dreamvsat Linux - Networking 2 11-02-2003 11:59 AM
mrtg cristi1979 Linux - Networking 0 06-24-2003 03:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 06:53 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration