Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Docker Jira

Ersin Cetin
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
October 17, 2019

I created a container for Jira Service desk on a VM. We have other containers running there and they are working fine. The VM has 5GB (from 12GB) free memory.

 

The install is working fine (I used the official docker files). When I start the container it is initializing and as soon the memory reaches 1GB the container crashes and starts again. I asume that there needs to be done some memory adjustments for Java, but I tried everything. 

There is that entry in the log:

OpenJDK 64-Bit Server VM warning: INFO: os::commit_memory(0x00007f6cc5b0b000, 262144, 0) failed; error='Cannot allocate memory' (errno=12),
2019-10-17T12:06:08.535581200Z #,
2019-10-17T12:06:08.536559400Z # There is insufficient memory for the Java Runtime Environment to continue.,
2019-10-17T12:06:08.538557300Z # Native memory allocation (mmap) failed to map 262144 bytes for committing reserved memory.,
2019-10-17T12:06:08.540559200Z # Can not save log file, dump to screen..,
2019-10-17T12:06:08.540559200Z #,
2019-10-17T12:06:08.540559200Z # There is insufficient memory for the Java Runtime Environment to continue.,
2019-10-17T12:06:08.540559200Z # Native memory allocation (mmap) failed to map 262144 bytes for committing reserved memory.,
2019-10-17T12:06:08.541572100Z # Possible reasons:,
2019-10-17T12:06:08.541572100Z # The system is out of physical RAM or swap space,
2019-10-17T12:06:08.541572100Z # The process is running with CompressedOops enabled, and the Java Heap may be blocking the growth of the native heap,
2019-10-17T12:06:08.541572100Z # Possible solutions:,
2019-10-17T12:06:08.541572100Z # Reduce memory load on the system,
2019-10-17T12:06:08.541572100Z # Increase physical memory or swap space,
2019-10-17T12:06:08.541572100Z # Check if swap backing store is full,
2019-10-17T12:06:08.541572100Z # Decrease Java heap size (-Xmx/-Xms),
2019-10-17T12:06:08.541572100Z # Decrease number of Java threads,
2019-10-17T12:06:08.541572100Z # Decrease Java thread stack sizes (-Xss),
2019-10-17T12:06:08.542573800Z # Set larger code cache with -XX:ReservedCodeCacheSize=,
2019-10-17T12:06:08.542573800Z # JVM is running with Zero Based Compressed Oops mode in which the Java heap is,
2019-10-17T12:06:08.542573800Z # placed in the first 32GB address space. The Java Heap base address is the,
2019-10-17T12:06:08.542573800Z # maximum limit for the native heap growth. Please use -XX:HeapBaseMinAddress,
2019-10-17T12:06:08.542573800Z # to set the Java Heap base and to place the Java Heap above 32GB virtual address.,
2019-10-17T12:06:08.542573800Z # This output file may be truncated or incomplete.,
2019-10-17T12:06:08.542573800Z #,
2019-10-17T12:06:08.544573700Z # Out of Memory Error (os_linux.cpp:2754), pid=8, tid=0x00007f6cd01ff700,

 

I used eg. this:

docker run --memory=3G -e Xmx=400m -e XX:MaxRAM=2g -e XX:-UseContainerSupport --restart always -d -v Jira:/var/atlassian/application-data/jira --name="jira" -d -p 8080:8080 atlassian/jira-software

 

What am I doing wrong?

1 answer

0 votes
Dave Chevell
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 25, 2020

Hey @Ersin Cetin ,

 

Sounds like you need to increase the memory for the JVM.

In our official Docker images for Jira, Confluence, Bitbucket Server and Crowd, you can set the environment variables JVM_MINIMUM_MEMORY and JVM_MAXIMUM_MEMORY which correspond to the Xms and Xmx flags. 

For example:

docker run -d -e JVM_MAXIMUM_MEMORY=2g -p 8080:8080 atlassian/jira-software

I hope that helps!

Cheers

Dave

Suggest an answer

Log in or Sign up to answer