Increase Stack Size

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

Symptoms

Need to increase the Stack Size; 'ulimit -s'. Increase the permitted number of stack size per thread for the Bamboo user and/or whole system. These setting may vary between operating systems, so you may need to talk to your system administrator or do your own research. We'll describe the most common approach to troubleshooting and fixing this problem.

Resolution based on the limits.conf file

To check the permitted stack size per thread, run ulimit -s

To modify the permitted stack size per thread, edit /etc/security/limits.conf and add (replacing Bamboo_USER with the name of the user running Bamboo or * for all users):

1 2 Bamboo_USER soft stack 40000 Bamboo_USER hard stack 40000

Solution when installed as a systemd service

When Bamboo is installed as a systemd service you may need to update the service unit file as described below.

If you are sure Bamboo is running as a systemd service, go straight to Step 2.

  1. Check if Bamboo is configured as a systemd service. This helps to identify if this is the case and the service name, in case you are not sure.

    1 grep -i bamboo/etc/systemd/system/*.service /lib/systemd/system/*.service

    In this example, the name of our service is bamboo.service, which is the name of the unit file itself and is located in the standard folder /etc/systemd/system.

  2. Edit the service unit file (/etc/systemd/system/bamboo.service in our example) and add the following line.

    1 LimitSTACK=40000
  3. Reboot the server.

Updated on April 24, 2025

Still need help?

The Atlassian Community is here for you.