aspose file tools*
The moose likes Performance and the fly likes How to identify default Java heapsize in Windows Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Java » Performance
Bookmark "How to identify default Java heapsize in Windows" Watch "How to identify default Java heapsize in Windows" New topic
Author

How to identify default Java heapsize in Windows

Varshini Priya
Ranch Hand

Joined: Feb 17, 2008
Posts: 93

Im running an eclipse application in my machine. I have two queries

1. I would like to know how to check the default heap size that the jvm is using to run the application.Im using a windows machine to run the java application. I tried to check the default heap size by the following way
ControlPanel--->Programs--->JavaSetting--> JavaTab -->View Button ---> JavaRuntimeEnvironment settings window ---> Userstab --> Value under RuntimeParameters

But in my system, there is no runtime parameters defined. Is there a command that I can execute via command prompt to check the default heap size in my machine.

2. How to increase the heap size parameter and run the eclipse plugin application from command prompt. For eg: To increase the heap size and execute the jar file we use the below command java -Xms64m -jar MyApp.jar. I would like to know how to set heap parameters and execute my java application which is an exe file. I tried to execute use the below command, but the command prompt doesnot recognise the command
java -Xms512m iepsd.exe

Where iepsd.exe is my java application.
E Armitage
Rancher

Joined: Mar 17, 2012
Posts: 892
    
    9
You can run jconsole and connect to the java process to get information about it.
Changing the startup memory depends on how the .exe was created. Normally (e.g in the case of eclipse itself) there would be a settings file for the configuration where you can change the startup settings.
Luan Cestari
Ranch Hand

Joined: Feb 07, 2010
Posts: 163

Eclipse have also eclipse.ini file in the installation folder which it receive those parameters -> http://wiki.eclipse.org/Eclipse.ini


Please, visit me for some cool tech post at www.ourdailycodes.com
Tai Truong
Greenhorn

Joined: Oct 16, 2012
Posts: 4

Do you know " java -XX:+PrintFlagsFinal". It prints all possible flags you can pass to the JVM. In addition it also prints the default value for each flag. I have summarized this on my blog here: http://www.pointsoftware.ch/de/cookbook-jvm-memory-arguments/

HTH, Tai
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to identify default Java heapsize in Windows