[mrtg] Re: cpu load

Andre Kuellenberg meiner at wtal.de
Sun Aug 1 20:34:04 MEST 1999


Hello!

Everything is working perfectly now! Thank you. (You also get nice graphs, when
you display the temperature of processor!!)
I've got still one question: Why do you output four numbers when only one value
should be displayed?
Regards
	Andre

Am Thu, 29 Jul 1999 schrieb Glenn Forbes Fleming Larratt:
> 1.On the target machine foo (if it's Solaris; other UNIXen may require
> tweaking, don't know NT), install "loadavg": 
> 
> #!/usr/local/bin/perl
> @w = `/usr/ucb/w`;
> while(!$w[0] =~ /\s+load average:\s+(\S+),\s/)
> { shift(@w) ; }
> $w[0] =~ /\s+load average:\s+(\S+),\s/;
> printf "%d\n0\n0\n0\n",100*$1;
> 
> 2.Set up MRTG host to be able to no-password ssh into foo.
> 
> 3.target[foo.cpu] `{fullpath}/ssh foo {fullpath}/loadavg`
> 
> 4.(if target foo is occasionally down), on MRTG host (same caveats
> regarding Solaris above), install "sshq":
> 
> #!/usr/local/bin/perl
> if(system("/usr/sbin/ping $ARGV[0] > /dev/null"))
> { printf "\n\n\n%s appears to be down\n",$ARGV[0]; }
> else
> { system("/usr/local/bin/ssh @ARGV"); }
> 
> , then substitute sshq for ssh in #3 above.

--
* To unsubscribe from the mrtg mailing list, send a message with the
  subject: unsubscribe to mrtg-request at list.ee.ethz.ch
* The mailing list archive is at http://www.ee.ethz.ch/~slist/mrtg


More information about the mrtg mailing list