

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

# 管理 Amazon OpenSearch Serverless 集合群組
<a name="manage-collection-group"></a>

建立 Amazon OpenSearch Serverless 集合群組之後，您可以在需求變更時修改其設定。使用這些管理操作來更新容量限制和檢視集合群組詳細資訊。這些變更可協助您最佳化資源配置，並維持集合的高效率組織。

## 檢視集合群組
<a name="view-collection-groups"></a>

顯示您的 OpenSearch Serverless 集合群組，以檢閱其組態、相關聯的集合和目前狀態。

------
#### [ Console ]

1. 開啟位於 https：//[https://console.aws.amazon.com/aos/](https://console.aws.amazon.com/aos/) 的 Amazon OpenSearch Service 主控台。

1. 在左側導覽窗格中，選擇**無伺服器**，然後選擇**集合**

1. 選擇**集合群組索引標籤**。系統會顯示您帳戶的集合群組。

1.  選擇集合群組**的名稱**以顯示其詳細資訊。

------
#### [ AWS CLI ]
+ 使用 [list-collection-groups](https://docs.aws.amazon.com/cli/latest/reference/opensearchserverless/list-collection-groups.html) 命令列出您帳戶中的所有集合群組。使用 [batch-get-collection-group](https://docs.aws.amazon.com/cli/latest/reference/opensearchserverless/batch-get-collection-group.html) 命令來檢視特定集合群組的詳細資訊。在下列命令中，將*範例*內容取代為您自己的特定資訊。

  若要列出所有集合群組：

  ```
  aws opensearchserverless list-collection-groups
  ```

  若要取得特定集合群組的詳細資訊：

  ```
  aws opensearchserverless batch-get-collection-group \
      --names my-collection-group another-group
  ```

------

## 更新集合群組設定
<a name="update-collection-group"></a>

更新您的 OpenSearch Serverless 集合群組設定，以修改容量限制和描述等組態。

------
#### [ Console ]

1. 開啟位於 https：//[https://console.aws.amazon.com/aos/](https://console.aws.amazon.com/aos/) 的 Amazon OpenSearch Service 主控台。

1. 在左側導覽窗格中，選擇**無伺服器**，然後選擇**集合**

1. 選擇**集合群組索引標籤**。系統會顯示您帳戶的集合群組。

1.  選擇集合群組**的名稱**以顯示其詳細資訊。

1. 在**集合群組詳細資訊**中，選擇**編輯**。

1. 進行任何變更，然後選擇**儲存**。

------
#### [ AWS CLI ]
+ 使用 [update-collection-group](https://docs.aws.amazon.com/cli/latest/reference/opensearchserverless/update-collection-group.html) 命令更新現有集合群組的描述和容量限制。在下列命令中，將*範例*內容取代為您擁有的資訊。

  ```
  aws opensearchserverless update-collection-group \
      --id abcdef123456 \
      --description "Updated description for production workloads" \
      --capacity-limits maxIndexingCapacityInOCU=30,maxSearchCapacityInOCU=30,minIndexingCapacityInOCU=4,minSearchCapacityInOCU=4
  ```

------

容量限制的變更會立即生效，並可能影響群組中集合的擴展行為。

## 刪除集合群組
<a name="delete-collection-group"></a>

您必須先從群組中移除所有集合，才能刪除集合群組。您無法刪除包含集合的集合群組。

------
#### [ Console ]

1. 開啟位於 https：//[https://console.aws.amazon.com/aos/](https://console.aws.amazon.com/aos/) 的 Amazon OpenSearch Service 主控台。

1. 在左側導覽窗格中，選擇**無伺服器**，然後選擇**集合**

1. 選擇**集合群組索引標籤**。系統會顯示您帳戶的集合群組。

1.  選擇您要刪除的集合群組**名稱**。
**重要**  
透過更新每個集合以移除集合群組關聯，或將集合移至其他集合群組，從集合群組移除所有集合。

1. 在頁面頂端，選擇 **Delete (刪除)**。

1. 確認刪除，然後選擇**刪除**。

------
#### [ AWS CLI ]
+ 使用 [delete-collection-group](https://docs.aws.amazon.com/cli/latest/reference/opensearchserverless/delete-collection-group.html) 命令來刪除集合群組。
**重要**  
透過更新每個集合以移除集合群組關聯，或將集合移至其他集合群組，從集合群組移除所有集合。

  在下列命令中，將*範例*內容取代為您擁有的資訊。

  刪除空的集合群組：

  ```
  aws opensearchserverless delete-collection-group \
      --id abcdef123456
  ```

------