You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by SnowCrash <ja...@gmail.com> on 2006/04/10 09:28:58 UTC

CreateJavaVM Failed when setting PermSize

Hello all,

I'm trying to override the default PermSize and MaxPermSize values in the
JVM due to some OutOfMemory errors we were getting recently, but I don't
appear to be able to set this in the Tomcat Service Properties (on Windows).

I have tried adding:

-XX:PermSize=128m
-XX:MaxPermSize=160m 

to the "Java options" section in the "Java" tab of the Tomcat Service
configuration dialog, but this prevents the service from starting, simply
listing:

[409  javajni.c] [error] CreateJavaVM Failed
[930  prunsrv.c] [error] Failed initializing java
C:\tomcat-5.5.12\bin\bootstrap.jar
[1179 prunsrv.c] [error] ServiceStart returned 2

In the service log.

I have also tried adding:

-Dcatalina.opts=-XX:PermSize=128m -XX:MaxPermSize=160m 

(I saw this on another post somewhere).  This appears to do nothing as the
MemoryPoolMXBean for the Perm Gen memory pool still reports a max size of
64m.

I have also tried setting an environment variable under JAVA_OPTS for the
same config (I saw this mentioned somewhere too); but again nothing.

Anyone know how I can configure the JVM under a Windows (service)
installation of Tomcat to change the Initial/Max PermSize?

Seems to me the first option should work but crashes the JVM.

I am using:

jdk1.5.0_04
tomcat-5.5.12
Windows XP SP2

Thanks.
--
View this message in context: http://www.nabble.com/CreateJavaVM-Failed-when-setting-PermSize-t1423415.html#a3837141
Sent from the Tomcat - User forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: CreateJavaVM Failed when setting PermSize

Posted by SnowCrash <ja...@gmail.com>.
Wow... I'm sure I tried that originally and got the same problem... however
this time it worked!

Thanks.

FYI for anyone else, this is what I have in my Tomcat Service config:

-Dcatalina.home=C:\tomcat-5.5.12
-Dcatalina.base=C:\tomcat-5.5.12
-Djava.endorsed.dirs=C:\tomcat-5.5.12\common\endorsed
-Djava.io.tmpdir=C:\tomcat-5.5.12\temp
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
-Djava.util.logging.config.file=C:\tomcat-5.5.12\conf\logging.properties
-XX:PermSize=128m
-XX:MaxPermSize=256m

With:

Initial memory pool: 128
Maximum memory pool: 512

Obviously my tomcat instance is installed at C:\tomcat-5.5.12


--
View this message in context: http://www.nabble.com/CreateJavaVM-Failed-when-setting-PermSize-t1423415.html#a3837504
Sent from the Tomcat - User forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: CreateJavaVM Failed when setting PermSize

Posted by Leon Rosenberg <ro...@googlemail.com>.
I think the PermSize can be only a 2 to the power of n, and 160M isn't
a valid value then.
Try to set it to 256M.
regards
Leon

On 4/10/06, SnowCrash <ja...@gmail.com> wrote:
>
> Hello all,
>
> I'm trying to override the default PermSize and MaxPermSize values in the
> JVM due to some OutOfMemory errors we were getting recently, but I don't
> appear to be able to set this in the Tomcat Service Properties (on Windows).
>
> I have tried adding:
>
> -XX:PermSize=128m
> -XX:MaxPermSize=160m
>
> to the "Java options" section in the "Java" tab of the Tomcat Service
> configuration dialog, but this prevents the service from starting, simply
> listing:
>
> [409  javajni.c] [error] CreateJavaVM Failed
> [930  prunsrv.c] [error] Failed initializing java
> C:\tomcat-5.5.12\bin\bootstrap.jar
> [1179 prunsrv.c] [error] ServiceStart returned 2
>
> In the service log.
>
> I have also tried adding:
>
> -Dcatalina.opts=-XX:PermSize=128m -XX:MaxPermSize=160m
>
> (I saw this on another post somewhere).  This appears to do nothing as the
> MemoryPoolMXBean for the Perm Gen memory pool still reports a max size of
> 64m.
>
> I have also tried setting an environment variable under JAVA_OPTS for the
> same config (I saw this mentioned somewhere too); but again nothing.
>
> Anyone know how I can configure the JVM under a Windows (service)
> installation of Tomcat to change the Initial/Max PermSize?
>
> Seems to me the first option should work but crashes the JVM.
>
> I am using:
>
> jdk1.5.0_04
> tomcat-5.5.12
> Windows XP SP2
>
> Thanks.
> --
> View this message in context: http://www.nabble.com/CreateJavaVM-Failed-when-setting-PermSize-t1423415.html#a3837141
> Sent from the Tomcat - User forum at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org