Container Options in AWS Elastic Beanstalk
- by Sangram Anand
We have deployed a java webapplication in Elastic Beanstalk with the minimum instance count 1 and max instance count 2 for Autoscaling. The custom AMI we are using is c1.medium with Sun JDK 6.
The environment status changed to yellow and then red. After checking into the log file from the snapshot logs we found a exception - Caused by: java.lang.OutOfMemoryError: Java heap space. Assuming this could be one of the possible reason for the Environment failure.
The settings that we have configured in the Environment Container option are
Initial JVM Heap Size (MB) - 256M
Maximum JVM Heap Size (MB) - 512m
The maximum heap size the java virtual machine will ever consume, specified on the JVM launch command line using -Xmx.
Maximum JVM Permanent Generation Size (MB) - 512m
Should i increase the Heap size from 512m to more or is it fine.