Skip to main content
Brainiac
September 6, 2010
Answered

Altering maximum JVM Heap Size to 1024 gives error

  • September 6, 2010
  • 2 replies
  • 8922 views

Altering maximum JVM Heap Size to 1024 gives error.

Environment:

CF9
O/S Windows 2003 R2 Sp2
CPU XEON
RAM 2Gb

After installing ColdFusion one of the settings that gets changed is:
Server Settings > Java and JVM > Maximum JVM Heap Size (MB) 1024
ColdFusion Application service will not start with this setting. An error file is created in \ColdFusion9\runtime\bin\hs_err_pid1234.log (where 1234 number changes). The log file details are long so will paste a sample soon.


Arguments to the JVM are:
java.args=-server  -Xmx1024m -Dsun.io.useCanonCaches=false -XX:MaxPermSize=192m -XX:+UseParallelGC -Dcoldfusion.rootDir={application.home}/../ -Dcoldfusion.libPath={application.home}/../lib -Dcoldfusion.classPath={application.home}/../lib/updates,{application.home}/../lib,{application.home}/../gateway/lib/,{application.home}/../wwwroot/WEB-INF/flex/jars,{application.home}/../wwwroot/WEB-INF/cfform/jars

The 1024m max JVM is one of the commonly recommended changes. Why would altering maximum JVM setting from 512m stop ColdFusion from functioning?

    This topic has been closed for replies.
    Correct answer Charlie Arehart

    Hi All,

    Thanks for your input so far (and Mack as well nice to know someone is listening).

    Charlie

    Yes CF8 functioned the same way as CF9. Salient details from CF8 hs_err_pid1234.log also shows NTDLL.DLL issue:

    #  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c82a774, pid=368, tid=2128
    #
    # Java VM: Java HotSpot(TM) Server VM (10.0-b19 mixed mode windows-x86)
    # Problematic frame:
    # C  [ntdll.dll+0x2a774]
    ...
    Stack: [0x57610000,0x57710000],  sp=0x5770e964,  free space=1018k
    Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
    C  [ntdll.dll+0x2a774]
    C  [ntdll.dll+0x2a84b]
    C  [MSVCR71.dll+0x218a]
    ...
    Dynamic libraries:
    0x00400000 - 0x00410000  e:\ColdFusion8\runtime\bin\jrun.exe
    0x7c800000 - 0x7c8c2000  C:\WINDOWS\system32\ntdll.dll
    etc

    Confirm expected memory details show up in CNTRL PANEL > System and TASKMANGER.

    As is so often the case these days the server is a distance from me I do not have hands on access. Have already had Windows 03 reloaded. One other peice of information to include is the server is a VM that is run on Citrix Xen  5.5.

    Appreciate all your further comments, Carl.


    This is indeed an odd problem. Something seems not right/normal.

    I did a little digging, and found one potentially useful blog entry:

    http://iamgoat.com/post/804922016/coldfusion-application-server-wont-start-after-windows

    It sounds just like your problem, but admittedly it offers a pretty specific problem/solution, which may not apply.

    Here's another question: are you looking in the \runtime\logs directory? Do the log files there perhaps show more info on the problem, perhaps before or after the time that these PID log files are being created? They may be secondary to some other primary problem. Look specifically for the string OutOfMemory in the log files.

    If that finds nothing, I'd propose one other thought: consider changing the JVM. I see you're using 1.6_0_14. There are several points between that and the latest _21 that you may want to try.

    Finally, one more thought to consider: since this is the Hotspot compiler that's reporting the error (the hs in hs_err_pidnnnn.log), there's a possibility that adding a switch to turn off Hotspot, just to get past this, might give a different error message with perhaps more info. In the jvm.config (or the CF admin, if on Standard or Server mode), try adding -Xint.

    Let us know if any help.

    /charlie

    Providing CF troubleshooting services at carehart.org/consulting

    charlie@carehart.org

    2 replies

    Inspiring
    September 6, 2010
    Arguments to the JVM are:

    java.args=-server  -Xmx1024m -Dsun.io.useCanonCaches=false -XX:MaxPermSize=192m -XX:+UseParallelGC -Dcoldfusion.rootDir={application.home}/../ -Dcoldfusion.libPath={application.home}/../lib -Dcoldfusion.classPath={application.home}/../lib/updates,{application .home}/../lib,{application.home}/../gateway/lib/,{application.home}/.. /wwwroot/WEB-INF/flex/jars,{application.home}/../wwwroot/WEB-INF/cffor m/jars

    Is there really a space in that last path:

    {application.home}/../wwwroot/WEB-INF/cffor m/jars

    ?

    Maybe try making the change directly to the file, rather than using the CFAdmin UI.  I seem to recall that in the past using CFAdmin to make these changes could cause problems (dunno the details, as I always edit the files directly).

    The 1024m max JVM is one of the commonly recommended changes. Why would altering maximum JVM setting from 512m stop ColdFusion from functioning?

    Dunno.  And it's hard to say without seeing anything from your logs.

    --

    Adam

    Inspiring
    September 6, 2010

    It probably goes without saying, but ... whichever way you update the settings, make a backup first. Then if anything goes terribly wrong, just restore the backup.

    (Sorry. It is a knee-jerk reaction any time I hear jvm.config ..)

    Brainiac
    September 6, 2010

    restoring jvm.config or changing the Xmx value to 512m allows ColdFusion application service  to start again. To support the CF application the maximum jvm heap needs to be set to 1024m

    Brainiac
    September 6, 2010

    More information. Have uninstalled CF9 and installed CF8.0.1 and get same problem once maximum JVM is altered to 1024m.