views:

371

answers:

6

Hello,

I am trying to prepare some statistics on the CPU and Memory usage (over time) of a Java application running on a Windows XP machine.

Is there a (free) tool that would let me obtain these statistics? Most of the tools I looked at either profile the existing code for CPU and Heap usage - but do not provide a view the process itself (from a systems point of view).

I tried using IBM Performance Analysis Tool for Java but this does not seem to provide a straightforward metric of determining the amount of memory the process is consuming (similar to the ProcessExplorer tool).

Any pointers would be much appreciated.

Kind regards, Dinuk

+1  A: 

You could always try the perfmon tool which is bundled with windows.

Shimi Bandiel
Actually, the IBM Performance Analysis Tool I mentioned does involve setting counters in the PerfMon tool. Maybe I haven't configured the counters well, but for most of the memory statistics available are paging rates, and virtual memory usage related.
Dinuk
There are also CPU usage monitors on PerfMon
Shimi Bandiel
A: 

Try the profiler included in the Netbeans IDE package. For more information about the details of their profiler see their profiler page.

Elijah
Yep, I did consider using Netbeans profiler, but unless I am mistaken, these profiling tools only provide *relative* CPU usage statistics (i.e. of the CPU cycles consumed, which threads, methods, or code fragments consumed most amounts of CPU and Memory) and do not provide an overview of the actual resources consumed on the Machine itself.
Dinuk
A: 

Sigar might provide what you want

fulkod
A: 

The best option is JNI wrappers if your operating system is windows XP 32 or 64 bit.

JNI wrapper and evaluation key are available here for one month/trail. This is very easy to configure (documents available) and this can give all information (working set, page file, memory details, cpu information ..etc) about specific process.

Perfmon is good on Vista operating system.

Thomman
+2  A: 

I would highly recommend looking into a tool like Hyperic or zenos. These tools can monitor a Java app in multiple ways; an agent installed on the system, via JMX MBeans, or by SNMP.

Rich Kroll
A: 

Do you actually want to "monitor" or "profile"? For the monitoring side of life, there is also Jopr (http://www.jboss.org/jopr/).

In general you should take into account that the shorter the measurement interval is, the more load you put on the targeted resource.

Heiko Rupp