关于jvm的内存限制的问题的解决办法
jdk编译器对内存的支持不同 client状态和server状态不同 后者支持更大些 操作系统不同也存在不同 位操作系统就比 位操作系统大
测试方法 在命令行下用 java XmxXXXXM version 命令来进行测试 然后逐渐的增大XXXX的值 如果执行正常就表示指定的内存大小可用 否则会打印错误信息
如
C:\>java client Xmx M version
java version _ ″
Java(TM) SE Runtime Environment (build _ b )
Java HotSpot(TM) Client VM (build b mixed mode)
C:\>java client Xmx M version
java version _ ″
Java(TM) SE Runtime Environment (build _ b )
Java HotSpot(TM) Client VM (build b mixed mode)
C:\>java client Xmx M version
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine
C:\>java server Xmx M version
Error: no `server JVM at `C:\Program Files\Java\jre _ \bin\server\jvm dll
java编译器 client和server状态改变方法
C:\Program Files\Java\jdk _ \jre\lib\i \jvm cfg
打开
client KNOWN
server KNOWN
hotspot ALIASED_TO client
classic WARN
native ERROR
green ERROR
调整为
server KNOWN
client KNOWN
hotspot ALIASED_TO client
classic WARN
native ERROR
green ERROR
lishixinzhi/Article/program/Java/hx/201311/26433