[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Read out processor load

K. R.

11/6/2007 3:07:00 PM

How can I read out the processor load with a rubyapp?
thanks for help...
--
Posted via http://www.ruby-....

4 Answers

Michael Linfield

11/6/2007 4:22:00 PM

0

K. R. wrote:
> How can I read out the processor load with a rubyapp?
> thanks for help...


perhaps?

http://www.noobkit.com/ruby-process...

- Mac
--
Posted via http://www.ruby-....

M. Edward (Ed) Borasky

11/7/2007 12:04:00 AM

0

Michael Linfield wrote:
> K. R. wrote:
>> How can I read out the processor load with a rubyapp?
>> thanks for help...
>
>
> perhaps?
>
> http://www.noobkit.com/ruby-process...
>
> - Mac

On Linux, do

a = `loadavg`

I can't help you with Windows, but I think there's something similar
with Macs.

Paul Brannan

11/7/2007 2:01:00 AM

0

On Wed, Nov 07, 2007 at 12:07:10AM +0900, K. R. wrote:
> How can I read out the processor load with a rubyapp?
> thanks for help...

On Linux you can read load from /proc/loadavg. See the other replies
for other ideas.

Paul


Alex Young

11/7/2007 10:07:00 AM

0

K. R. wrote:
> How can I read out the processor load with a rubyapp?
> thanks for help...
gem install sys-cpu, I think.

--
Alex