Crowd as linux service does not kill PID

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

Summary

Problem

If you installed Crowd as a service on Linux, and found that the process is not being killed, you can try the following:

  1. If you are running Crowd 2.8.3 and below, make sure to upgrade to Crowd 2.8.4 or later (includes fix for CWD-4423 - Crowd's Tomcat setenv.sh misses CATALINA_PID variable)

  2. Crowd documentation on Setting Crowd to Run Automatically and Use an Unprivileged System User on UNIX is a bit outdated compared to Confluence and JIRA. I opened a feature request for it CWD-4702 - Improve Setting Crowd to Run Automatically Documentation.

  3. First recommendation is to migrate Crowd apache service script to look like Confluence or Jira

  4. Save and try the script again

  5. You might encounter a problem where the process is not killed from the first attempt.

    1 service crowd stop

    Running the stop command another time will finally kill the process.

Diagnosis

Diagnostic Steps

  • You could try increasing the wait time for the gracefull shutdown (5 seconds is the default value) to something like 30 seconds

    1 stop-crowd.sh 30

Cause

The thread dumps show that there are multiple threads locked waiting for others. 30 seconds delay did not help to gracefully shutdown crowd.

Solution

Workaround

A workaround is to force the script to shutdown Crowd (killing the process.) In order to do that, modify the tomcat service script to force the process kill

1 stop-crowd.sh -force

The force flag will execute kill -9 on the PID and Crowd process will be killed.

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.