Forums

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

How to delete multiple plans in bamboo ?

SunadhRaj.Malaka June 7, 2023

I want to delete multiple plans from my server .

can any one suggest me how i can follow the steps.

 

 

Thanks

Raj

5 answers

1 vote
Sushant Verma
Community Champion
June 7, 2023

@SunadhRaj.Malaka As from screenshot, you are getting 401 error. Please check if credentials are fine or also, please check below:

  1. Confirm the URL Is Correct. This might sound obvious, but the 401 error code might appear if the user entered the wrong URL in the browser's address bar.
  2. Clear User End Issues.
  3. Check Authentication Credentials.
  4. Disable Password Protection.
  5. Troubleshoot the Code.

You can also follow this doc : https://confluence.atlassian.com/bamkb/how-to-delete-bamboo-projects-and-plans-in-bulk-using-rest-api-1216583450.html

You be honest, I am not sure about Rest API's. Might be above solutions will help you or you can also raise the ticket with Atlassian via https://support.atlassian.com/

Regards,
Sushant Verma

1 vote
Sushant Verma
Community Champion
June 7, 2023

Hi @SunadhRaj.Malaka 

Welcome to the community!

Deleting a plan deletes everything related to that plan, including the plan's configuration, all of the plan's job configurations and the plan's branch plans, job build results, artifacts, labels, and comments:

  • (warning) Deleting a plan also deletes its branch plans. Be careful!
  • The Admin global permission is required to delete a plan.
  • A plan that is currently being built cannot be deleted. If you need to delete such a plan, stop the plan's build first. Refer to Stopping an active build for more information.
  • Bamboo cleans up everything related to deleted plans every two minutes. You'll have to wait at least that long if you want to reuse the key from a deleted plan.
  • If you need to keep a permanent record of the job build results for your plan, see Exporting data for backup.


There are two ways to delete a plan:

  • From the dashboard:
    1. Go to Builds > All build plans and select the plan's name.
    2. Select Actions > Configure plan.
    3. Select Actions > Delete plan.
  • In the Administration console:
    1. From the Bamboo header select  > Plans.
    2. Select Remove plans in the left navigation column.
    3. Choose the plan you wish to delete.
    4. Select Delete at the bottom of the list. You will be prompted to confirm the deletion.

These doc will help you more : https://confluence.atlassian.com/bamboo/disabling-or-deleting-a-plan-289276855.html

Regards,
Sushant Verma

0 votes
SunadhRaj.Malaka June 11, 2023

we have around 30000+ plans

0 votes
SunadhRaj.Malaka June 7, 2023

Thank Yo so much Sushant

0 votes
SunadhRaj.Malaka June 7, 2023

i want to delete from REST API , i am trying with this below rest api  and facing some the issue attached can you guide me on this .

REET API 

#
# Marks plan for deletion. Plan will be deleted by batch job.
#
# replace {username}
# replace {planKey}, e.g PROJ-PLAN
# replace http://localhost:8085 with URL to access Bamboo

curl -k -u {username} \
-H 'X-Atlassian-Token: no-check' \
-H 'Accept: application/json' \
-H 'Content-Type: application/x-www-form-urlencoded' \
-d 'buildKey={planKey}' \
-X POST 'http://localhost:8085/chain/admin/deleteChain!doDelete.action'2

 

error is attached ex.PNG

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events