Bamboo Data Center Remote Agent installation: Solving security token authentication errors

Still need help?

The Atlassian Community is here for you.

Ask the community

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

When attempting to install a Bamboo Agent with the security token option enabled, the installation may fail with different messages.

Environment

This issue has been observed with Bamboo version 9.2.13, but is also applicable to other Bamboo versions.

Diagnosis

The following errors can be observed during the Bamboo Agent installation process:

  • When no security token is provided:

    Security token is required for preliminary authentication, but none was provided. Please obtain the token from https://bamboo-url.com/admin/agent/addRemoteAgent.action
  • When an incorrect security token provided:

    Security token verification failed. Please obtain the correct token from https://bamboo-url.com/admin/agent/addRemoteAgent.action

Cause

In Bamboo, there is an option to enable security token verification during the Agent installation process. When this option is enabled, a valid security token must be provided during the Agent installation.

Solution

Option 1:

  1. Get the valid security token by navigating to Bamboo administration > Build resources > Agents > Install remote agent page.

  2. Validate the value set for the parameter wrapper.app.parameter.3 in the <bamboo-agent-home>/conf/wrapper.conf file.
    1. If the value is incorrect, modify it to add the token obtained on Step 1.
    2. If the parameter is missing from the file, add a new line following the wrapper.app.parameter.2 entry:

      wrapper.app.parameter.3=<VALID_SECURITY_TOKEN>
  3. After updating the valid security token, restart the Bamboo Agent.

Option 2:

  1. Stop the Bamboo Agent and delete the <AGENT_HOME_DIR>
  2. Install the Bamboo Agent by executing the following command:

    $ java -Dbamboo.home=<AGENT_HOME_DIR> -jar atlassian-bamboo-agent-installer-<BAMBOO_VERSION>.jar <BAMBOO_URL>/agentServer/ -t <TOKEN>
  3. Replace the key values above with: 
    • <AGENT_HOME_DIR> - The Agent's home directory

    • <BAMBOO_VERSION> - The Bamboo version
    • <BAMBOO_URL> - The Bamboo server's URL

    • <TOKEN> - The valid security token by navigating to Bamboo administration > Build resources > Agents > Install remote agent


Known Bug

The Agent installation instructions provided in the Bamboo UI may have a missing security token property -t <TOKEN>. That missing option will cause the Agent installation to fail. Make sure to add the -t <TOKEN> option when installing the Agent with a security token. There is a known bug BAM-25913 - Getting issue details... STATUS associated with this issue.


By following these steps, you should be able to successfully install the Bamboo Agent with the security token option enabled. If you continue to experience issues, please consult the Bamboo documentation or contact support for assistance.

Last modified on Oct 24, 2024

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.