Hello,
I have a Multiwiki site hosted in a t2.medium Amazon EC2 Instance (2CPU, 4GB RAM).
The structure of my xwiki is this:
- xwiki 10.8
- Server version: Apache Tomcat/8.5.30 (Ubuntu)
- JVM Version: 1.8.0_181-8u181-b13-1ubuntu0.18.04.1-b13
- 7 Subwikis
- 10 Global users (This users authenticate throught the wiki using LDAP plugin https://extensions.xwiki.org/xwiki/bin/view/Extension/LDAP/Authenticator/)
- 16 Local users (distribuited on the subwikis)
The problem is after some time of use I always recieve an out of memory exception, that freezes the app and that error reflects on the logs of tomcat8 (/var/log/tomcat8/catalina.out):
java.lang.OutOfMemoryError: Java heap space
Exception in thread "ContainerBackgroundProcessor[StandardEngine[Catalina]]" java.lang.OutOfMemoryError: Java heap space
Exception in thread "ContainerBackgroundProcessor[StandardEngine[Catalina]]" java.lang.OutOfMemoryError: Java heap space
My Java Opts are these:
JAVA_OPTS="-Djava.awt.headless=true -XX:+UseConcMarkSweepGC -Xmx3584m"
When this error comes, the only workaround fix that I have is reboot the tomcat8 service (sudo service tomcat8 restart
)
Is there any recommendation on the JAVA_OPTS to make this doesn’t happen a lot?
Regards.