cancel
Showing results for 
Search instead for 
Did you mean: 

java.lang.OutOfMemoryError: PermGen space

grp1260
Champ on-the-rise
Champ on-the-rise
Hi All

            I am new to the alfresco. I have downloaded Alfresco-Labs-3b-OOo-Setup from sourceforge site and i have installed in my machine. It installed properly. while deploying also it has deployed the properly. i am using the derby database. While try to do some customization on Create Content Wizard, i am facing the error "java.lang.OutOfMemoryError: PermGen space" in tomcat. And it is getting disconnected due to above error. Please provide the proper solution to come out of this probelm. I tried the solutions provided in the forum on above mentioned problem but nothing was working, it might be the way i approaching to correct it is not the proper way. please provide the correct approach to resolve the solution.Please do the needful.


Thanks
Prasad.
6 REPLIES 6

loftux
Star Contributor
Star Contributor
The first thing for you to do is to post your JAVA_OPTS settings, so that we know what you have tried. Then let us know what environment you are running in.
Then check that your JAVA_OPTS actually has been picked up, you can do this by looking in the Administration Console, System Information and then System Properties. Check for eaxmple heap size.

Here is some mor info on JVM tuning and PermGen: http://wiki.alfresco.com/wiki/JVM_Tuning

Peter Löfgren

grp1260
Champ on-the-rise
Champ on-the-rise
Hi Peter

         Thanks a lot for your information.
         System Properties are:

Property Value
alfresco.jmx.dir /C:/Alfresco/AlfrescoLabs3b/tomcat/webapps/alfresco/WEB-INF/classes/alfresco
awt.toolkit sun.awt.windows.WToolkit
catalina.base C:\Alfresco\AlfrescoLabs3b\tomcat
catalina.home C:\Alfresco\AlfrescoLabs3b\tomcat
catalina.useNaming true
common.loader ${catalina.home}/common/classes,${catalina.home}/common/i18n/*.jar,${catalina.home}/common/endorsed/*.jar,${catalina.home}/common/lib/*.jar
file.encoding Cp1252
file.encoding.pkg sun.io
file.separator \
heap.free 48.652MB (51015944 bytes)
heap.maxsize 506.313MB (530907136 bytes)
heap.size 126.750MB (132907008 bytes)
java.awt.graphicsenv sun.awt.Win32GraphicsEnvironment
java.awt.printerjob sun.awt.windows.WPrinterJob
java.class.path C:\jdk1.5.0\lib\tools.jar; C:\Alfresco\AlfrescoLabs3b\tomcat\bin\bootstrap.jar
java.class.version 49.0
java.endorsed.dirs C:\Alfresco\AlfrescoLabs3b\tomcat\common\endorsed
java.ext.dirs C:\jdk1.5.0\jre\lib\ext
java.home C:\jdk1.5.0\jre
java.io.tmpdir C:\Alfresco\AlfrescoLabs3b\tomcat\temp
java.library.path C:\jdk1.5.0\bin; .; C:\WINDOWS\system32; C:\WINDOWS; C:\jdk1.5.0\bin; C:\Alfresco\AlfrescoLabs3b\bin; C:\jdk1.5.0\jre\bin\client; D:\oracle\product\10.2.0\db_1\bin; C:\Program Files\CA\Dcs\DMScripting\; C:\Program Files\CA\DCS\CAWIN\; C:\WINDOWS\system32; C:\WINDOWS; C:\WINDOWS\System32\Wbem; C:\Program Files\CA\Unicenter Software Delivery\BIN; c:\Program Files\Microsoft SQL Server\90\Tools\binn\; C:\PROGRA~1\CA\SHARED~1\CAM\bin; C:\Program Files\CA\Unicenter DSM\bin; C:\Program Files\Microsoft SQL Server\80\Tools\Binn\; C:\Program Files\Microsoft SQL Server\90\DTS\Binn\; C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\; C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\PrivateAssemblies\; C:\NANT\nant-0.86-nightly-2006-10-29\bin; ; C:\Program Files\CA\SharedComponents\ScanEngine; C:\Program Files\CA\SharedComponents\CAUpdate\; C:\Program Files\CA\SharedComponents\ThirdParty\; C:\Program Files\CA\SharedComponents\SubscriptionLicense\; C:\Program Files\CA\eTrust Antivirus; C:\jdk1.5.0\bin; =%Path%; C:\Alfresco\ApacheAnt\apache-ant-1.7.1\bin; C:\MatrixRMI\bin\winnt
java.naming.factory.initial org.apache.naming.java.javaURLContextFactory
java.naming.factory.url.pkgs org.apache.naming
java.runtime.name Java(TM) 2 Runtime Environment, Standard Edition
java.runtime.version 1.5.0-b64
java.specification.name Java Platform API Specification
java.specification.vendor Sun Microsystems Inc.
java.specification.version 1.5
java.util.logging.config.file C:\Alfresco\AlfrescoLabs3b\tomcat\conf\logging.properties
java.util.logging.manager org.apache.juli.ClassLoaderLogManager
java.vendor Sun Microsystems Inc.
java.vendor.url http://java.sun.com/
java.vendor.url.bug http://java.sun.com/cgi-bin/bugreport.cgi
java.version 1.5.0
java.vm.info mixed mode
java.vm.name Java HotSpot(TM) Server VM
java.vm.specification.name Java Virtual Machine Specification
java.vm.specification.vendor Sun Microsystems Inc.
java.vm.specification.version 1.0
java.vm.vendor Sun Microsystems Inc.
java.vm.version 1.5.0-b64
javax.net.ssl.trustStore C:\jdk1.5.0\jre\lib\security\cacerts
javax.net.ssl.trustStorePassword changeit
line.separator 
org.apache.lucene.lockDir C:/Alfresco/AlfrescoLabs3b/alf_data/lucene-indexes/locks
os.arch x86
os.name Windows XP
os.version 5.1
package.access sun.,org.apache.catalina.,org.apache.coyote.,org.apache.tomcat.,org.apache.jasper.,sun.beans.
package.definition sun.,java.,org.apache.catalina.,org.apache.coyote.,org.apache.tomcat.,org.apache.jasper.
path.separator ; 
server.loader ${catalina.home}/server/classes,${catalina.home}/server/lib/*.jar
shared.loader ${catalina.base}/shared/classes,${catalina.base}/shared/lib/*.jar
sun.arch.data.model 32
sun.boot.class.path C:\Alfresco\AlfrescoLabs3b\tomcat\common\endorsed\serializer.jar; C:\Alfresco\AlfrescoLabs3b\tomcat\common\endorsed\xalan.jar; C:\jdk1.5.0\jre\lib\rt.jar; C:\jdk1.5.0\jre\lib\i18n.jar; C:\jdk1.5.0\jre\lib\sunrsasign.jar; C:\jdk1.5.0\jre\lib\jsse.jar; C:\jdk1.5.0\jre\lib\jce.jar; C:\jdk1.5.0\jre\lib\charsets.jar; C:\jdk1.5.0\jre\classes
sun.boot.library.path C:\jdk1.5.0\jre\bin
sun.cpu.endian little
sun.cpu.isalist  
sun.desktop windows
sun.io.unicode.encoding UnicodeLittle
sun.jnu.encoding Cp1252
sun.management.compiler HotSpot Server Compiler
sun.os.patch.level Service Pack 2
tomcat.util.buf.StringCache.byte.enabled true
user.country US
user.dir C:\Alfresco\AlfrescoLabs3b
user.home C:\Documents and Settings\sk33945
user.language en
user.name SK33945
user.timezone GMT+05:30
user.variant  
webapp.root C:\Alfresco\AlfrescoLabs3b\tomcat\webapps\alfresco\

loftux
Star Contributor
Star Contributor
It looks like you have not updated the JAVA_OPT.
Edit alfresco.bat in your installation folder, look for JAVA_OPT=
Try these setting (depending on your memory)
set JAVA_OPTS=-Xms256m -Xmx1024m -Xss96k -XX:MaxPermSize=256m -server

xtine
Champ in-the-making
Champ in-the-making
I am on linux32, had the same error, following http://www.jroller.com/agileanswers/entry/preventing_java_s_java_lang I set permsize and maxpermsize in java_opts to 512, which seems to work for me.

Xtine

m_anands
Champ in-the-making
Champ in-the-making
Modify JAVA_OPTS variable in Tomcat to ${ALF_HOME}/tomcat/bin/setenv.bat file. This file looks like to:


set JAVA_OPTS=-Xms256m -Xmx1024m -Xss96k -XX:MaxPermSize=256m -server 

set JAVA_HOME=C:\1BPMS-~1\alf34c_1\java 

set JAVA_OPTS=%JAVA_OPTS%

nicolasraoul
Star Contributor
Star Contributor
I had the same error, and switching from HotSpot to Resin fixed it (it was on a Windows server).
It might not work in all cases.
Resin performs garbage collection on PermGen, while HotSpot does not.

Hope this helps,
Nicolas Raoul
Getting started

Tags


Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.