console keeps outputting:
[GC (Allocation Failure) [PSYoungGen: 338275K->4614K(341504K)]
412867K->79382K(1040896K), 0.0107084 secs]
[Times: user=0.01 sys=0.00, real=0.01 secs]
catalina.sh file is configured as follows:
JAVA_OPTS="-server -Xms1024m -Xmx2048m
-XX:+HeapDumpOnOutOfMemoryError
-XX:HeapDumpPath=/data/webSoft/tomcatLogs
-XX:+PrintGCDetails"
- Server operating system: CentOS 6.8 64-bit
- CPU: 2 core
- Server memory: 8G
I heard that the memory is adjusted to physical memory 1ax 2, the maximum is the same as the minimum, and the younger generation is 3 br 8 of heap memory
so, try to increase the heap space and the size of the younger generation. The catalina.sh file is configured as follows:
JAVA_OPTS="-server -Xms4096m -Xmx4096m -Xmn1536m "
but with egg, the value of [PSYoungGen: 338275K-> 4614K (341504K)] seems to be larger. The memory burst after a period of time, causing the tomcat to stop failing.