aspose file tools*
The moose likes Performance and the fly likes Console based java profiler needed Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » Performance
Bookmark "Console based java profiler needed" Watch "Console based java profiler needed" New topic
Author

Console based java profiler needed

sumit anand kumar
Ranch Hand

Joined: Apr 28, 2010
Posts: 83
Hi All,

I have a application running in AWS EC2. Now i can just login from console to run the app. I don't have X11 support.
I want to monitor the health of the application running there. CPU usage, heap size, memory leakage etc.
Most of the profilers JConsole,JVisualVM are UI based. And its very difficult to use them for the end user side to monitor the application.

Another one i used is HPROF, but the data generated by it is not readable. it is in so much details.

This -agentlib:hprof=heap=sites doesn't give much data, & -agentlib:hprof=heap=all gives too much data.
I am using jhat to parse the output.
But what i really want is simple info about CPU usage, heap size, memory leakage. Identifying any culprit in my apps etc.

I want the tool to monitor the app, then i will fire my testcases for doing the performance runs. The tool should be able to record the VM stats, and i can download it and view it offline.
Kindly suggest any open source tool that does / matches like the one i need.
Rohan Dhapodkar
Greenhorn

Joined: Jun 27, 2011
Posts: 23
If you can access your server from any X11 based desktop(Windows/Linux), then you can use JVIsualVM which can connect to remote JVM configured with remote JMX settings. Refer http://download.oracle.com/javase/1.5.0/docs/guide/management/agent.html#remote for remote JMX settings.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41574
    
  54
Have you considered such tools as JamonApi, java-monitor.com and Probe (on GoogleCode)? JamonApi in particular can be programmatically extended to suit your needs.


Ping & DNS - my free Android networking tools app
sumit anand kumar
Ranch Hand

Joined: Apr 28, 2010
Posts: 83
@Rohan : Internet connection is sometimes too slow to do that.

@Dittmer : Yes i use JamonApis, but it only tells the time taken to execute some section of code. But i need something that can tell me CPU utilization & Memory consumptions related data.
Also not sure if i can use java-monitor.com, as my project don't have the privilege of getting outside access.
steve souza
Ranch Hand

Joined: Jun 26, 2002
Posts: 860
You could try jstat (http://download.oracle.com/javase/1,5.0/docs/tooldocs/share/jstat.html) or write some code that writes memory, cpu stats to a log file every 30 seconds or so.


http://www.jamonapi.com/ - a fast, free open source performance tuning api.
JavaRanch Performance FAQ
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Console based java profiler needed