Copy link to clipboard
Copied
Hi All,
I just started run my web application via coldfusion 11 (production). Previously was a cf9.
Can anyone advise me what is the best jvm setting for production use. My server run on :
1. windows 2012 r2 datacenter
2. 128gb ram
3. 8 core
I try to run use this setting xms : 100g xmx: 120g, after 1 day, i cant enter cfserver and it keep load. Check log it return memory :
org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
SEVERE: The web application [/] created a ThreadLocal with key of type [coldfusion.util.DateUtils$1] (value [coldfusion.util.DateUtils$1@32c8948a]) and a value of type [java.util.GregorianCalendar] (value [java.util.GregorianCalendar[time=1438651990401,areFieldsSet=true,areAllFieldsSet=true,lenient=false,zone=sun.util.calendar.ZoneInfo[id="America/Los_Angeles",offset=-28800000,dstSavings=3600000,useDaylight=true,transitions=185,lastRule=java.util.SimpleTimeZone[id=America/Los_Angeles,offset=-28800000,dstSavings=3600000,useDaylight=true,startYear=0,startMode=3,startMonth=2,startDay=8,startDayOfWeek=1,startTime=7200000,startTimeMode=0,endMode=3,endMonth=10,endDay=1,endDayOfWeek=1,endTime=7200000,endTimeMode=0]],firstDayOfWeek=1,minimalDaysInFirstWeek=1,ERA=1,YEAR=2015,MONTH=7,WEEK_OF_YEAR=32,WEEK_OF_MONTH=2,DAY_OF_MONTH=3,DAY_OF_YEAR=215,DAY_OF_WEEK=2,DAY_OF_WEEK_IN_MONTH=1,AM_PM=1,HOUR=6,HOUR_OF_DAY=18,MINUTE=33,SECOND=10,MILLISECOND=401,ZONE_OFFSET=-28800000,DST_OFFSET=3600000]]) but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
so i change to : xms: 50g xmx100g restart svc and i able to load the cfserver back.
So anyone pls help me for the best tuning for cf11 using my machine spec. thx in advance
Shaffiq
1 Correct answer
Hi Shaffiq,
Question can be a bit like asking how long to make a piece of string.
I would like to recommend enabling some monitoring via traditional Java logging to a file or use JMX (java management extensions) with JDK (java developer kit) tools like jconsole or jmc (java mission control)
to know how well the heap and non heap are performing.
Some thoughts about making adjustments.
Since your current Xms Xmx settings are not giving you grief perhaps leave those for now.
Some folks recommend settin
...Copy link to clipboard
Copied
Hi Shaffiq,
Question can be a bit like asking how long to make a piece of string.
I would like to recommend enabling some monitoring via traditional Java logging to a file or use JMX (java management extensions) with JDK (java developer kit) tools like jconsole or jmc (java mission control)
to know how well the heap and non heap are performing.
Some thoughts about making adjustments.
Since your current Xms Xmx settings are not giving you grief perhaps leave those for now.
Some folks recommend setting to the Xms Xmx values the same and many times I agree.
Consider adjusting Metaspace to a higher value than default setting CF11 provides of MaxMetasize=192M. Defining an initial value to Metaspace can be helpful. With more memory available higher values might suit better.
EG -XX:MetaspaceSize=312m -XX:MaxMetaspaceSize=512m
Perhaps define a value to CodeCache so it can grow more than the 240Mb you get when not defined.
EG -XX:ReservedCodeCacheSize=512m
New generation made up of Eden and Survivor spaces might not be performing well even tho
you have large Xms Xmx settings. One can do well to define some tuning for NewGen.
EG -XX:NewSize=4096m -XX:MaxNewSize=4096m -XX:SurvivorRatio=8 -XX:TargetSurvivorRatio=90
Does -XX:CompressedClassSpaceSize= value need applying. JMX will help to know.
Define more threads for the -XX:+UseParallelGC garbage collector defined
EG -XX:ParallelGCThreads=24
Define some limits for growth and shrink of heap.
EG -XX:MinHeapFreeRatio=40 -XX:MaxHeapFreeRatio=70
Something a bit more leading edge use a different garbage collector.
EG -XX:+UseG1GC (Java reminder you would not define -XX:+UseParallelGC)
HTH, Carl.
Copy link to clipboard
Copied
tq carl

