Skip to main content
Known Participant
March 16, 2011
Question

Server stops processing ColdFusion

  • March 16, 2011
  • 2 replies
  • 4289 views

One of our servers is throwing "java.lang.OutOfMemoryError: PermGen space".

Here is the original jvm.config:

java.args=-server  -Xmx4096m -Xms4096m -Dsun.io.useCanonCaches=false -XX:PermSize=128m  -XX:MaxPermSize=192m -XX:+UseParallelGC -XX:-UseGCOverheadLimit  -Dcoldfusion.rootDir={application.home}/  -Djava.security.policy={application.home}/servers/cfusion/cfusion-ear/cfusion-war/WEB-INF/cfusion/lib/coldfusion.policy   -Djava.security.auth.policy={application.home}/servers/cfusion/cfusion-ear/cfusion-war/WEB-INF/cfusion/lib/neo_jaas.policy

Made  a change to bump the -XX:MaxPermSize=192m to -XX:MaxPermSize=256m but  this morning got the error again so I bumped it again to  -XX:MaxPermSize=512m.

Am I barking up the wrong tree?

ColdFusion version 9,0,1,274733 

Update level

JRun4/servers/cfusion/cfusion-ear/cfusion-war/WEB-INF/cfusion/lib/updates/hf901-00001.jar  

server OS: Windows 2003 R2, Standar x64, SP2

webserver: IIS6

database: MSSQL 2005

    This topic has been closed for replies.

    2 replies

    dpstucsonAuthor
    Known Participant
    March 17, 2011

    Will let you know what happens with the deletion of the cfclasses.  Have  to this this when it impacts our client community the least.

    Community Expert
    March 17, 2011

    With that many compiled classes, you'll probably see better performance if you don't store them in the first place. You can disable that from within the CF Administrator by unchecking "Save class files" under Caching.

    Dave Watts, CTO, Fig Leaf Software

    http://www.figleaf.com/

    http://training.figleaf.com/

    Dave Watts, Eidolon LLC
    pete_freitag
    Participating Frequently
    March 16, 2011

    The PermGen stores compiled java class files and metadata type information about them. Take a look at the cfclasses folder on production, and see how big it is, that should give you a minimum permgen size.

    Another reason the PermGen could be filling up could be if you are doing a lot of dynamic class loading. Are you doing anything funky in your code, do you use JavaLoader by chance?

    dpstucsonAuthor
    Known Participant
    March 16, 2011

    The cfclasses folder on the production machine is 144MB.

    As far as code I cannot tell you that as I'm just the System Admin who catches the flak when the server goes south.

    Legend
    March 17, 2011

    Hi,

    I would be inclined to stop CF, delete contents of cfclasses and start CF. Having said that I do not know your application, you will know better if this procedure is detrimental or not. Why do this maybe on the files in there is broken somehow, so let them build again.

    The "java.lang.OutOfMemoryError: PermGen space" is usually fairly clear as to the problem and in my mind the “knee jerk” steps you took to increase MaxPermSize would seem correct.

    Since you are still have a problem tho increases have been made to the relevant error maybe some logging to see what is going on might lead to a solution. Normally I would say turn on JVM logging tho to see a PermGen issue with that can be hard. In your case some logging with the Java Dev Kit tools JCONSOL and JVISUALVM might be easier to see what is happening. Just a couple things happening for me right now so I will post more details on how to do that latter on.

    Sometimes I have seen the Code Cache buffer be the issue and a “java.lang.OutOfMemoryError: PermGen” error provided in the log. Strange I know the JDK style logging will help see if that is a problem.

    See your using -XX:-UseGCOverheadLimit. Personally I do not like to use that switch however guess you know why it is there and you have good reasons for running JVM that way?

    Perhaps interesting to know what JVM version is in use? CF9.0.1 usually installs with 1.6.0_17, I see from CF blog 1.6.0_24 is supported.

    http://blogs.adobe.com/coldfusion/2011/03/15/jdk-1-6-0_24-is-now-officially-supported/

    HTH, Carl.