How to recreate a terminated cluster with a backup entry using the same name?

I had a cluster that was created with Keep existing snapshots after termination to On (I could not find the option on the UI, but I did manage to enable it using the option in the atlas terraform provider). After I terminated the cluster, the backup remains as expected, but I could not create the cluster with the same name anymore, and the atlas API on terraform returns the following errors:

error creating MongoDB ClusterAdvanced: POST https://cloud.mongodb.com/api/atlas/v1.5/groups//clusters: 400 (request “ATLAS_GENERAL_ERROR”) Reason: There are active backup snapshots for a cluster with name development in group . Please choose another name…

I removed all the snapshot in the backup entry itself, but the entry remains so I could not create the cluster with the same name.
image

After the weekend, I came back and saw that the entry is now gone, so there’s some mechanism that trigger the deletion. I’m not sure what it is however, and I think this should be documented somewhere as I could not found any.

Hi @Phong_Nguyen2 - Welcome to the community :wave:

I believe the option pops up when you try to terminate a cluster (within the green box):


Note: Image is example from my test environment

Were you able to see this from the UI when trying terminating a cluster?

Sounds like the issue mentioned above is that you’ve terminated all backups associated with the terminated cluster but aren’t able to re-create a new cluster with the same name as it still exists under the Backup section. Is this correct?

If so, I tried testing the following:

  1. Created a cluster with backups enabled
  2. Took an on-demand snapshot
  3. Terminated the cluster associated with step 1.
  4. Checked that the backups still existed (from the Backup section). They still were there.
  5. Terminated all backups associated with the cluster created from step 1.
  6. Checked the Backup tab to see if it was still there. It was (Cluster0 for reference):
  7. After waiting ~5 minutes and refreshing, the Cluster0 disappeared from the Backup section shown above in Step 6:

I will try find out how long this generally takes but for me, it seems to have taken only a few minutes on my own test Atlas project (assuming all backups associated with the cluster in question were terminated).

Regards,
Jason

So if I understand correctly, to delete the backup entry I’ll have to delete all the snapshot and wait for some time. Thanks for the help.

1 Like

In terms of “Backup entry”, I believe you are referring to the cluster name which shows up in the Backup tab under the Security section of the Atlas UI (On the left hand side). If so, then yes based off my testing, after removing the snapshots within that “Backup entry” (i.e. the terminated cluster name) and waiting a few minutes the entry itself will be removed so that you can create your new cluster with that name.

Regards,
Jason

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.