[英]Avoid Permgen Space error when running Tomcat from Eclipse
What is the best way to avoid permgen space error when running Tomcat from Eclipse 3.6? 从Eclipse 3.6运行Tomcat时,避免permgen空间错误的最佳方法是什么? Is this done by adding the following line:
这是通过添加以下行来完成的:
-XX:MaxPermSize=512m
at the end of eclipse.ini
? 在
eclipse.ini
结尾? Or is there extra configuration necessary? 或者是否需要额外的配置?
The configuration in eclipse.ini
is only for the JVM that actually runs Eclipse. eclipse.ini
的配置仅适用于实际运行Eclipse的JVM。
Tomcat is run in its own JVM instance, so you'll need that separately. Tomcat在自己的JVM实例中运行,因此您需要单独使用它。
Assuming you use WTP to start your Tomcat instance, you need to go to your Server configuration, click "Open launch configuration" and there (on the "Arguments" tab) edit/add the VM arguments to include the desired -XX:MaxPermSize
argument. 假设您使用WTP启动Tomcat实例,您需要转到服务器配置,单击“打开启动配置”并在那里(在“参数”选项卡上)编辑/添加VM参数以包含所需的
-XX:MaxPermSize
参数。
No. Tomcat runs in a separate JVM from eclipse. 不,Tomcat在eclipse的独立JVM中运行。 Add this option in the VM arguments of the launch configuration :
在启动配置的VM参数中添加此选项:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.