Now when I try to take snapshot using the command java -jar jboss-profiler-client.jar snapshot, the command prompt never returns.
The snapshot command can take a while to complete - also try to increase the heap size for the VM using -Xmx1024m.
It sounds like you are doing it the right way.
You may want to try the Save command followed by the GetSnapshot command instead.
Otherwise post your full config here together with the commands executed.
I tried running the jboss-profiler-client.jar on a remote machine ( different from where JBoss AS is running) by executing the following command
java -Xmx1024m -jar jboss-profiler-client.jar -h <IP Address> -p 5400 snapshot
Still the command prompt hangs (waited for around 30 minutes).
Even using listSnapshots doesn't display any output. jboss-profiler.properties copied to <JBOSS_HOME>/bin is provided below:
Does startProfiler and stopProfiler return ?
The save=yes + startup=yes option should provide you with a .jps file after the AS has been halted - probably in the bin/ directory.
There are some fixes in the SVN repository - so you can try that if you want.
I now tried with a package that has few classes and it worked. I am able to take snapshots.
Is there a GUI available with jboss-profiler-2.0.Beta2 to view the snapshots?
I have released 2.0 Beta4 which will generate the reports in HTML.
We don't have a web ui for the 2.0 branch yet - but we are working on it.
If stopProfiler or snapshot doesn't return, try to set "jsf=no" in jboss-profiler.properties.
I had this problem, and eventually I've found out that the jsf profiler tryes to validate XML documents at some point during the stopProfiler call, and it needs to access external web sites to do so. Our firewall was blocking outgoing requests, so all XML validation attempts had to wait until the connection timed out.