Amazon DocumentDB
Developer Guide

Step 4: (Optional) Delete the Amazon DocumentDB Instance and Cluster

If you are no longer using your Amazon DocumentDB cluster, you should delete it so that you aren't charged for resources that you're not using.

Deleting a cluster is a non-stoppable, non-reversable action. Unless you create a final snapshot, your data will be lost when you delete the cluster.

Using the AWS Management Console

To delete a cluster with instances

  1. Open the Amazon DocumentDB console at https://console.aws.amazon.com/docdb.

  2. In the navigation pane, choose Instances.

  3. Choose your Amazon DocumentDB instance. Choose Actions, and then choose Delete. In the confirmation dialog box, type delete me, then choose Delete.

    Deleting the last instance

    Because deleting the last instance also deletes the cluster, for the cluster's last instance the confirmation dialog requires responses for the following:

    1. Create final cluster snapshot?: Choose Yes to create a final snapshot before deleting the cluster, or choose No to delete the cluster without creating a final snapshot.

    2. Final snapshot name: If you chose Yes, either accept the name provided by Amazon DocumentDB for your final snapshot, or type another name.

    3. If you chose No for creating a final snapshot, read and acknowledge the paragraph that describes what will not be available to you after the cluster is deleted.

    4. Type delete entire cluster.

  4. To delete the cluster and stop incurring charges, choose Delete. To retain the cluster, choose Cancel.

If your cluster does not have any instances, delete the cluster.

To delete a cluster that does not have any instances

  1. In the navigation pane, choose Clusters. Then in the list of clusters, choose the button to the left of the name of the cluster that you want to delete.

  2. In the Actions menu, choose Delete.

  3. In the Delete <cluster-name> dialog box, do the following:

    1. Create final cluster snapshot?: Choose Yes to create a final snapshot before deleting the cluster, or choose No to delete the cluster without creating a final snapshot.

    2. Final snapshot name: If you chose Yes, either accept the name provided by Amazon DocumentDB for your final snapshot, or type another name.

    3. If you chose No for creating a final snapshot, read and acknowledge the paragraph that describes what will not be available to you after the cluster is deleted.

    4. Type delete entire cluster.

  4. To delete the cluster and stop incurring charges, choose Delete. To retain the cluster, choose Cancel.

  5. Optionally, monitor the status of your cluster.

    aws docdb describe-db-clusters \ --query 'DBClusters[*].[DBClusterIdentifier,Status]'