问题描述
我使用eclipse64 3.7.1与Linux RHEL5 64我有8g的ram。无论我设置的大小多少
-Dosgi.requiredJavaVersion = 1.5
-XX:MaxPermSize = 1024M
-Xms1024m
-Xmx1024m
记录事件循环异常时出错:
java.lang.OutOfMemoryError :PermGen空间
在java.lang.ClassLoader.defineClass1(本机方法)
在java.lang.ClassLoader.defineClass(ClassLoader.java:791)
在org.eclipse.osgi.internal .baseadaptor.DefaultClassLoader。
有没有其他地方可以配置与eclipse和JVM相关的内存选项?请帮忙。
如果您设置最大 PermGen
大小为1024M,很可能您的应用程序中有类加载器泄漏。增加PermGen大小会减轻这些异常的一段时间,但对于长时间运行的应用程序可能不是很有帮助。
您可能会发现这篇文章很有用:
I'm using eclipse64 3.7.1 with Linux RHEL5 64 I have 8gigs of ram.
No matter how large I set the
-Dosgi.requiredJavaVersion=1.5
-XX:MaxPermSize=1024M
-Xms1024m
-Xmx1024m
I continue to get errors like:
Error while logging event loop exception:
java.lang.OutOfMemoryError: PermGen space
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:791)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.
Is there anywhere else I can configure memory options that relate to eclipse and the JVM? Please help.
If you're getting that exception even after setting the max PermGen
size to 1024M, it is likely that you have classloader leaks in your application. Increasing the PermGen size will mitigate these exceptions for a while but might not be very helpful for a long-running application.
You might find this article useful: http://blogs.oracle.com/fkieviet/entry/classloader_leaks_the_dreaded_java
这篇关于在Eclipse.ini之外设置JVM maxperm大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!