CPU meter

  • Follow


Good day, all

I would like to monitor the CPU load on multiple linux hosts from a
browser. Checked the JMETER from apache and it is too involved.

For example: 192.168.1.1 and 192.168.1.2 are the linux hosts

I would like to view the meter in the browser by typing http://192.168.1.1/cpumeter
or http://192.168.1.2

All I need are the CPU load and RAM.

Alternately, if "top" can be run on the browser...

Thanks


0
Reply soup_or_power (215) 4/29/2008 10:32:04 PM

soup_or_power@yahoo.com staggered into the Black Sun and said:
> I would like to monitor the CPU load on multiple linux hosts from a
> browser. Checked the JMETER from apache and it is too involved.

What was too involved about it?

> I would like to view the [CPU] meter in [my] browser by typing
> http://192.168.1.1/cpumeter or http://192.168.1.2 .  All I need are
> the CPU load and RAM.

You'd want to have these things somewhere that wasn't on the document
root for obvious reasons.  Install Apache, install PHP, then put
something like this in monitor.php :

<html><head><title>Stats for server 192.168.1.1</title></head>
<body>
<?php
$w=`w`;
$ram=`free -m`;
echo "<pre>$w</pre><hr/>";
echo "<pre>$ram/pre>";
?>
</body></html>

....modify to taste; you can make it look quite a bit fancier with some
easy messing around.  Then you'd go to http://192.168.1.1/monitor.php
and see the obvious things.

> [Alternatively], if "top" can be run on the browser...

What good would that do?  The machine running the browser is not the
machine you're interested in.  You may want to read up on how web
servers and web clients work before getting involved in this stuff.
Anyway, HTH,

-- 
   Outside of a dog, a book is a man's best friend.  Inside of a dog
   it's too dark to read.
  My blog and resume: http://crow202.dyndns.org:8080/wordpress/
Matt G|There is no Darkness in Eternity/But only Light too dim for us to see
0
Reply danceswithcrows (534) 4/30/2008 12:28:29 AM


Dances With Crows wrote:

> soup_or_power@yahoo.com staggered into the Black Sun and said:
>> I would like to monitor the CPU load on multiple linux hosts from a
>> browser. Checked the JMETER from apache and it is too involved.
> 
> What was too involved about it?
> 
>> I would like to view the [CPU] meter in [my] browser by typing
>> http://192.168.1.1/cpumeter or http://192.168.1.2 .  All I need are
>> the CPU load and RAM.
> 
> You'd want to have these things somewhere that wasn't on the document
> root for obvious reasons.  Install Apache, install PHP, then put
> something like this in monitor.php :
> 
> <html><head><title>Stats for server 192.168.1.1</title></head>
> <body>
> <?php
> $w=`w`;
> $ram=`free -m`;
> echo "<pre>$w</pre><hr/>";
> echo "<pre>$ram/pre>";
> ?>
> </body></html>
> 
> ...modify to taste; you can make it look quite a bit fancier with some
> easy messing around.  Then you'd go to http://192.168.1.1/monitor.php
> and see the obvious things.
> 
>> [Alternatively], if "top" can be run on the browser...
> 
> What good would that do?  The machine running the browser is not the
> machine you're interested in.  You may want to read up on how web
> servers and web clients work before getting involved in this stuff.
> Anyway, HTH,

There is always "gkrellm" ! //gkrellm.net

-- 
Best Regards:
                     Baron.
0
Reply baron.nospam (7) 4/30/2008 7:18:24 PM

Baron <baron.nospam@linuxmainiac.nospam.net> writes:

>Dances With Crows wrote:

>> soup_or_power@yahoo.com staggered into the Black Sun and said:
>>> I would like to monitor the CPU load on multiple linux hosts from a
>>> browser. Checked the JMETER from apache and it is too involved.
>> 
>> What was too involved about it?
>> 
>>> I would like to view the [CPU] meter in [my] browser by typing
>>> http://192.168.1.1/cpumeter or http://192.168.1.2 .  All I need are
>>> the CPU load and RAM.

Why on the browser?
Use gkrellm and have it display on your local desktop (Ie ssh to the remote
machine and run gkrellm. It will display on your desktop) If you just want
the cpu meter, set it up to display just the cpu meter.



>There is always "gkrellm" ! //gkrellm.net

Agreed
0
Reply unruh-spam (2581) 4/30/2008 8:07:25 PM

"s" == soup_or_po...@yahoo.com <soup_or_po...@yahoo.com>:
s> I would like to monitor the CPU load on multiple linux hosts from a
s> browser. Checked the JMETER from apache and it is too involved.

Running

watch \
  '{ echo "<html><pre>";top -b -n 1|head -9;echo "</html></pre>"; } \
      > cpu_load.html'

on each computer, will give you a nice CPU load webpage,
automatically updated every 2 seconds...

0
Reply anonymous195 (210) 5/13/2008 3:40:04 AM

In comp.os.linux.misc Unruh <unruh-spam@physics.ubc.ca>:
> Baron <baron.nospam@linuxmainiac.nospam.net> writes:
>>Dances With Crows wrote:

>>> soup_or_power@yahoo.com staggered into the Black Sun and said:
>>>> I would like to monitor the CPU load on multiple linux hosts from a
>>>> browser. Checked the JMETER from apache and it is too involved.

>>> What was too involved about it?

>>>> I would like to view the [CPU] meter in [my] browser by typing
>>>> http://192.168.1.1/cpumeter or http://192.168.1.2 .  All I need are
>>>> the CPU load and RAM.

> Why on the browser?

The OP might be restricted to running a browser + doze? ;-)

> Use gkrellm and have it display on your local desktop (Ie ssh to the remote
> machine and run gkrellm. It will display on your desktop) If you just want
> the cpu meter, set it up to display just the cpu meter.

Indeed, or use something even simpler like "xosview", "ssh -CX
remote_host" and "xosview &" should just cut it. Using "xosview
+net +disk" and alike shows even more real time stats.

-- 
Michael Heiming (X-PGP-Sig > GPG-Key ID: EDD27B94)
mail: echo zvpunry@urvzvat.qr | perl -pe 'y/a-z/n-za-m/'
#bofh excuse 109: The electricity substation in the car park
blew up.
0
Reply USENET22 (5462) 5/13/2008 3:18:04 PM

5 Replies
77 Views

(page loaded in 0.081 seconds)

Similiar Articles:













7/15/2012 8:54:36 PM


Reply: