When running Java programs, especially the app server, we often need to increase the JVM heap size. Set the heap size in the parameter format of-xms256m-xmx256m, and set the memory size of the perm space in the format of-XX: permsize = 256 m-XX: maxpermsize = 256m.
However, from the perspective of the operating system, the memory size of a running process that can be applied for is limited. Instead of making an application at will.
In Linux, you can use ulimit-a to manually set the memory size of processes that can be applied by the process. However, on Windows, I do not know how to manually set this value. You can tell me what you know.
In Windows XP (other Windows la s have not been tested), the memory size of a process that a process can apply for cannot exceed half of the physical memory. For a JVM, the size of-xmx and-XX: maxpermsize should not exceed half of the physical memory, considering that-xmx and-XX: maxpermsize are only the majority of JVM memory, not all. Therefore, the sum of-xmx and-XX: maxpermsize should be slightly less than half of the physical memory.