You should really post all the options your using as its hard to put into context the options your using without knowing the others.
Without knowing what Xms is its hard to know if Xmn is set correctly? the default is 1/4 the total heap but on larger heaps this can be to high. I think Sakai's does well when new is around 1G which that would be the default where Xmx=4g which are probably what most installations run with so no need tune if running a 4g heap. The key here is to make Young large enough so your not performing minor collections back to back and collection times for Young are fast typically milliseconds. Also you need leave enough room in tenured which is where most of long lived objects will live, for example this is where you will find the sakai caches.
1) Break up your configuration options into different lines so that you can more easily test different options
JAVA_OPTS="-server -Djava.awt.headless=true -Dhttp.agent=Sakai"
# Set memory options, this sets young to 1/8 the size of tenured where the default is 1/4. Don't make Young generation to large or to small it should be small enough that its collected fast and leave the majority of heap to tenured. Typically no need to adjust survivor.
JAVA_OPTS="$JAVA_OPTS -Xms8g -Xmx8g -Xmn=1g"
# Use compressed oops to use 32bit pointers
JAVA_OPTS="$JAVA_OPTS XX:+UseCompressedOops -XX:+DisableExplicitGC"
# Use Concurrent Mark Sweep collector
JAVA_OPTS="$JAVA_OPTS -XX:+UseConcMarkSweepGC"
# when to start collecting tenured
JAVA_OPTS="$JAVA_OPTS -XX:CMSInitiatingOccupancyFraction=70"
# Set Sakai's Cookie
#JAVA_OPTS="$JAVA_OPTS -Dsakai.cookieName=SAKAI2SESSIONID"
# Enable Sakai Demo for testing
#JAVA_OPTS="$JAVA_OPTS -Dsakai.demo=true"
# Uncomment the following line if using JDK 1.6 SAK-16745
#JAVA_OPTS="$JAVA_OPTS -Dsun.lang.ClassLoader.allowArraySyntax=true"
# Uncomment the following line if using JDK 1.7 SAK-21265
#JAVA_OPTS="$JAVA_OPTS -Dorg.apache.jasper.compiler.Parser.STRICT_WHITESPACE=false"
# Still need this
JAVA_OPTS="$JAVA_OPTS -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false"
# Use legacy merge sort (not needed for Java 8)
#JAVA_OPTS="$JAVA_OPTS -Djava.util.Arrays.useLegacyMergeSort=true"
# Sensitive sakai config should go here and only be accessible to the user sakai runs as
JAVA_OPTS="$JAVA_OPTS -Dsakai.security=$CATALINA_HOME/sakai/"
# uncomment the following line and enter the timezone if different than server's
# some examples for the U.S.: US/Eastern, US/Central, US/Mountain, US/Pacific, US/Arizona
JAVA_OPTS="$JAVA_OPTS -Duser.timezone=US/Eastern"
# for debugging--print garbage collection info
#JAVA_OPTS="$JAVA_OPTS -verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails"
# do these tasks when sakai is starting, like configuring JMX
if [[ "$1" == "start" ]]; then
echo "Sakai Starting"
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8089 -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false"
fi