Page 1 of 1

OutOfMemoryError: PermGen space on fresh WIndows 7 install

PostPosted:Mon Apr 11, 2011 7:30 pm
by cakewipe
Hi, I am new to openKM but have been developing in Java for a 7 years. Im running Java 1.6.0_21 on my windows 7 64 bit machine.
I've seen other posts where people hit this same issue and they've had to increase their permspace in their run.bat file...
Here's how my run.bat file looks with my new modifications (in bold)...
Code: Select all
REM Add bin/native to the PATH if present
if exist "%JBOSS_HOME%\bin\native" set PATH=%JBOSS_HOME%\bin\native;%PATH%
if exist "%JBOSS_HOME%\bin\native" set JAVA_OPTS=%JAVA_OPTS% -Xms256m -Xmx2048m -XX:PermSize=256m -XX:MaxPermSize=1024m -Djava.awt.headless=true -Djava.library.path="%PATH%"
to get it to even run without errors, I had to create a JAVA_HOME variable and add the java lib directory to my class path and the java bin directory to my path in my environment variables... These are all things I had to do that WEREN'T in the quickrun guide. which is understandable because these are Java install issues NOT openKM... Now I'm getting TONS! of PermGen space errors even after I increased my PermSize quite a bit!!!! It wouldn't even start up completely until I boosted my PermSize, now I get the PermGen error whenever I login, try to upload a file, and pretty much every other action.
Is there a problem with this running on a 64 bit processor/operating system?
Can someone please help me? I can keep increasing this size limit but I haven't seen anyone else experiencing these issues with the large memory that I've allocated for it already.

Thanks in advance!

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Mon Apr 11, 2011 10:14 pm
by jllort
Take a look at run.sh and put in similar way in your run.bat ( look at first lines of run.sh )

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Mon Apr 11, 2011 11:24 pm
by cakewipe
Ok, I updated my run.sh to include these lines and took them out of the run.bat file but I still experience the same problems.
After much frustration, I tried running this on my windows Vista (32bit) computer (Which is the same computer but I have dual boot option setup so I can boot off either Windows7 or Windows Vista) and installed it the exact same way and it worked.
So now I'm thinking it has to do with either the 64bit operating system or the fact that it's Windows7... I also noticed windows 7 is not on your supported operating systems page. So now I have to ask, is Windows7 the problem? or is it 64bit ?

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Tue Apr 12, 2011 8:32 pm
by jllort
I don't know which could the the cause of the problem. Really I've got some installation on 64 bits environment but I'm not sure if there're some one on windows 7. By deafault OpenKM comes with jboss and only need JVM for running, nothing else. Do you hava java sun jdk version 1.6.X ? Could be some error on JVM version which version are you using ?

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Wed Apr 13, 2011 9:07 am
by pavila

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Fri Apr 15, 2011 12:51 am
by cakewipe
I am still hitting this error on Windows 7. Since I posted this message I have installed it successfully on Mac OS X (10.6.7 running java version 1.6.0.17) and Ubuntu
after installing on windows 7(64bit) and my windows Vista (32bit) machines. On my windows7 machine I get a TON of PermGen errors from just doing simple tasks like checking in a file. On the Vista machine I can use it for while before I start getting PermGen errors.
I have the same version of JVM running on both machines.... I type java -version and it says java version "1.6.0_18".
I'm wondering why windows would have all these issues when Mac and Ubuntu wouldn't.

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Sat Apr 16, 2011 3:56 pm
by jllort
Do you've got other windows 7 for testing ?

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Tue May 17, 2011 3:06 pm
by kmstitt
Hello,

I have the same setup (Windows 7, 64 bit) This seemed to take care of the OutOfMemoryError on my computer:

I changed this line in the run.bat file from this:
Code: Select all
set JAVA_OPTS=%JAVA_OPTS% -Xms128m -Xmx512m
to this:
Code: Select all
set JAVA_OPTS=%JAVA_OPTS% -Xms256m -Xmx1024m -XX:PermSize=64m -XX:MaxPermSize=128m
Not sure if the Xms and Xmx settings really needed to be changed, you might get by be just adding the XX settings.

Good Luck,
-Kris

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Fri May 20, 2011 10:54 pm
by jllort
it's good have Xmx1024m of memory assigned 512 is too small for jboss.

Next openkm release will come with tomcat bundle or jboss bundle, really we're now developing under this both environments ( on trunk )

Re: OutOfMemoryError: PermGen space on fresh WIndows 7 insta

PostPosted:Fri Jun 10, 2011 2:40 am
by sanyou
I have the same problem before. But after using Kris' solution. The problem seems fixed. Thanks for Kris.