

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 刪除 Amazon Aurora 全域資料庫
<a name="aurora-global-database-deleting"></a>

 因為 Aurora 全域資料庫通常包含關鍵業務資料，您不能在單一步驟中刪除全域資料庫和相關聯的叢集。若要刪除 Aurora 全域資料庫，請執行下列動作：
+ 從 Aurora 全域資料庫移除所有次要資料庫叢集。每個叢集都會變成獨立 Aurora 資料庫叢集。若要瞭解如何操作，請參閱[從 Amazon Aurora 全域資料庫中移除叢集](aurora-global-database-detaching.md)。
+ 從每個獨立 Aurora 資料庫叢集中，刪除所有 Aurora 複本。
+ 從 Aurora 全域資料庫移除主要資料庫叢集。這會成為獨立 Aurora 資料庫叢集。
+ 從 Aurora 主要資料庫叢集中，先刪除所有 Aurora 複本，然後刪除寫入器資料庫執行個體。

 從新獨立的 Aurora 資料庫叢集刪除寫入器執行個體，通常也會移除 Aurora 資料庫叢集和 Aurora 全域資料庫。

 如需一般詳細資訊，請參閱[從 Aurora 個體資料庫叢集刪除資料庫執行個體](USER_DeleteCluster.md#USER_DeleteInstance)。

 若要刪除 Aurora 全域資料庫，您可以使用 AWS 管理主控台 AWS CLI、 或 RDS API。

## 主控台
<a name="aurora-global-database-deleting.console"></a>

**刪除 Aurora 全域資料庫**

1. 登入 AWS 管理主控台 ，並在 [https://console.aws.amazon.com/rds/](https://console.aws.amazon.com/rds/)：// 開啟 Amazon RDS 主控台。

1. 選擇 **Databases** (資料庫)，然後在清單中尋找您要刪除的 Aurora 全域資料庫。

1. 請確認已從 Aurora 全域資料庫中移除所有叢集。Aurora 全域資料庫應顯示 0 個區域和可用區域，以及大小為 0 的叢集。

   如果 Aurora 全域資料庫包含任何 Aurora 資料庫叢集，則無法將其刪除。如有必要，請從 Aurora 全域資料庫中卸離主要和次要 Aurora 資料庫叢集。如需更多詳細資訊，請參閱 [從 Amazon Aurora 全域資料庫中移除叢集](aurora-global-database-detaching.md)。

1. 在清單中選擇您的 Aurora 全球資料庫，然後從**動作**功能表中選擇**刪除**。  
![以 Aurora MySQL 5.6.10a 為基礎的 Aurora 全域資料庫會保留在 中， AWS 管理主控台 直到您刪除它為止，即使它沒有任何相關聯的 Aurora 資料庫叢集。](http://docs.aws.amazon.com/zh_tw/AmazonRDS/latest/AuroraUserGuide/images/aurora-global-db-ams5610a-delete-empty-cluster.png)

## AWS CLI
<a name="aurora-global-database-deleting.cli"></a>

若要刪除 Aurora 全域資料庫，請使用 的名稱 AWS 區域 和 Aurora 全域資料庫識別符執行 [delete-global-cluster](https://docs.aws.amazon.com/cli/latest/reference/rds/delete-global-cluster.html) CLI 命令，如下列範例所示。

針對 Linux、macOS 或 Unix：

```
aws rds --region {{primary_region}} delete-global-cluster \
   --global-cluster-identifier {{global_database_id}}
```

在 Windows 中：

```
aws rds --region {{primary_region}} delete-global-cluster ^
   --global-cluster-identifier {{global_database_id}}
```

## RDS API
<a name="aurora-global-database-deleting.api"></a>

若要刪除屬於 Aurora 全域資料庫的叢集，請執行 [ DeleteGlobalCluster](https://docs.aws.amazon.com/AmazonRDS/latest/APIReference/API_DeleteGlobalCluster.html) API 操作。