How do I provide JVM arguments to VisualVM?

Mike Partridge picture Mike Partridge · Mar 5, 2012 · Viewed 53.8k times · Source

I'm using VisualVM from JDK 1.6.0_26 to profile a Java webapp running under Tomcat, but VisualVM often tells me that it doesn't have enough memory to take a snapshot, and to use the -Xmx switch to provide more memory to Netbeans. The problem is, I'm running VisualVM outside of Netbeans, so how can I provide JVM arguments to jvisualvm.exe?

Answer

Zack Macomber picture Zack Macomber · Mar 5, 2012

Should be able to modify the memory settings in %JDK_HOME%\lib\visualvm\etc\visualvm.conf

Xms and Xmx are in the default_options line.