retrieve cpu memory and bandwidth programmatically with java linux

A

anonym0us

Hi, I have been googling for this. I found some article about creating
JNI to use native system library to access those information, but the
examples are for Windows and Solaris only, and I am looking for linux
version, Ubuntu 8.04 in particular. I am using java 6 for this. My
program will need to display real time CPU memory and bandwidth of the
system. I thought of parsing input from top but there must be better
way than this.
Thanks for any help there..

Regards,
Eric
 
M

Mark Space

anonym0us said:
Hi, I have been googling for this. I found some article about creating
JNI to use native system library to access those information, but the
examples are for Windows and Solaris only, and I am looking for linux
version, Ubuntu 8.04 in particular. I am using java 6 for this. My
program will need to display real time CPU memory and bandwidth of the
system. I thought of parsing input from top but there must be better
way than this.
Thanks for any help there..

Regards,
Eric

It's been a while since I messed around with Linux, but I think the
/proc files system has what you need. I don't think this has all the
details you need, but try starting here:

<http://www.redhat.com/docs/manuals/linux/RHL-9-Manual/ref-guide/ch-proc.html>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,534
Members
45,007
Latest member
obedient dusk

Latest Threads

Top