Jira on Docker startup failure with lock error

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

The content on this page relates to platforms which are not supported. Consequently, Atlassian Support cannot guarantee providing any support for it. Please be aware that this material is provided for your information only and using it is done so at your own risk.

Problem

Jira running on Docker fails to start due to the 'jira.home' directory locking mechanism.

For non-docker environments, please see our Archive "JIRA has been locked" error when starting Jira Server or Data Center article.

(Auto-migrated image: description temporarily unavailable)

Cause

  1. The docker container is killed too quickly with the 'docker stop' command.

  2. The docker container is shutdown forcibly.

Resolution

The '--time' parameter/flag can be passed into the 'docker stop' command to allow additional time before the container is killed.

We found a timeout of between 60-90 seconds provides the necessary time for a graceful Jira shutdown.

1 docker stop ContainerName --time 60

AWS ECS

ECS utilizes the StopTask API endpoint which is the equivalent of 'docker stop'. This results in a SIGTERM with a 30-second timeout, after which SIGKILL is sent and the container(s) are forcibly shutdown.

The 30-second timeout can be adjusted on the container agent with the 'ECS_CONTAINER_STOP_TIMEOUT' variable.

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.