

• 2026 年 4 月 30 日之後， AWS Systems Manager CloudWatch Dashboard 將不再可用。客戶可以繼續使用 Amazon CloudWatch 主控台來檢視、建立和管理其 Amazon CloudWatch 儀表板，就像現在一樣。如需詳細資訊，請參閱 [Amazon CloudWatch Dashboard 文件](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Dashboards.html)。

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

# AWS Systems Manager 操作工具
<a name="systems-manager-ops-center"></a>

操作工具是一套功能，可協助您管理 AWS 資源。
+ [Systems Manager 託管的 Amazon CloudWatch 儀表板](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-cloudwatch-dashboards.html)是 CloudWatch 主控台中的可自訂首頁，可讓您於單一檢視中跨 AWS 區域監控資源。
+ [https://docs.aws.amazon.com/systems-manager/latest/userguide/Explorer.html](https://docs.aws.amazon.com/systems-manager/latest/userguide/Explorer.html) 是可自訂的操作儀表板，可報告 AWS 資源的相關資訊。Explorer 會顯示您 AWS 帳戶 和跨 AWS 區域 的操作資料 (OpsData) 的彙整檢視。
+ [Incident Manager](https://docs.aws.amazon.com/incident-manager/latest/userguide/what-is-incident-manager.html) 可協助您減輕事件對 AWS 託管的應用程式的影響並從中復原。
+ [https://docs.aws.amazon.com/systems-manager/latest/userguide/OpsCenter.html](https://docs.aws.amazon.com/systems-manager/latest/userguide/OpsCenter.html) 提供一個集中的位置，營運工程師和 IT 專業人員可在此檢視、調查和解決與 AWS 資源相關的操作工作項目 (OpsItems)。

**Topics**
+ [AWS Systems Manager Incident Manager](incident-manager.md)
+ [AWS Systems Manager Explorer](Explorer.md)
+ [AWS Systems Manager OpsCenter](OpsCenter.md)
+ [使用 Systems Manager 託管的 Amazon CloudWatch 儀表板](systems-manager-cloudwatch-dashboards.md)

# AWS Systems Manager Incident Manager
<a name="incident-manager"></a>

**Incident Manager 可用性變更**  
AWS Systems Manager Incident Manager 自 2025 年 11 月 7 日起，不再向新客戶開放。如果您想要使用 Incident Manager，請在該日期之前註冊。現有客戶可以繼續正常使用服務。如需詳細資訊，請參閱[AWS Systems Manager Incident Manager 可用性變更](https://docs.aws.amazon.com/incident-manager/latest/userguide/incident-manager-availability-change.html)。

使用 中的工具 Incident Manager AWS Systems Manager來管理 AWS 託管應用程式中發生的事件。Incident Manager 結合使用者參與、提升、Runbook、回應計劃、聊天頻道和事件後分析，可協助您的團隊更快地分類事件，並將應用程式回復為正常。若要進一步了解 Incident Manager，請參閱[《Incident Manager 使用者指南》](https://docs.aws.amazon.com/incident-manager/latest/userguide/what-is-incident-manager.html)。

# AWS Systems Manager Explorer
<a name="Explorer"></a>

AWS Systems Manager Explorer 是可自訂的操作儀表板，可報告 AWS 資源的相關資訊。 Explorer會顯示您 AWS 帳戶 和 之間的操作資料 (OpsData) 彙總檢視 AWS 區域。在 Explorer 中，OpsData 包含有關[混合多雲端](operating-systems-and-machine-types.md#supported-machine-types)環境中受管節點的中繼資料。OpsData 也包含 Systems Manager 其他工具提供的資訊，包括 Patch Manager 修補程式合規和 State Manager 關聯合規詳細資訊。為了進一步簡化您存取 OpsData 的方式， Explorer會顯示支援服務的資訊 AWS Config， AWS 例如 AWS Trusted Advisor AWS Compute Optimizer和 AWS 支援 （支援案例）。

為提高營運意識，Explorer 也會顯示營運工作項目 (OpsItems)。Explorer 會提供 OpsItems 如何在您的業務單位或應用程式中分散、隨著時間的趨勢，以及如何因類別而異的相關內容。您可以在 Explorer 中群組和篩選資訊，以專注於與您相關且需要採取動作的項目。當您發現高優先順序的問題時，您可以使用 Systems Manager OpsCenter 來執行Automation Runbook，並快速解決這些問題。若要開始使用 Explorer，請開啟 [Systems Manager 主控台](https://console.aws.amazon.com//systems-manager/explorer)。在導覽窗格中，選擇 **Explorer**。

下列影像顯示一些個別的報告方塊，稱為 *Widget*，可在 Explorer 中使用。

![\[Explorer 中的儀表板 AWS Systems Manager\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/Explorer-1-overview.png)


## Explorer 有哪些功能？
<a name="Explorer-learn-more-features"></a>

Explorer 包含下列功能：
+ **可自訂顯示可操作資訊**： Explorer 包含drag-and-drop小工具。 會在兩種小工具類型中Explorer顯示資訊。 AWS 
  + **資訊小工具**：這些小工具摘要來自 Amazon EC2、State Manager、 Patch Manager和 AWS 服務 等支援 AWS Trusted Advisor、 AWS Compute Optimizer 和 的資料 支援。這些小工具提供重要的內容，協助您了解 AWS 資源的狀態和操作風險。資訊小工具的範例包括 **Instance count** (執行個體計數)、**Instance by AMI** (依 AMI 排序的執行個體)、**Total noncompliant nodes** (不合規節點總數) (修補程式)、**Noncompliant associations** (不合規關聯) 和 **Support Center cases** (支援中心案例)。
  + **OpsItem 小工具**：Systems Manager *OpsItem*是與一或多個 AWS 資源相關的操作工作項目。 OpsItems 是 Systems Manager 的一項功能OpsCenter。 OpsItems可能需要 DevOps 工程師調查並可能修復問題。可能的 OpsItems 範例包括 EC2 執行個體高 CPU 使用率、分離的 Amazon Elastic Block Store (Amazon EBS) 磁碟區、 AWS CodeDeploy 部署失敗或 Systems Manager 自動化執行失敗。OpsItem 小工具的範例包括 **開啟 OpsItem 摘要**、**依狀態的 OpsItem**，以及**隨著時間的 OpsItems**。
+ **篩選條件**：每個小工具都能夠根據 AWS 帳戶 AWS 區域和 標籤篩選資訊。篩選器可協助您快速精細化 Explorer 中顯示的資訊。
+ **服務畫面的直接連結**：為了協助您調查 AWS 資源的問題，Explorer小工具包含相關服務畫面的直接連結。如果您瀏覽至相關的服務畫面，對 Widget 套用的篩選器仍會有效。
+ **群組**：為協助您了解整個組織的操作問題類型，某些小工具允許您根據帳戶、區域和標籤來群組資料。
+ **報告標籤鍵**：設定 Explorer 時，可以指定最多五個標籤鍵。這些鍵可協助您在 Explorer 中群組和篩選資料。如果指定的鍵與產生 OpsItem 的資源上的鍵相符，則 OpsItems 中會包含該鍵和值。
+ ** AWS 帳戶 和 AWS 區域 顯示的三種模式**： Explorer包含下列 OpsData 和 和 OpsItems中的顯示模式 AWS 帳戶 AWS 區域：
  + *單一帳戶/單一區域*：這是預設檢視。此模式允許使用者檢視來自自己的帳戶和目前區域的資料和 OpsItems。
  + *單一帳戶/多重區域*：此模式需要您使用 Explorer **Settings (設定)** 頁面建立一或多個資源資料同步。資源資料同步會從一或多個區域彙總 OpsData。建立資源資料同步之後，您可以切換要在 Explorer 儀表板上使用的同步。然後，您可以根據區域篩選和群組資料。
  + *多重帳戶/多重區域*：此模式需要您的組織或公司使用 [AWS Organizations](https://docs.aws.amazon.com/organizations/latest/userguide/) 並開啟 **All features** (所有功能)。在 AWS Organizations 運算環境中設定 之後，您可以彙總管理帳戶中的所有帳戶資料。然後，您可以建立資源資料同步，以便根據區域篩選和群組資料。如需**所有功能**模式的詳細資訊，請參閱[啟用組織中的所有功能](https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org_support-all-features.html)。
+ **報告**：您可以將 Explorer 報告以逗號分隔值 (.csv) 檔案格式匯出至 Amazon Simple Storage Service (Amazon S3) 儲存貯體。匯出完成時，您會收到來自 Amazon Simple Notification Service (Amazon SNS) 的提醒。

## Explorer 如何與 OpsCenter 相關？
<a name="Explorer-learn-more-OpsCenter"></a>

[Systems Manager OpsCenter](OpsCenter.md) 提供中央位置，讓營運工程師和 IT 專業人員檢視、調查和解決與 AWS 資源OpsItems相關的問題。 Explorer 是一個報告中樞，DevOps 管理員可檢視其營運資料的彙總摘要OpsItems，包括跨 AWS 區域 和 帳戶。 Explorer可讓使用者探索趨勢和模式，並視需要使用 Systems Manager Automation Runbook 快速解決問題。

OpsCenter 安裝程式現在已與 Explorer 安裝程式整合。如果您已設定 OpsCenter，則 Explorer 會自動顯示操作資料，包括有關 OpsItems 的彙總資訊。如果您尚未設定 OpsCenter，則可以使用 Explorer 設定來開始使用這兩個工具。如需詳細資訊，請參閱[開始使用 Systems Manager Explorer 和 OpsCenter](Explorer-setup.md)。

## 什麼是 OpsData？
<a name="Explorer-learn-more-OpsData"></a>

OpsData 是 Systems Manager Explorer 儀表板中顯示的任何操作資料。Explorer 會從下列來源擷取 OpsData：
+ **Amazon Elastic Compute Cloud (Amazon EC2)**

  Explorer 中顯示的資料包括：節點總數、受管和非受管節點總數，以及使用特定 Amazon Machine Image (AMI) 的節點計數。
+ **Systems Manager OpsCenter**

  Explorer 中顯示的資料包括：依狀態的 OpsItems 計數、依嚴重性的 OpsItems 計數、跨群組與 30 天期間開啟的 OpsItems 計數，以及隨時間的 OpsItems 歷史資料。
+ **Systems Manager Patch Manager**

  Explorer 中顯示的資料包括不合規節點和嚴重不合規節點的計數。
+ **AWS Trusted Advisor**

  Explorer 中顯示的資料包括：EC2 預留執行個體在成本最佳化、安全性、容錯能力、效能和服務限制等領域的最佳實務檢查狀態。
+ **AWS Compute Optimizer**

  Explorer 中顯示的資料包括 **Under provisioned (佈建不足)** 和 **Over provisioned (過度佈建)** 的 EC2 執行個體計數、最佳化問題清單、隨需定價詳情，以及執行個體類型和價格的建議。
+ **支援 中心案例**

  Explorer 中顯示的資料包括：案例 ID、嚴重性、狀態、建立時間、主旨、服務和類別。
+ **AWS Config**

  中顯示的資料Explorer包括：合規和不合規 AWS Config 規則的整體摘要、合規和不合規資源的數量，以及每個資源的特定詳細資訊 （當您深入了解不合規規則或資源時）。
+ **AWS Security Hub CSPM**

  中顯示的資料Explorer包括：Security Hub CSPM 調查結果的整體摘要、依嚴重性分組的每個調查結果數量，以及有關調查結果的特定詳細資訊。

**注意**  
若要在 中檢視 AWS Trusted Advisor 和 支援 置中案例Explorer，您必須設定企業或企業帳戶 AWS 支援。

您可以從 Explorer 的 **Settings** (設定) 頁面檢視和管理 OpsData 來源。如需設定和配置使用 OpsData 填入 Explorer Widget 之服務的詳細資訊，請參閱[設定 Explorer 的相關服務](Explorer-setup-related-services.md)。

## 使用 Explorer 需要付費嗎？
<a name="Explorer-learn-more-cost"></a>

是。當您開啟在整合式設定期間建立 OpsItems 的預設規則時，您會啟動自動建立 OpsItems 的程序。我們會根據每月建立的 OpsItems 數量向您的帳戶收費。也會根據每月進行的 `GetOpsItem`、`DescribeOpsItem`、`UpdateOpsItem` 和 `GetOpsSummary` API 呼叫次數向您收費。此外，您可能需要就向可公開相關診斷資訊的其他服務的公有 API 呼叫支付費用。如需詳細資訊，請參閱 [AWS Systems Manager 定價](https://aws.amazon.com/systems-manager/pricing/)。

**Topics**
+ [Explorer 有哪些功能？](#Explorer-learn-more-features)
+ [Explorer 如何與 OpsCenter 相關？](#Explorer-learn-more-OpsCenter)
+ [什麼是 OpsData？](#Explorer-learn-more-OpsData)
+ [使用 Explorer 需要付費嗎？](#Explorer-learn-more-cost)
+ [開始使用 Systems Manager Explorer 和 OpsCenter](Explorer-setup.md)
+ [使用 Explorer](Explorer-using.md)
+ [從 Systems Manager Explorer 匯出 OpsData](Explorer-exporting-OpsData.md)
+ [Systems Manager Explorer 故障診斷](Explorer-troubleshooting.md)

# 開始使用 Systems Manager Explorer 和 OpsCenter
<a name="Explorer-setup"></a>

AWS Systems Manager 使用整合式設定體驗來協助您開始使用 Systems Manager Explorer 和 Systems Manager OpsCenter。在本文件中，Explorer 和 OpsCenter 設定稱為*整合式設定*。如果已設定 OpsCenter，您仍然需要完成整合式設定，以確認設定和選項。如果您尚未設定 OpsCenter，則可以使用整合式設定來開始使用這兩個工具。

**注意**  
整合式設定僅適用於 Systems Manager 主控台。您無法以程式設計方式設定 Explorer 或 OpsCenter。

整合式設定會執行下列任務：
+ [設定角色和許可](Explorer-setup-permissions.md)：整合式設定會建立 AWS Identity and Access Management (IAM) 角色，讓 Amazon EventBridge 根據預設規則自動建立 OpsItems。設定之後，您必須如本節所述，為 OpsCenter 設定使用者、群組或角色許可。
+ [允許 OpsItem 建立的預設規則](Explorer-setup-default-rules.md)：整合式設定會在 EventBridge 中建立預設規則。這些規則會自動建立 OpsItems 以回應事件。這些事件的範例包括：AWS 資源的狀態變更、安全設定的變更，或服務無法使用。
+ 啟用 OpsData 來源：整合式設定會啟用以下可填入 Explorer 小工具的資料來源。
  + 支援 中心 (您必須擁有商業或企業支援方案，才能啟動此來源。)
  + AWS Compute Optimizer (您必須擁有商業或企業支援方案，才能啟動此來源。)
  + Systems Manager State Manager 關聯合規
  + AWS Config 合規
  + Systems Manager OpsCenter
  + Systems Manager Patch Manager 修補程式合規
  + Amazon Elastic Compute Cloud (Amazon EC2)
  + Systems Manager 庫存
  + AWS Trusted Advisor (您必須擁有商業或企業支援方案，才能啟動此來源。)
  + AWS Security Hub CSPM

**注意**  
您可以隨時在 **Settings (設定)** 頁面上變更設定組態。

完成整合式設定之後，建議您[設定 Explorer 以顯示來自多個區域和帳戶的資料](Explorer-resource-data-sync.md)。Explorer 和 OpsCenter 會自動為您在完成整合式設定時所使用的 AWS 帳戶 和 AWS 區域 同步 OpsData 以及 OpsItems。您可以透過建立資源資料同步來彙總來自其他帳戶和區域的 OpsData 及 OpsItems。

# 設定 Explorer 的相關服務
<a name="Explorer-setup-related-services"></a>

AWS Systems Manager 從其他 和 AWS Systems Manager OpsCenter Systems Manager 工具中探索 AWS 服務 和收集資訊，或與之互動。建議您在使用整合式設定之前，先設定和配置這些其他服務或工具。

下表包含允許 Explorer和 從其他 AWS 服務 和 Systems Manager 工具OpsCenter收集資訊或與之互動的任務。


****  

| 任務 | 資訊 | 
| --- | --- | 
|  確認 Systems Manager 自動化中的許可  |  Explorer 和 OpsCenter 允許您使用 Systems Manager Automation Runbook 修正 AWS 資源的問題。若要使用此修復工具，您必須有執行 Systems Manager Automation 執行手冊的許可。如需詳細資訊，請參閱[設定自動化](automation-setup.md)。  | 
|  安裝和設定 Systems Manager Patch Manager  |  Explorer 包含可提供修補程式符合性相關資訊的 Widget。若要在 Explorer 中檢視此資料，您必須設定修補。如需詳細資訊，請參閱[AWS Systems Manager Patch Manager](patch-manager.md)。  | 
|  安裝和設定 Systems Manager State Manager  |  Explorer 包含可提供有關 Systems Manager State Manager 關聯合規資訊的小工具。若要在 Explorer 中檢視此資料，您必須設定 State Manager。如需詳細資訊，請參閱[AWS Systems Manager State Manager](systems-manager-state.md)。  | 
|  開啟 AWS Config 組態記錄器  |  Explorer 使用 AWS Config 組態記錄器提供的資料，將 EC2 執行個體的相關資訊填入小工具。若要在 中檢視此資料Explorer，請開啟 AWS Config 組態記錄器。如需詳細資訊，請參閱[管理組態記錄器](https://docs.aws.amazon.com/config/latest/developerguide/stop-start-recorder.html)。  您允許組態記錄器之後，最多可能需要六個小時的時間，Systems Manager 才能在 Explorer 小工具 (顯示有關 EC2 執行個體的資訊) 中顯示資料。   | 
|  開啟 AWS Trusted Advisor  |  Explorer 使用 提供的資料 Trusted Advisor ，在成本最佳化、安全性、容錯能力、效能和服務限制等領域顯示 Amazon EC2 預留執行個體的最佳實務檢查狀態。若要在 Explorer 檢視此資料，您必須擁有商業或企業支援方案。如需詳細資訊，請參閱[支援](https://aws.amazon.com/premiumsupport/)。  | 
|  開啟 AWS Compute Optimizer  |  Explorer 使用 Compute Optimizer 提供的資料來顯示**佈建不足**和**過度佈建**的 EC2 執行個體計數、最佳化問題清單、隨需定價詳細資訊，以及執行個體類型和價格的建議。若要在 Explorer 中檢視此資料，開啟 Compute Optimizer。如需詳細資訊，請參閱 [入門 AWS Compute Optimizer](https://docs.aws.amazon.com/compute-optimizer/latest/ug/getting-started.html)。  | 
|  開啟 AWS Security Hub CSPM  |  Explorer 使用 Security Hub CSPM 提供的資料，將安全性問題清單的相關資訊填入小工具。若要在 中檢視此資料Explorer，請開啟 Security Hub CSPM 整合。如需詳細資訊，請參閱[什麼是 AWS Security Hub CSPM](https://docs.aws.amazon.com/securityhub/latest/userguide/what-is-securityhub.html) 。  | 

# 設定 Systems Manager Explorer 的角色和許可
<a name="Explorer-setup-permissions"></a>

整合式設定會自動為 AWS Systems Manager Explorer 和 建立和設定 AWS Identity and Access Management (IAM) 角色 AWS Systems Manager OpsCenter。如果您已完成整合式設定，則不需要執行任何其他工作來設定 Explorer 的角色和許可。但是，您必須設定 OpsCenter 的許可，如本主題稍後所述。

整合式設定會建立和設定下列角色，以使用 Explorer 和 OpsCenter。
+ `AWSServiceRoleForAmazonSSM`︰提供由 Systems Manager 管理或使用的 AWS 資源存取權限。
+ `OpsItem-CWE-Role`：允許 CloudWatch Events 和 EventBridge 建立 OpsItems 以回應常見事件。
+ `AWSServiceRoleForAmazonSSM_AccountDiscovery`：允許 Systems Manager 在同步資料時呼叫其他 AWS 服務 以探索 AWS 帳戶 資訊。如需有關此角色的詳細資訊，請參閱 [使用 角色來收集 OpsCenter和 AWS 帳戶 的資訊 Explorer](using-service-linked-roles-service-action-2.md)。
+ `AmazonSSMExplorerExport`：允許 Explorer 將 OpsData 匯出至以逗號分隔值的 (CSV) 檔案。

如果您設定 使用 和資源資料同步Explorer來顯示來自多個帳戶 AWS Organizations 和區域的資料，則 Systems Manager 會建立`AWSServiceRoleForAmazonSSM_AccountDiscovery`服務連結角色。Systems Manager 使用此角色來取得 AWS 帳戶 中 的相關資訊 AWS Organizations。該角色會使用下列許可政策。

------
#### [ JSON ]

****  

```
{
   "Version":"2012-10-17",		 	 	 
   "Statement":[
      {
         "Effect":"Allow",
         "Action":[
            "organizations:DescribeAccount",
            "organizations:DescribeOrganization",
            "organizations:ListAccounts",
            "organizations:ListAWSServiceAccessForOrganization",
            "organizations:ListChildren",
            "organizations:ListParents"
         ],
         "Resource":"*"
      }
   ]
}
```

------

如需 `AWSServiceRoleForAmazonSSM_AccountDiscovery` 角色的詳細資訊，請參閱 [使用 角色來收集 OpsCenter和 AWS 帳戶 的資訊 Explorer](using-service-linked-roles-service-action-2.md)。

## 設定的 Systems Manager OpsCenter 的許可
<a name="Explorer-getting-started-user-permissions"></a>

完成整合式設定之後，您必須設定使用者、群組或角色許可，以便使用者在 OpsCenter 中執行動作。

**開始之前**  
可以將 OpsCenter 設定為建立和管理單一帳戶或跨多個帳戶的 OpsItems。如果您OpsCenter將 設定為OpsItems跨多個帳戶建立和管理，您可以使用 Systems Manager 委派管理員帳戶或 AWS Organizations 管理帳戶，在其他OpsItems帳戶中手動建立、檢視或編輯 。如需有關 Systems Manager 委派管理員帳戶的詳細資訊，請參閱[設定 Explorer 的委派管理員](Explorer-setup-delegated-administrator.md)。

如果您針對單一帳戶設定 OpsCenter，則只能在建立 OpsItems 的帳戶中檢視或編輯 OpsItems。您無法OpsItems跨 共用或傳輸 AWS 帳戶。因此，建議您在用來執行 AWS 工作負載 AWS 帳戶 的 OpsCenter中設定 的許可。然後，您就可以在該帳戶中建立 使用者或群組。利用這種方式，多位營運工程師或 IT 專業人員即可在相同的 AWS 帳戶中建立、檢視和編輯 OpsItems。

Explorer 和 OpsCenter 會使用下列 API 操作。如果使用者、群組或角色可以存取這些動作，您就可以使用 Explorer 和 OpsCenter 的所有功能。您也可以建立更嚴格的存取權，如本節前文所述。
+  [CreateOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateOpsItem.html) 
+  [CreateResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateResourceDataSync.html) 
+  [DescribeOpsItems](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DescribeOpsItems.html) 
+  [DeleteResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DeleteResourceDataSync.html) 
+  [GetOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsItem.html) 
+  [GetOpsSummary](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsSummary.html) 
+  [ListResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_ListResourceDataSync.html) 
+  [UpdateOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_UpdateOpsItem.html) 
+  [UpdateResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_UpdateResourceDataSync.html) 

您可以視需要將下列內嵌政策新增至帳戶、群組或角色，以指定唯讀許可。

------
#### [ JSON ]

****  

```
{
  "Version":"2012-10-17",		 	 	 
  "Statement": [
    {
      "Effect": "Allow",
      "Action": [
        "ssm:GetOpsItem",
        "ssm:GetOpsSummary",
        "ssm:DescribeOpsItems",
        "ssm:GetServiceSetting",
        "ssm:ListResourceDataSync"
      ],
      "Resource": "*"
    }
  ]
}
```

------

如需有關建立和編輯 IAM 政策的詳細資訊，請參閱《IAM 使用者指南》**中的[建立 IAM 政策](https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_create.html)。如需如何將此政策指派給 IAM 群組的資訊，請參閱[將政策連接到 IAM 群組](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_groups_manage_attach-policy.html)。

使用以下項目建立許可並將許可新增至使用者、群組或角色：

------
#### [ JSON ]

****  

```
{
  "Version":"2012-10-17",		 	 	 
  "Statement": [
    {
      "Effect": "Allow",
      "Action": [
        "ssm:GetOpsItem",
        "ssm:UpdateOpsItem",
        "ssm:DescribeOpsItems",
        "ssm:CreateOpsItem",
        "ssm:CreateResourceDataSync",
        "ssm:DeleteResourceDataSync",
        "ssm:ListResourceDataSync",
        "ssm:UpdateResourceDataSync"

      ],
      "Resource": "*"
    }
  ]
}
```

------

視您在組織中使用的身分應用程式而定，您可以選取下列任何選項來設定使用者存取權。

若要提供存取權，請新增權限至您的使用者、群組或角色：
+ 中的使用者和群組 AWS IAM Identity Center：

  建立權限合集。請按照《*AWS IAM Identity Center 使用者指南*》中的[建立權限合集](https://docs.aws.amazon.com//singlesignon/latest/userguide/howtocreatepermissionset.html)說明進行操作。
+ 透過身分提供者在 IAM 中管理的使用者：

  建立聯合身分的角色。遵循《*IAM 使用者指南*》的[為第三方身分提供者 (聯合) 建立角色](https://docs.aws.amazon.com//IAM/latest/UserGuide/id_roles_create_for-idp.html)中的指示。
+ IAM 使用者：
  + 建立您的使用者可擔任的角色。請按照《*IAM 使用者指南*》的[為 IAM 使用者建立角色](https://docs.aws.amazon.com//IAM/latest/UserGuide/id_roles_create_for-user.html)中的指示。
  + (不建議) 將政策直接附加至使用者，或將使用者新增至使用者群組。請遵循 *IAM 使用者指南*的[新增許可到使用者 (主控台)](https://docs.aws.amazon.com//IAM/latest/UserGuide/id_users_change-permissions.html#users_change_permissions-add-console) 中的指示。

### 使用標籤限制存取 OpsItems
<a name="OpsCenter-getting-started-user-permissions-tags"></a>

您也可以使用指定標籤的內嵌 IAM 政策，限制存取 OpsItems。以下範例會指定 *Department* 的標籤鍵和 *Finance* 的標籤值。使用此政策，使用者只能呼叫 *GetOpsItem* API 操作，檢視之前以 Key=Department 和 Value=Finance 標記的 OpsItems。使用者無法檢視任何其他 OpsItems。

------
#### [ JSON ]

****  

```
{
  "Version":"2012-10-17",		 	 	 
  "Statement": [
    {
      "Effect": "Allow",
      "Action": [
        "ssm:GetOpsItem"
             ],
      "Resource": "*"
      ,
      "Condition": { "StringEquals": { "ssm:resourceTag/Department": "Finance" } }
    }
  ]
}
```

------

以下範例會指定檢視和更新 OpsItems 的 API 操作。此政策還會指定兩組標籤金鑰/值對：Department-Finance 和 Project-Unity。

------
#### [ JSON ]

****  

```
{
   "Version":"2012-10-17",		 	 	 
   "Statement":[
      {
         "Effect":"Allow",
         "Action":[
            "ssm:GetOpsItem",
            "ssm:UpdateOpsItem"
         ],
         "Resource":"*",
         "Condition":{
            "StringEquals":{
               "ssm:resourceTag/Department":"Finance",
               "ssm:resourceTag/Project":"Unity"
            }
         }
      }
   ]
}
```

------

如需將標籤新增到 OpsItem 的資訊，請參閱 [手動建立 OpsItems](OpsCenter-manually-create-OpsItems.md)。

# 了解整合式設定建立的預設 EventBridge 規則
<a name="Explorer-setup-default-rules"></a>

在 Explorer 和 OpsCenter 的整合式設定程序期間，可以選擇根據 Amazon EventBridge 偵測到的事件啟用多個預設規則。偵測到這些事件時，系統會自動在 AWS Systems Manager OpsCenter 中建立 OpsItems。

例如，EC2 自動擴展執行個體終止失敗時，規則 `SSMOpsItems-Autoscaling-instance-termination-failure` 會導致建立 OpsItem。

Systems Manager 維護時段無法成功完成時，規則 `SSMOpsItems-SSM-maintenance-window-execution-failed` 會導致建立 OpsItem。

如需可以在設定程序期間啟用的所有 EventBridge 規則的設定指示和說明，請參閱 [設定 OpsCenter](OpsCenter-setup.md)。

如果您不希望 EventBridge 為這些事件建立 OpsItems，可以選擇不在整合式設定中啟用此選項。如果您願意，您可以將 OpsCenter 指定為特定 EventBridge 事件的目標。如需詳細資訊，請參閱[設定 EventBridge 規則以建立 OpsItems](OpsCenter-automatically-create-OpsItems-2.md)。

您可以在 OpsCenter **設定**頁面中選擇 **OpsCenter、設定**，然後在**OpsItem規則**區域中選擇**編輯**，以停用預設規則或變更其類別和嚴重性等級。

您也可以在 Systems Manager 主控台中編輯指派給根據這些規則建立的個別 OpsItem 的類別或嚴重性。如需相關資訊，請參閱[編輯 OpsItem](OpsCenter-working-with-OpsItems-editing-details.md)。

![\[在 Systems Manager Explorer 中建立 OpsItems 的預設規則\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/explorer-default-rules.png)


# 設定 Explorer 的委派管理員
<a name="Explorer-setup-delegated-administrator"></a>

如果您使用資源資料同步來彙總多個 AWS 區域 和 帳戶的 AWS Systems Manager Explorer 資料 AWS Organizations，建議您為 設定委派管理員Explorer。委派系統管理員可透過下列方式改善 Explorer 安全性。
+ 限制 Explorer 管理員數目，這些管理員可建立或刪除多帳戶以及同步到個別 AWS 帳戶的區域資源資料。
+ 您不再需要登入 AWS Organizations 管理帳戶，即可在 中管理資源資料同步Explorer。

委派管理員可以使用 主控台、 SDK、 AWS Command Line Interface (AWS CLI) 或 使用以下Explorer資源資料同步 APIs AWS Tools for Windows PowerShell：
+ [CreateResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateResourceDataSync.html)
+ [DeleteResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DeleteResourceDataSync.html)
+ [ListResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_ListResourceDataSync.html)
+ [UpdateResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_UpdateResourceDataSync.html)

委派管理員可以從主控台或使用 SDK、 AWS CLI或 等程式設計工具來搜尋、篩選和彙總Explorer資料 AWS Tools for Windows PowerShell。搜尋、篩選和資料彙總會使用 [GetOpsSummary](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsSummary.html) API 操作。

委派管理員可以為整個組織或組織單位的子集建立最多五個資源資料同步。委派管理員所建立的資源資料同步只能在委派管理員帳戶中使用。您無法在 AWS Organizations 管理帳戶中檢視同步或彙總的資料。

**注意**  
您無法使用委派管理員帳戶在[選擇加入 AWS 區域](https://docs.aws.amazon.com/global-infrastructure/latest/regions/aws-regions.html#regions-opt-in-status)中建立資源資料同步。您必須使用 AWS Organizations 管理帳戶。

如需資源資料同步的相關資訊，請參閱 [設定 Systems Manager Explorer 以顯示來自多個帳戶和區域的資料](Explorer-resource-data-sync.md)。如需 的詳細資訊 AWS Organizations，請參閱*AWS Organizations 《 使用者指南*》中的[什麼是 AWS Organizations？](https://docs.aws.amazon.com/organizations/latest/userguide/)。

**Topics**
+ [開始之前](#Explorer-setup-delegated-administrator-before-you-begin)
+ [設定 Explorer 委派管理員](Explorer-setup-delegated-administrator-configure.md)
+ [取消註冊 Explorer 委派管理員](Explorer-setup-delegated-administrator-deregister.md)

## 開始之前
<a name="Explorer-setup-delegated-administrator-before-you-begin"></a>

下列清單包含有關 Explorer 委派管理的重要資訊。
+ 您只能委派一個帳戶進行 Explorer 管理。
+ 您指定為 Explorer 委派管理員的帳戶 ID 必須列為 AWS Organizations中的成員帳戶。如需詳細資訊，請參閱*AWS Organizations 《 使用者指南*》中的[AWS 帳戶 在組織中建立 ](https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_accounts_create.html)。
+ 委派管理員可以使用主控台中的所有Explorer資源資料同步 API 操作，或使用程式設計工具，例如 SDK、 AWS Command Line Interface (AWS CLI) 或 AWS Tools for Windows PowerShell。資源資料同步 API 操作包括下列項目：[CreateResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateResourceDataSync.html)、[DeleteResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DeleteResourceDataSync.html)、[ListResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_ListResourceDataSync.html) 和 [UpdateResourceDataSync](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_UpdateResourceDataSync.html)。
+ 委派管理員可以在主控台中搜尋、篩選和彙總 Explorer 資料，或使用程式設計工具 (例如 SDK、 AWS CLI或 AWS Tools for Windows PowerShell)。搜尋、篩選和資料彙總會使用 [GetOpsSummary](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsSummary.html) API 操作。
+ 委派管理員所建立的資源資料同步只能在委派管理員帳戶中使用。您無法檢視 AWS Organizations 管理帳戶中的同步或彙總資料。
+ 委派管理員最多可建立五個資源資料同步。
+ 委派管理員可以為 中的整個組織 AWS Organizations 或組織單位的子集建立資源資料同步。

# 設定 Explorer 委派管理員
<a name="Explorer-setup-delegated-administrator-configure"></a>

請使用下列程序來註冊 Explorer 委派管理員。

**註冊 Explorer 委派管理員**

1. 登入您的 AWS Organizations 管理帳戶。

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 在 **Delegated administrator for Explorer** (Explorer 的委派管理員) 區段中，確認您已設定必要的服務連結角色和服務存取選項。如有必要，請選擇 **Create role** (建立角色) 和 **Enable access** (啟用存取) 按鈕設定這些選項。

1. 針對**帳戶 ID**，輸入 AWS 帳戶 ID。此帳戶必須是其中的成員帳戶 AWS Organizations。

1. 選擇 **Register delegated administrator (註冊委派管理員)**。

委派管理員現在可以存取在**建立資源資料同步**頁面上的選項中**包含來自我的 AWS Organizations 組態的所有帳戶**和**選取組織單位 AWS Organizations**。

# 取消註冊 Explorer 委派管理員
<a name="Explorer-setup-delegated-administrator-deregister"></a>

請使用下列程序來取消註冊 Explorer 委派管理員。委派管理員帳戶只能由 AWS Organizations 管理帳戶取消註冊。取消註冊委派管理員帳戶時，系統會刪除委派管理員建立的所有 AWS Organizations 資源資料同步。

**取消註冊 Explorer 委派管理員**

1. 登入您的 AWS Organizations 管理帳戶。

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 在 **Delegated administrator for Explorer** (Explorer 的委派管理員) 區段，選擇 **Deregister** (取消註冊)。系統會顯示警告。

1. 輸入帳戶 ID，然後選擇 **Remove** (移除)。

帳戶無法再存取 AWS Organizations 資源資料同步 API 操作。系統會刪除帳戶建立的所有 AWS Organizations 資源資料同步。

# 設定 Systems Manager Explorer 以顯示來自多個帳戶和區域的資料
<a name="Explorer-resource-data-sync"></a>

AWS Systems Manager 使用整合的設定體驗來協助您開始使用 AWS Systems Manager Explorer *和* AWS Systems Manager OpsCenter 。完成整合設定後，Explorer 和 OpsCenter 會自動同步資料。更具體地說，這些工具OpsItems會針對 AWS 區域 同步 OpsData 和 ， AWS 帳戶 並在您完成整合設定時使用。如果您希望彙整來自其他帳戶和區域的 OpsData 和 OpsItems，您必須建立資源資料同步，如本主題所說明。

**注意**  
如需整合式設定的詳細資訊，請參閱[開始使用 Systems Manager Explorer 和 OpsCenter](Explorer-setup.md)。

**Topics**
+ [了解 Explorer 的資源資料同步](Explorer-resource-data-sync-understanding.md)
+ [了解多個帳戶和區域資源資料同步](Explorer-resource-data-sync-multiple-accounts-and-regions.md)
+ [刪除資源資料同步](Explorer-resource-data-sync-configuring-multi.md)

# 了解 Explorer 的資源資料同步
<a name="Explorer-resource-data-sync-understanding"></a>

Explorer 的資源資料同步提供兩種彙整選項：
+ **單一帳戶/多個區域：**您可以設定 Explorer 彙整多個 AWS 區域的 OpsItems 和 OpsData 資料，但資料集會受限於目前的 AWS 帳戶。
+ **多帳戶/多區域：**您可以設定 Explorer 彙整多個 AWS 區域 和帳戶的資料。此選項需要您設定 AWS Organizations。在您設定 和 之後 AWS Organizations，您可以Explorer依組織單位 (OU) 或整個組織在 中彙總資料。Systems Manager 會將資料彙整至 AWS Organizations 管理帳戶，再於 Explorer 中進行顯示。如需詳細資訊，請參閱*AWS Organizations 《 使用者指南*》中的[什麼是 AWS Organizations？](https://docs.aws.amazon.com/organizations/latest/userguide/)。

**警告**  
如果您設定 Explorer 以彙總 AWS Organizations中的組織資料，系統會啟用組織中所有成員帳戶的 OpsData。在所有成員帳户中啟用 OpsData 來源會增加呼叫 [CreateOpsItem](https://docs.aws.amazon.com//systems-manager/latest/APIReference/API_CreateOpsItem.html) 和 [GetOpsSummary](https://docs.aws.amazon.com//systems-manager/latest/APIReference/API_GetOpsSummary.html) 等 OpsCenter API 的次數。呼叫這些 API 動作需支付費用。

下圖顯示設為使用 AWS Organizations的資源資料同步。在此案例中，使用者具備兩個在 AWS Organizations中定義的帳戶。資源資料同步會將來自兩個帳戶和多個 AWS 區域 的資料彙總到 AWS Organizations 管理帳戶中，然後顯示在 中Explorer。

![\[Systems Manager Explorer 的資源資料同步\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/ExplorerSyncFromSource.png)


# 了解多個帳戶和區域資源資料同步
<a name="Explorer-resource-data-sync-multiple-accounts-and-regions"></a>

本節說明有關使用 AWS Organizations的多個帳戶和多個區域資源資料同步的重要詳細資訊。具體而言，如果您選擇了 **Create resource data sync** (建立資源資料同步) 頁面中的以下其中一個選項，則本節的資訊適用：
+ 包含我的 AWS Organizations 組態中的所有帳戶
+ 在 中選取組織單位 AWS Organizations

如果您不打算使用以下其中一個選項，您可以略過本節。

當您在 SSM 主控台中建立資源資料同步時，如果您選擇其中一個 AWS Organizations 選項，則 Systems Manager 會自動為組織 （或所選組織單位 AWS 帳戶 ) 中的所有 ，允許所選區域中的所有 OpsData 來源。例如，即使您尚未在區域中Explorer開啟 ，如果您為資源資料同步選取 AWS Organizations 選項，則 Systems Manager 會自動從該區域收集 OpsData。若要在不允許 OpsData 來源的情況下建立資源資料同步，請在建立資料同步時將 **EnableAllOpsDataSources** 指定為 false。如需詳細資訊，請參閱《Amazon EC2 Systems Manager API 參考》**中 [ResourceDataSyncSource](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_ResourceDataSyncSource.html) 資料類型的 `EnableAllOpsDataSources` 參數詳細資訊。

如果您未選擇資源資料同步的其中一個 AWS Organizations 選項，則必須在Explorer您要存取資料的每個帳戶和區域中完成整合式設定。如果沒有這樣做，Explorer 將不會顯示未完成整合式設定的帳戶和區域的 OpsData 和 OpsItems。

如果您將子帳戶新增至您的組織，Explorer 會自動允許該帳戶的所有 OpsData 來源。如果您稍後從組織中移除子女帳戶，Explorer 會繼續從帳戶收集 OpsData。

如果您更新使用其中一個 AWS Organizations 選項的現有資源資料同步，系統會提示您核准收集受變更影響之所有帳戶和區域的所有 OpsData 來源。

如果您將新服務新增至 AWS 帳戶，且 為該服務Explorer收集 OpsData，則 Systems Manager 會自動設定 Explorer以收集該 OpsData。例如，如果您的組織在您先前建立資源資料同步 AWS Trusted Advisor 時未使用 ，但您的組織註冊此服務， Explorer會自動更新您的資源資料同步以收集此 OpsData。

**重要**  
請注意下列有關多個帳戶和區域資源資料同步的重要資訊：  
刪除資源資料同步不會關閉 Explorer 中的 OpsData 來源。
若要從多個帳戶檢視 OpsData OpsItems 和 ，您必須開啟 AWS Organizations **所有功能**模式，而且必須登入 AWS Organizations 管理帳戶。
大多數 預設為 AWS 區域 作用中 AWS 帳戶，但只有在您手動選取特定區域時才會啟用。這些區域稱為[選擇加入區域](https://docs.aws.amazon.com/global-infrastructure/latest/regions/aws-regions.html#regions-opt-in-status)。依預設，Explorer 跨帳戶/跨區域資源資料同步在選擇加入區域中不支援資料彙總。我們已於 2025 年 6 月 30 日新增對下列選擇加入區域的支援。  
歐洲 (米蘭)
非洲 (開普敦)
Middle East (Bahrain)
亞太地區 (香港)
請注意，您無法使用委派管理員帳戶在選擇加入區域中建立資源資料同步。您必須使用 AWS Organizations 管理帳戶。

# 刪除資源資料同步
<a name="Explorer-resource-data-sync-configuring-multi"></a>

在設定 Explorer 的資源資料同步之前，請留意以下詳細資訊。
+ Explorer 支援最多五個資源資料同步。
+ 為區域建立資源資料同步之後，您無法變更該同步的*帳戶選項*。例如，如果您在 us-east-2 （俄亥俄） 區域中建立同步，並選擇**僅包含目前帳戶**選項，則您無法稍後編輯該同步，並從**我的 AWS Organizations 組態選項中選擇包含所有帳戶**。相反地，您必須刪除第一個資源資料同步，並建立新的資源資料同步。
+ Explorer 中檢視的 OpsData 是唯讀的。

使用下列程序可為 Explorer 建立資源資料同步。

**建立資源資料同步**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 在 **Configure resource data sync (設定資源資料同步)** 區段中，選擇 **Create resource data sync (建立資源資料同步)**。

1. 對於 **Resource data sync name (資源資料同步名稱)**，輸入名稱。

1. 在 **Add accounts (新增帳戶)** 區段中，選擇一個選項。
**注意**  
若要使用任一 AWS Organizations 選項，您必須登入 AWS Organizations 管理帳戶，或必須登入Explorer委派管理員帳戶。如需委派管理員帳戶的詳細資訊，請參閱 [設定 Explorer 的委派管理員](Explorer-setup-delegated-administrator.md)。

1. 在 **Regions to include (要包含的區域)** 區段中，選擇下列其中一個選項。
   + 選擇**所有目前和未來的區域**，以自動同步來自所有目前 AWS 區域 和未來上線之新區域的資料。
   + 選擇**所有區域**以自動同步所有目前資料 AWS 區域。
   + 個別選擇您要包含的區域。

1. 選擇**建立資源資料同步**。

建立資源資料同步之後，可能需要幾分鐘的時間，才能填入 Explorer 的資料。您可從 Explorer 中的 **Select a resource data sync** (選取資源資料同步) 清單中進行選擇，從而檢視同步。

# 使用 Explorer
<a name="Explorer-using"></a>

本節包含如何藉由變更小工具配置以及變更儀表板中顯示的資料來自訂 AWS Systems Manager Explorer 的相關資訊。

**Topics**
+ [編輯為 Explorer 建立的 EventBridge 規則](Explorer-using-editing-default-rules.md)
+ [編輯 Systems Manager Explorer 資料來源](Explorer-using-editing-data-sources.md)
+ [自訂 Explorer 顯示](Explorer-using-filters.md)
+ [在 AWS Security Hub CSPM 中接收問題清單 Explorer](explorer-securityhub-integration.md)
+ [刪除 Systems Manager Explorer 資源資料同步](Explorer-using-resource-data-sync-delete.md)

# 編輯為 Explorer 建立的 EventBridge 規則
<a name="Explorer-using-editing-default-rules"></a>

完成整合式設定時，系統允許在 Amazon EventBridge 中啟用十幾個以上的規則。這些規則會自動在 OpsItems中建立 AWS Systems Manager OpsCenter。 AWS Systems Manager Explorer然後 會顯示有關 的彙總資訊OpsItems。

每個規則都包含預設的 **Category (類別)** 和 **Severity (嚴重性)** 值。當系統從事件建立 OpsItems 時，它會自動指派預設的 **Category (類別)** 和 **Severity (嚴重性)**。

**重要**  
目前，您無法編輯預設規則的 **Category** (類別) 和 **Severity** (嚴重性) 值，但您可以在透過預設規則建立的 OpsItems 上編輯這些值。

![\[在 Systems Manager Explorer 中建立 OpsItems 的預設規則\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/explorer-default-rules.png)


**編輯用於建立 OpsItems 的預設規則**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 在 **OpsItems 規則**規則區段中，選擇 **Edit (編輯)**。

1. 展開 **CWE rules (CWE 規則)**。

1. 清除您不想使用的規則旁邊的核取方塊。

1. 使用 **Category (類別)** 和 **Severity (嚴重性)** 清單來變更規則的此資訊。

1. 選擇**儲存**。

您的變更會在下次系統建立 OpsItem 時生效。

# 編輯 Systems Manager Explorer 資料來源
<a name="Explorer-using-editing-data-sources"></a>

對於[預設](https://docs.aws.amazon.com/global-infrastructure/latest/regions/aws-regions.html)可用的 AWS 區域 ， AWS Systems Manager Explorer 會顯示來自下列來源的資料。您可以編輯 Explorer 設定來新增或移除資料來源：
+ Amazon Elastic Compute Cloud (Amazon EC2)
+ AWS Systems Manager 庫存
+ AWS Systems Manager OpsCenter OpsItems
+ AWS Systems Manager Patch Manager 修補程式合規
+ AWS Systems Manager State Manager 關聯合規
+ AWS Trusted Advisor
+ AWS Compute Optimizer
+ AWS 支援 中心案例
+ AWS Config 規則和資源合規
+ AWS Security Hub CSPM 問題清單

**注意**  
對於亞太區域 （大阪） 區域， Explorer不會顯示來自 AWS Compute Optimizer 和 AWS Security Hub CSPM 調查結果的資料。

對於 [AWS 選擇加入區域](https://docs.aws.amazon.com/global-infrastructure/latest/regions/aws-regions.html#regions-opt-in-status)，Explorer 會顯示以下來源的資料：
+ Amazon Elastic Compute Cloud (Amazon EC2)
+ AWS Systems Manager 庫存
+ AWS Systems Manager OpsCenter OpsItems
+ AWS Systems Manager Patch Manager 修補程式合規
+ AWS Systems Manager State Manager 關聯合規
+ AWS Trusted Advisor
+ AWS 支援 中心案例
+ AWS Config 規則和資源合規

**注意**  
若要在 中檢視 支援 中心案例Explorer，您必須設定企業或企業帳戶 支援。
您無法設定 Explorer 來停止顯示 OpsCenter OpsItem 資料。

**開始之前**  
確認您已安裝並設定將資料填入 Explorer 小工具的服務。如需詳細資訊，請參閱[設定 Explorer 的相關服務](Explorer-setup-related-services.md)。

**編輯資料來源**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**，然後選擇**設定儀表板**索引標籤。

1. 在 **OpsData 來源**區段的**狀態**欄位中，根據要檢視的資料開啟或關閉來源。

# 自訂 Explorer 顯示
<a name="Explorer-using-filters"></a>

您可以使用drag-and-drop功能在 AWS Systems Manager Explorer 中自訂小工具配置。您也可以使用篩選器自訂在 Explorer 中顯示的 OpsData 和 OpsItems，如本主題所述。

在您自訂小工具配置之前，請驗證您要檢視的小工具目前已顯示在 Explorer 中。若要檢視 Explorer 中的某些小工具 (例如 AWS Config 合規小工具)，必須在 **Configure dashboard** (設定儀表板) 頁面上將其啟用。

**啟用小工具以顯示在 Explorer 中**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇 **Dashboard actions** (儀表板動作)、**Configure dashboard** (設定儀表板)。

1. 選擇 **Configure Dashboard** (設定儀表板) 標籤。

1. 選擇 **Enable all** (全部啟用) 或開啟個別小工具或資料來源。

1. 選擇 **Explorer** 檢視您的變更。

若要在 Explorer 中自訂小工具配置，請選擇要移動的小工具。按住 Widget 的名稱，然後將它拖曳到新位置。

![\[移動 Systems Manager Explorer 中的小工具\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/explorer-customize.png)


對您要重新定位的每個 Widget 重複此程序。

如果您決定不要新的配置，請選擇**重設配置**，將所有小工移回原始位置。

## 使用篩選器變更在 Explorer 中顯示的資料
<a name="Explorer-using-filters-filtering"></a>

根據預設， Explorer會顯示目前 AWS 帳戶 和目前區域的資料。如果您建立一或多個資源資料同步，您可以使用篩選器來變更哪個同步處於作用中。然後，您可以選擇顯示特定區域或所有區域的資料。您也可以使用搜尋列來依據不同的 OpsItem 和 key-tag 條件篩選。

**使用篩選器變更在 Explorer 中顯示的資料**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 在 **Filter (篩選)** 區段中，使用 **Select a resource data sync (選取資源資料同步清單)** 來選擇同步。

1. 使用 **Regions** (區域) 清單來選擇特定 AWS 區域 或選擇 **All Regions** (所有區域)。

1. 選擇搜尋列，然後選擇要篩選資料的依據條件。  
![\[使用 Systems Manager Explorer 中的篩選條件搜尋列\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/explorer-filters.png)

1. 按 Enter。

如果您關閉並重新開啟頁面，Explorer 會保留您選取的篩選選項。

# 在 AWS Security Hub CSPM 中接收問題清單 Explorer
<a name="explorer-securityhub-integration"></a>

[AWS Security Hub CSPM](https://docs.aws.amazon.com/securityhub/latest/userguide/what-is-securityhub.html) 提供 中安全狀態的完整檢視 AWS。此服務會從各 AWS 帳戶、服務和支援的第三方產品收集安全資料 (稱為*調查結果*)。Security Hub CSPM 調查結果可協助您根據安全產業標準和最佳實務檢查環境，分析您的安全趨勢，並識別最高優先順序的安全問題。

Security Hub CSPM 會將問題清單傳送至 Amazon EventBridge，其會使用事件規則將問題清單傳送至 Explorer。啟用整合後，如此處所述，您可以在Explorer小工具中檢視 Security Hub CSPM 問題清單，並在 OpsCenter 中檢視問題清單詳細資訊OpsItems。小工具會根據嚴重性提供所有 Security Hub CSPM 調查結果的摘要。Security Hub CSPM 中的新問題清單通常會在建立後的幾Explorer秒鐘內顯示。

**警告**  
記下以下重要資訊：  
Explorer 已與 OpsCenter 整合 (Systems Manager 中的工具)。啟用與 Security Hub CSPM 的Explorer整合後， OpsCenter會自動OpsItems為 Security Hub CSPM 調查結果建立 。根據您的 AWS 環境，啟用整合可能會產生大量 OpsItems，但需付費。  
繼續之前，請閱讀 Security Hub CSPM OpsCenter整合的相關資訊。本主題包含有關對調查結果和 OpsItems 的變更和更新將如何收費的詳細資訊。如需詳細資訊，請參閱[了解與 的OpsCenter整合 AWS Security Hub CSPM](OpsCenter-applications-that-integrate.md#OpsCenter-integrate-with-security-hub)。如需 OpsCenter 定價資訊，請參閱 [AWS Systems Manager 定價](https://aws.amazon.com/systems-manager/pricing/)。
如果您在登入管理員帳戶Explorer時在 中建立資源資料同步，系統會自動為管理員和同步中的所有成員帳戶啟用 Security Hub CSPM 整合。啟用後， OpsCenter會自動OpsItems為 Security Hub CSPM 調查結果建立 ，但需付費。如需建立資源資料同步的相關資訊，請參閱 [設定 Systems Manager Explorer 以顯示來自多個帳戶和區域的資料](Explorer-resource-data-sync.md)。

## Explorer 接收之調查結果的類型
<a name="explorer-securityhub-integration-finding-types-received"></a>

Explorer 從 Security Hub CSPM 接收[所有調查結果](https://docs.aws.amazon.com/securityhub/latest/userguide/securityhub-cwe-integration-types.html#securityhub-cwe-integration-types-all-findings)。當您開啟 Security Hub CSPM 預設設定時，您可以根據Explorer小工具中的嚴重性查看所有調查結果。根據預設，Explorer 可為「關鍵」和「高」安全性調查結果建立 OpsItems。您可以手動設定 Explorer，為「中等」和「低」安全性調查結果建立 OpsItems。

雖然 Explorer不會OpsItems為資訊調查結果建立 ，但您可以在 Security Hub CSPM 調查結果摘要小工具中檢視資訊操作資料 (OpsData)。 會為所有調查結果Explorer建立 OpsData，無論嚴重性為何。如需 Security Hub CSPM 嚴重性等級的詳細資訊，請參閱 *AWS Security Hub API 參考*中的[嚴重性](https://docs.aws.amazon.com//securityhub/1.0/APIReference/API_Severity.html)。

## 啟用整合
<a name="explorer-securityhub-integration-receive-enable"></a>

本節說明如何啟用和設定 Explorer以開始接收 Security Hub CSPM 問題清單。

**開始之前**  
在設定 Explorer開始接收 Security Hub CSPM 問題清單之前，請先完成下列任務。
+ 啟用和設定 Security Hub CSPM。如需詳細資訊，請參閱*AWS Security Hub 《 使用者指南*》中的[設定 Security Hub CSPM](https://docs.aws.amazon.com/securityhub/latest/userguide/securityhub-settingup.html)。
+ 登入 AWS Organizations 管理帳戶。Systems Manager 需要存取 ， AWS Organizations 才能OpsItems從 Security Hub CSPM 調查結果建立 。登入管理帳戶後，系統會提示您選取 Explorer **Configure dashboard** (設定儀表板) 標籤上的 **Enable access** (啟用存取) 按鈕 設定儀表板索引標籤，如下列程序所述。如果您未登入 AWS Organizations 管理帳戶，則無法允許存取，Explorer也無法OpsItems從 Security Hub CSPM 調查結果建立。

**開始接收 Security Hub CSPM 問題清單**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 選取 **Configure dashboard** (設定儀表板) 標籤。

1. 選取 **AWS Security Hub CSPM**。

1. 選取 **Disabled** (已停用) 滑桿，以開啟 **AWS Security Hub CSPM**。

   預設會顯示「關鍵」和「高」安全性調查結果。若要顯示「中」和「低」安全性調查結果，請選取**中、低**旁邊的**已停用**滑桿。

1. 在 **OpsItems Security Hub CSPM 調查結果建立的** 區段中，選擇**啟用存取**。如果您沒有看到此按鈕，請登入 AWS Organizations 管理帳戶並返回此頁面以選取按鈕。

## 如何檢視 Security Hub CSPM 的問題清單
<a name="explorer-securityhub-integration-view-received-findings"></a>

下列程序說明如何檢視 Security Hub CSPM 問題清單。

**檢視 Security Hub CSPM 調查結果**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 尋找 **AWS Security Hub CSPM 調查結果摘要**小工具。這會顯示您的 Security Hub CSPM 問題清單。您可以選取嚴重性等級，以檢視對應的 OpsItem 的詳細說明。

## 如何停止接收調查結果
<a name="explorer-securityhub-integration-disable-receive"></a>

下列程序說明如何停止接收 Security Hub CSPM 問題清單。

**停止接收 Security Hub CSPM 問題清單**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 選取 **Configure dashboard** (設定儀表板) 標籤。

1. 選取 **Enabled** (已啟用) 滑桿，以關閉 **AWS Security Hub CSPM**。

**重要**  
如果停用 Security Hub CSPM 問題清單的選項在 主控台中呈現灰色，您可以在 中執行下列命令來停用此設定 AWS CLI。登入 AWS Organizations 管理帳戶或 Systems Manager 委派管理員帳戶時，您必須執行 命令。針對 `region` 參數，指定您要在 中停止接收 Security Hub CSPM 問題清單 AWS 區域 的 Explorer。  

```
aws ssm update-service-setting --setting-id /ssm/opsdata/SecurityHub --setting-value Disabled --region AWS 區域
```
範例如下。  

```
aws ssm update-service-setting --setting-id /ssm/opsdata/SecurityHub --setting-value Disabled --region us-east-1
```

# 刪除 Systems Manager Explorer 資源資料同步
<a name="Explorer-using-resource-data-sync-delete"></a>

在 AWS Systems Manager Explorer 中，您可以透過建立資源資料同步，OpsItems從其他帳戶和區域彙總 OpsData 和 。

您無法變更資源資料同步的帳戶選項。例如，如果您在 us-east-2 （俄亥俄） 區域中建立同步，並選擇**僅包含目前帳戶**選項，則您無法稍後編輯該同步，並從**我的 AWS Organizations 組態選項中選擇包含所有帳戶**。相反地，您必須刪除資源資料同步，並建立新的資源資料同步，如下列程序所述。

**刪除資源資料同步**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 在 **Configure resource data sync (設定資源資料同步)** 區段中，選擇您要刪除的資源資料同步。

1. 選擇**刪除**。

# 從 Systems Manager Explorer 匯出 OpsData
<a name="Explorer-exporting-OpsData"></a>

您可以從 AWS Systems Manager Explorer 將 5，000 個 OpsData 項目匯出為逗號分隔值 (.csv) 檔案到 Amazon Simple Storage Service (Amazon S3) 儲存貯體。Explorer 使用 [https://docs.aws.amazon.com/systems-manager-automation-runbooks/latest/userguide/automation-aws-exportopsdatatos3.html](https://docs.aws.amazon.com/systems-manager-automation-runbooks/latest/userguide/automation-aws-exportopsdatatos3.html) 自動化執行手冊匯出 OpsData。匯出 OpsData 時，系統會顯示自動化執行手冊頁面，您可以在其中指定詳細資訊，例如要匯出的 assumeRole、Amazon S3 儲存貯體名稱、SNS 主題 ARN 以及欄位。

**Topics**
+ [步驟 1：指定 SNS 主題](#Explorer-specify-SNS-topic)
+ [步驟 2：(選用) 設定資料匯出](#Explorer-configure-data-export)
+ [步驟 3：匯出 OpsData](#Explorer-export-OpsData)

## 步驟 1：指定 SNS 主題
<a name="Explorer-specify-SNS-topic"></a>

設定資料匯出時，您必須指定 Amazon Simple Notification Service (Amazon SNS) 主題，該主題存在於您要匯出資料的相同 AWS 區域 位置。匯出完成時，Systems Manager 會將通知傳送到 Amazon SNS 主題。如需建立 Amazon SNS 主題的相關資訊，請參閱[建立 Amazon SNS 主題](https://docs.aws.amazon.com/sns/latest/dg/sns-tutorial-create-topic.html)。

## 步驟 2：(選用) 設定資料匯出
<a name="Explorer-configure-data-export"></a>

您可以從**設定**或**將操作資料匯出至 S3 儲存貯體**頁面進行資料匯出設定。

**從 Explorer 設定資料匯出**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇**設定**。

1. 在 **Configure data export (設定資料匯出)** 區段中，選擇 **Edit (編輯)**。

1. 若要將資料匯出檔案上傳至現有的 Amazon S3 儲存貯體，請選擇**選取現有的 S3 儲存貯體**，然後從清單中選擇儲存貯體。

   若要將資料匯出檔案上傳至新的 Amazon S3 儲存貯體，請選擇**建立新的 S3 儲存貯體**，然後輸入您要用於新儲存貯體的名稱。
**注意**  
在 Explorer 中，您只能從您第一次設定這些設定的頁面編輯 Amazon S3 儲存貯體名稱和 Amazon SNS 主題 ARN。如果您從**設定**頁面設定 Amazon S3 儲存貯體和 Amazon SNS 主題 ARN，則只能從**設定**頁面修改這些設定。

1. 針對**選取 Amazon SNS 主題 ARN**，選擇匯出完成時要通知的主題。

1. 選擇**建立**。

## 步驟 3：匯出 OpsData
<a name="Explorer-export-OpsData"></a>

當您匯出Explorer資料時，Systems Manager 會建立名為 的 AWS Identity and Access Management (IAM) 角色`AmazonSSMExplorerExportRole`。此角色使用下列 IAM 政策。

------
#### [ JSON ]

****  

```
{
      "Version":"2012-10-17",		 	 	 
      "Statement": [
          {
              "Sid": "OpsSummaryExportAutomationServiceRoleStatement1",
              "Effect": "Allow",
              "Action": [
                  "s3:PutObject"
              ],
              "Resource": [
                 "arn:aws:s3:::amzn-s3-demo-bucket/*"
              ]
          },
          {
              "Sid": "OpsSummaryExportAutomationServiceRoleStatement2",
              "Effect": "Allow",
              "Action": [
                  "s3:GetBucketAcl",
                  "s3:GetBucketLocation"
              ],
              "Resource": [
                 "arn:aws:s3:::amzn-s3-demo-bucket"
              ]
          },
          {
              "Sid": "OpsSummaryExportAutomationServiceRoleStatement3",
              "Effect": "Allow",
              "Action": [
                  "sns:Publish"
              ],
              "Resource": [
                  "arn:aws:sns:us-east-1:111122223333:SNSTopicName"
              ]
          },
          {
              "Sid": "OpsSummaryExportAutomationServiceRoleStatement4",
              "Effect": "Allow",
              "Action": [
                  "logs:DescribeLogGroups",
                  "logs:DescribeLogStreams"
              ],
              "Resource": [
                  "arn:aws:logs:us-east-1:111122223333:log-group:MyLogGroup"
              ]
          },
          {
              "Sid": "OpsSummaryExportAutomationServiceRoleStatement5",
              "Effect": "Allow",
              "Action": [
                  "logs:CreateLogGroup",
                  "logs:PutLogEvents",
                  "logs:CreateLogStream"
              ],
              "Resource": [
                  "*"
              ]
          },
          {
              "Sid": "OpsSummaryExportAutomationServiceRoleStatement6",
              "Effect": "Allow",
              "Action": [
                  "ssm:GetOpsSummary"
              ],
              "Resource": [
                  "*"
              ]
          }
      ]
  }
```

------

角色包括下列信任實體。

------
#### [ JSON ]

****  

```
{
      "Version":"2012-10-17",		 	 	 
      "Statement": [
        {
          "Sid": "OpsSummaryExportAutomationServiceRoleTrustPolicy",
          "Effect": "Allow",
          "Principal": {
            "Service": "ssm.amazonaws.com"
          },
          "Action": "sts:AssumeRole"
        }
      ]
    }
```

------

**從 Explorer 匯出 OpsData**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Explorer**。

1. 選擇 Explorer 小工具中的資料連結。例如，在**依狀態劃分的 OpsItems** 小工具中，選擇**未解決**或**未決問題**。或在**依嚴重性劃分的 OpsItem** 小工具中，選擇**關鍵**或**高**資料連結。Explorer 開啟所選資料集的 **OpsData** 頁面。

1. 選擇**開始匯出**。
**注意**  
第一次匯出 OpsData 時，系統會為匯出建立擔任角色。您無法修改預設擔任角色。

1. 針對 **S3 儲存貯體名稱**，選擇一個現有的儲存貯體。如果需要，可選擇**建立**來建立一個 Amazon S3 儲存貯體。

   如果您無法變更某個 S3 儲存貯體的名稱，則表示您此前是從**設定**頁面設定儲存貯體名稱。您只能從**設定**頁面變更該儲存貯體的名稱。
**注意**  
在 Explorer 中，您只能從您第一次設定這些設定的頁面編輯 Amazon S3 儲存貯體名稱和 Amazon SNS 主題 ARN。

1. 針對 **SNS 主題 ARN**，請選擇一個現有的 Amazon SNS 主題 ARN，用於在下載完成時進行通知。

   如果您無法變更某個 Amazon SNS 主題 ARN，則表示您此前是從**設定**頁面設定 Amazon SNS 主題 ARN。您只能從**設定**頁面變更該主題 ARN。

1. (選用) 針對 **SNS 成功訊息**，請指定匯出成功完成時要顯示的成功訊息。

1. 選擇**提交**。系統會導覽至上一頁，並顯示**按一下以檢視匯出程序狀態訊息。檢視詳細資訊**。

   您可以選擇**檢視詳細資訊**以在 Systems Manager Automation 中檢視執行手冊的狀態和進度。

您現在可以將 OpsData 從 Explorer 匯出至指定的 Amazon S3 儲存貯體。

如果您無法使用此程序匯出資料，請確認使用者、群組或角色是否包含 `iam:CreatePolicyVersion` 和 `iam:DeletePolicyVersion` 動作的許可。如需有關將這些動作新增至使用者、群組或角色的相關資訊，請參閱《IAM 使用者指南》**中的[編輯 IAM 政策](https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_manage-edit.html)。

# Systems Manager Explorer 故障診斷
<a name="Explorer-troubleshooting"></a>

本主題涵蓋的資訊能協助您了解如何針對 AWS Systems Manager Explorer 的常見問題進行故障診斷。

 **資源資料同步停止運作** 

如果您的資源資料同步因*選擇加入 AWS 區域*而停止運作，請驗證設定同步的 AWS Organizations 管理帳戶和成員帳戶是否已選擇加入該區域。

對於您的 AWS 帳戶，大部分 AWS 區域預設為作用中，但只有在您手動選取特定區域時，才會啟用這些區域。這些區域稱為[選擇加入區域](https://docs.aws.amazon.com/global-infrastructure/latest/regions/aws-regions.html#regions-opt-in-status)。依預設，Explorer 跨帳戶/跨區域資源資料同步在選擇加入區域中不支援資料彙總。我們已於 2025 年 6 月 30 日新增對下列選擇加入區域的支援。
+ 歐洲 (米蘭)
+ 非洲 (開普敦)
+ 中東 (巴林)
+ 亞太區域 (香港)

請注意，您無法使用委派管理員帳戶在選擇加入區域中建立資源資料同步。您必須使用 AWS Organizations 管理帳戶。

 **在 **Settings** (設定) 頁面上更新標籤後，無法篩選 Explorer 中的 AWS 資源** 

如果您在 Explorer 中更新標籤鍵或其他資料設定，系統可能需要長達六個小時才能根據您的變更同步資料。

 ***Create resource data sync* (建立資源資料同步) 頁面上的 AWS Organizations 會顯示為灰色** 

**建立資源資料同步**頁面上的**包含來自我的 AWS Organizations 組態的所有帳戶**與**選擇 AWS Organizations 中的組織單位**選項僅在安裝及設定 AWS Organizations 時可用。如果您已安裝並設定 AWS Organizations，則 AWS Organizations 管理帳戶或 Explorer 委派管理員可以建立使用這些選項的資源資料同步。

如需詳細資訊，請參閱 [設定 Systems Manager Explorer 以顯示來自多個帳戶和區域的資料](Explorer-resource-data-sync.md) 及 [設定 Explorer 的委派管理員](Explorer-setup-delegated-administrator.md)。

 **Explorer 完全不顯示任何資料** 
+ 確認您已在您要 Explorer 能存取和顯示資料的每個帳戶和區域中完成整合式設定。如果沒有這樣做，Explorer 將不會顯示未完成整合式設定的帳戶和區域的 OpsData 和 OpsItems。如需更多詳細資訊，請參閱 [開始使用 Systems Manager Explorer 和 OpsCenter](Explorer-setup.md)。
+ 使用 Explorer 檢視來自多個帳戶和區域的資料時，請確認您已登入 AWS Organizations 管理帳戶或 Explorer 委派管理員帳戶。若要檢視來自多個帳戶和區域的 OpsData 和 OpsItems，您必須登入此帳戶。

 **Amazon EC2 執行個體的相關小工具未顯示資料** 

如果 Amazon Elastic Compute Cloud (Amazon EC2) 執行個體的相關小工具 (例如 **Instance count** (執行個體計數)、**Managed instances** (受管執行個體) 以及 **Instance by AMI** (依 AMI 的執行個體) 小工具) 未顯示資料，請確認下列項目：
+ 確認您已等待數分鐘。完成整合式設定之後，OpsData 可能需要數分鐘的時間才會在 Explorer 中顯示。
+ 確認您已設定 AWS Config 組態記錄器。Explorer 使用 AWS Config 組態記錄器提供的資料，在 Widget 中填入有關 EC2 執行個體的資訊。如需詳細資訊，請參閱[管理組態記錄器](https://docs.aws.amazon.com/config/latest/developerguide/stop-start-recorder.html)。
+ 在 **Settings** (設定) 頁面上，確認 **Amazon EC2** OpsData 來源處於作用中狀態。此外，請確認自啟用組態記錄器或自您對執行個體進行變更後，已超過 6 小時。初始啟用組態記錄器或對執行個體進行變更後，最多可能需要六個小時的時間，Systems Manager 才能在 Explorer EC2 小工具中顯示來自 AWS Config 的資料。
+ 請注意，如果執行個體已停止或終止，則 Explorer 會在 24 小時後停止顯示這些執行個體。
+ 確認您位於設定 Amazon EC2 執行個體的正確 AWS 區域。Explorer 不會顯示內部部署執行個體的相關資料。
+ 如果您設定了多個帳戶和區域的資源資料同步，請確認您已登入 Organizations 管理帳戶或 Explorer 委派管理員帳戶。

 **修補 Widget 不會顯示資料** 

**Non-compliant instances for patching** (用於修補的不合規執行個體) 小工具只會顯示不合規之修補程式執行個體的相關資料。如果您的執行個體合規，則此 Widget 不會顯示任何資料。如果您懷疑有不合規的執行個體，那麼，請確認您已安裝和設定 Systems Manager 修補，並使用 AWS Systems Manager Patch Manager 來檢查修補程式合規。如需更多詳細資訊，請參閱 [AWS Systems Manager Patch Manager](patch-manager.md)。

 **雜項問題** 

**Explorer 不允許您編輯或補救 OpsItems**：OpsItems 檢視的跨帳戶或區域是唯讀的。只能從其家用帳戶或區域更新和補救。

# AWS Systems Manager OpsCenter
<a name="OpsCenter"></a>

OpsCenter是 中的工具 AWS Systems Manager，提供中央位置，讓營運工程師和 IT 專業人員可以檢視、調查和解決與 AWS 資源相關的操作工作項目 (OpsItems)。 OpsCenter 旨在縮短對影響 AWS 資源的問題進行解決的平均時間。 OpsItems會跨 服務OpsCenter彙總和標準化OpsItems，同時提供每個 OpsItem、相關 和相關資源的情境式調查資料。 OpsCenter也提供 Systems Manager Automation 執行手冊，供您用來快速解決問題。您可以為每個 OpsItem 指定可搜尋的自訂資料。您也可以依狀態及來源，檢視自動產生的 OpsItems 摘要報告。若要開始使用 OpsCenter，請開啟 [Systems Manager 主控台](https://console.aws.amazon.com//systems-manager/opsitems)。在導覽窗格中，選擇 **OpsCenter**。

OpsCenter 與 Amazon EventBridge 及 Amazon CloudWatch 整合。這表示您可以將這些服務設定為在 CloudWatch 警示進入 `ALARM` 狀態OpsCenter，或 EventBridge 從發佈事件的任何 AWS 服務處理事件時，在 OpsItem中自動建立 。設定 CloudWatch 警示和 EventBridge 事件以自動建立OpsItems可讓您快速診斷和修復來自單一主控台 AWS 的資源問題。

為了協助您診斷問題，每個 都OpsItem包含情境相關資訊，例如 AWS 產生 的資源名稱和 IDOpsItem、警示或事件詳細資訊、警示歷史記錄，以及警示時間軸圖表。

對於 AWS 資源， 會OpsCenter彙總來自 AWS Config、 AWS CloudTrail 日誌和 Amazon CloudWatch Events 的資訊，因此您在調查期間不需要瀏覽多個主控台頁面。

下列清單包含客戶設定 CloudWatch 警示來建立 AWS 的資源和指標類型OpsItems。
+ Amazon DynamoDB：資料庫讀取和寫入動作達到閾值
+ Amazon EC2：CPU 使用率達到閾值
+ AWS 計費：預估費用達到閾值
+ Amazon EC2：執行個體未通過狀態檢查
+ Amazon Elastic Block Store (EBS)：磁碟空間使用率達到閾值

下列清單包含客戶設定的 EventBridge 規則類型，以建立 OpsItems。
+ AWS Security Hub CSPM：已發出安全提醒
+ DynamoDB：調節事件
+ Amazon EC2 Auto Scaling：無法啟動執行個體
+ Systems Manager：無法執行自動化
+ AWS Health：排定維護的提醒
+ EC2：執行個體狀態從 `Running` 變更為 `Stopped`

OpsCenter 也已經與 .NET 和 SQL Server 的 Amazon CloudWatch Application Insights 整合。這表示您可以為您應用程式中偵測到的問題自動建立 OpsItems。您也可以OpsCenter與 整合 AWS Security Hub CSPM ，在 Systems Manager 中彙總安全性、效能和操作問題並採取行動。

操作工程師和 IT 專業人員可以使用 AWS Systems Manager 主控台中的 OpsCenter頁面、公OpsItems有 API 操作、 AWS Command Line Interface (AWS CLI)、 或 AWS SDKs 來建立 AWS Tools for Windows PowerShell、檢視和編輯。OpsCenter公有 API 操作也可讓您OpsCenter整合您的案例管理系統和運作狀態儀表板。

## OpsCenter 如何為我的組織帶來益處？
<a name="OpsCenter-learn-more-benefits"></a>

OpsCenter 提供標準和統一的體驗，用於檢視、處理和修復與 AWS 資源相關的問題。標準及一致的體驗可改善修正問題、調查相關問題及培訓新營運工程師和 IT 專業人員所需的時間。標準和一致的體驗也可以降低在系統中管理和修正問題的手動錯誤數量。

尤有甚者，OpsCenter 為營運工程師和組織提供下列優勢：
+ 您不再需要跨多個主控台頁面進行導覽，即可檢視、調查和解決與 AWS 資源OpsItems相關的問題。 OpsItems 會跨服務集中彙總。
+ 您可以檢視 OpsItems 的服務特定或與內容相關的資料；這些資料是由 CloudWatch 警示、EventBridge 事件和 .NET 及 SQL Server 的 CloudWatch Application Insights 自動產生。
+ 您可以指定與 OpsItem 相關的資源 Amazon Resource Name (ARN)。透過指定相關的資源，OpsCenter 使用內建的邏輯協助您避免建立重複的 OpsItems。
+ 您可以檢視類似 OpsItems 的詳細資訊和解決資訊。
+ 您可以快速檢視資訊以及執行 Systems Manager Automation Runbook 來解決問題。

## OpsCenter 有哪些功能？
<a name="OpsCenter-learn-more-features"></a>
+ **自動和手動建立 OpsItem**

  OpsCenter 與 Amazon CloudWatch 整合。這表示您可以將 CloudWatch 設定為在警示進入 `ALARM` 狀態時或 Amazon EventBridge 處理來自任何發佈事件之 AWS 服務的事件時，自動在 OpsCenter 中建立 OpsItem。您也可以手動建立 OpsItems。

  OpsCenter 也已經與 .NET 和 SQL Server 的 Amazon CloudWatch Application Insights 整合。這表示您可以為您應用程式中偵測到的問題自動建立 OpsItems。
+ **詳細和可搜尋的 OpsItems**

  每個 OpsItem 包含多個資訊欄位，包括標題、ID、優先順序、描述、OpsItem 的來源，以及上次更新的日期/時間。每個 OpsItem 還包含以下可設定的功能：
  + **Status (狀態)**：Open (開放)、In progress (正在進行)、Resolved (已解決)，或 Open and In progress (開放並正在進行)。
  + **相關資源**：相關資源是受影響的資源，或起始建立 OpsItem 之 EventBridge 事件的資源。每個 OpsItem 都包含 **Related resources (相關資源)** 區段，OpsCenter 會在此自動列出相關資源的 Amazon Resource Name (ARN)。您也可以手動指定相關資源的 ARN。針對某些 ARN 類型，OpsCenter 會自動建立深度連結，顯示資源的詳細資訊，不必瀏覽其他主控台頁面即可檢視該資訊。例如，如果您指定 EC2 執行個體的 ARN，您可以在 OpsCenter 中檢視所有 EC2 提供之該執行個體的詳細資訊。您可以手動新增其他相關資源的 ARN。每個 OpsItem 最多可以列出 100 個相關的資源 ARN。如需詳細資訊，請參閱[將相關的資源新增至 OpsItem](OpsCenter-working-with-OpsItems-adding-related-resources.md)。
  + **相關和類似的 OpsItems**：**Related OpsItems** (相關的 OpsItem) 功能可讓您指定 OpsItems 的 ID，它們與目前的 OpsItem 有某種關聯。**Similar OpsItem** (類似的 OpsItem) 功能會自動檢閱 OpsItem 標題和描述，然後列出其他相關或您感興趣的 OpsItems。
  + **Searchable and private operational data (可搜尋的私有營運資料)**：營運資料是自訂資料，提供有用的 OpsItem 參考詳細資訊。例如，您可以指定日誌檔案、錯誤字串、授權金鑰、故障診斷秘訣，或其他相關資料。您輸入營運資料做為金鑰/值對。金鑰的最大長度為 128 個字元。值的大小上限為 20 KB。

    這個自訂資料可供搜尋，但有所限制。針對 **Searchable operational data** (可搜尋操作資料) 功能，所有能存取 OpsItem 概觀頁面的使用者 (如[描述 OpsItem API](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DescribeOpsItems.html) 動作所提供) 都可以檢視和搜尋指定的資料。針對 **Private operational data** (私有操作資料) 功能，只有能夠存取 OpsItem 的使用者可檢視此資料 (如 [GetOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsItem.html) API 操作所提供)。
  + **重複資料刪除**：透過指定相關資源，OpsCenter 會使用內建的邏輯協助您避免建立重複的 OpsItems。OpsCenter 也包含名為 **Operational insights** (操作洞察) 的功能，其中顯示有關重複 OpsItems 的資訊。為了進一步限制帳戶中重複 OpsItems 的數量，您可以手動指定 EventBridge 事件規則的重複資料刪除字串。如需詳細資訊，請參閱[管理重複的 OpsItems](OpsCenter-working-deduplication.md)。
+ **大量編輯 OpsItems**：您可以在 OpsCenter 中選取多個 OpsItems，然後編輯下列其中一個欄位：**Status** (狀態)、**Priority** (優先順序)、**Severity** (嚴重性)、**Category** (類別)。
+ **使用 Runbook 輕鬆修復**

  每個 都OpsItem包含 **Runbooks** 區段，其中包含 Systems Manager Automation Runbook 的清單，可用來自動修復 AWS 資源的常見問題。如果您開啟 OpsItem，請選擇該 AWS 的資源OpsItem，然後在 主控台中選擇**執行自動化**按鈕，然後OpsCenter提供可在產生 AWS 的資源上執行的 Automation Runbook 清單OpsItem。從 OpsItem 執行 Automation Runbook 之後，Runbook 會自動與 OpsItem 的相關資源建立關聯，以供日後參考。此外，如果使用 OpsCenter 在 EventBridge 中自動設定 OpsItem 規則，則 EventBridge 會自動關聯常見事件的 Runbook。OpsCenter 會為特定 OpsItem 保留 30 天的 Automation Runbook 執行記錄。如需詳細資訊，請參閱[修正 OpsItem 問題](OpsCenter-remediating.md)。
+ **變更通知**：您可以指定 Amazon Simple Notification Service (SNS) 主題的 ARN 並在 OpsItem 變更或編輯時隨時發佈通知。SNS 主題必須存在於與 AWS 區域 相同的 中OpsItem。
+ **Comprehensive search capabilities (全方位的 OpsItem 搜尋功能)**：OpsCenter 提供多個搜尋選項，協助您快速找到 OpsItems。以下是幾個搜尋方式範例：OpsItem ID、標題、上次修改時間、營運資料值、來源和 Runbook 執行的 Automation ID，還有更多。您可以使用狀態篩選條件進一步限制搜尋結果。
+ **OpsItem 摘要報告**

  OpsCenter 包含自動顯示下列區段的摘要報告頁面：
  + **Status summary (狀態摘要)**：依狀態的 OpsItems 摘要 (Open (開放)、In progress (正在進行)、Resolved (已解決)、Open and In progress (開放和正在進行))。
  + **最多開啟 的來源OpsItems**：最多開啟 AWS 服務的明細OpsItems。
  + ** by source and age (依來源和天數分組的 OpsItems)**：依來源和建立天數分組的 OpsItems 計數。

  如需檢視 OpsCenter 摘要報告的詳細資訊，請參閱 [檢視 OpsCenter 摘要報告](OpsCenter-reports.md)。
+ **記錄和稽核功能支援**

  您可以透過與其他 AWS 服務的整合， AWS 帳戶 在 中稽核和記錄OpsCenter使用者動作。如需詳細資訊，請參閱[檢視 OpsCenter 日誌和報告](OpsCenter-logging-auditing.md)。
+ **主控台、CLI、PowerShell 和 OpsCenter 工具的 SDK 存取權**

  您可以使用 AWS Systems Manager 主控台、 AWS Command Line Interface (AWS CLI) AWS Tools for PowerShell、 或您選擇的 AWS SDK OpsCenter來使用 。

## OpsCenter 與我現有的案例管理系統整合嗎？
<a name="OpsCenter-learn-more-case-management"></a>

OpsCenter 旨在補充您現有的案例管理系統。您可以使用公有 API 操作，將 OpsItems 整合到您現有的案例管理系統。您也可以在目前的系統中維持手動的生命週期工作流程，使用 OpsCenter 做為調查和修復中樞。

如需 OpsCenter 公有 API 操作的詳細資訊，請參閱《*AWS Systems Manager API 參考*》中的以下 API 操作。
+ [CreateOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateOpsItem.html)
+ [DescribeOpsItems](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DescribeOpsItems.html)
+ [GetOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsItem.html)
+ [GetOpsSummary](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsSummary.html)
+ [UpdateOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_UpdateOpsItem.html)

## 使用 OpsCenter 需要付費嗎？
<a name="OpsCenter-learn-more-cost"></a>

是。如需詳細資訊，請參閱[AWS Systems Manager 定價](https://aws.amazon.com/systems-manager/pricing/)。

## OpsCenter 適用於內部部署和混合式受管節點嗎？
<a name="OpsCenter-learn-more-hybrid"></a>

是。您可以使用 OpsCenter 調查和修復針對 Systems Manager 設定之內部部署受管節點的問題。如需安裝和設定 Systems Manager 內部部署伺服器和虛擬機器的詳細資訊，請參閱 [使用 Systems Manager 在混合多雲端環境中管理節點](systems-manager-hybrid-multicloud.md)。

## OpsCenter 的配額為何？
<a name="OpsCenter-learn-more-limits"></a>

您可以在 *Amazon Web Services 一般參考* 的 [Systems Manager Service Quotas](https://docs.aws.amazon.com/general/latest/gr/ssm.html#limits_ssm) 中檢視所有 Systems Manager 工具的配額。除非另有說明，否則每個配額都是區域特定的。

# 設定 OpsCenter
<a name="OpsCenter-setup"></a>

AWS Systems Manager 使用整合式設定來協助您開始使用 OpsCenter 和 Explorer (Systems Manager 中的工具)。Explorer 是可自訂操作儀表板，用於報告 AWS 資源的相關資訊。在本文件中，Explorer 和 OpsCenter 設定稱為*整合式設定*。

您必須使用整合式設定來透過 Explorer 設定 OpsCenter。整合式設定僅適用於 AWS Systems Manager 主控台。您無法以程式設計方式設定 Explorer 和 OpsCenter。如需更多詳細資訊，請參閱 [開始使用 Systems Manager Explorer 和 OpsCenter](Explorer-setup.md)。

**開始之前**  
當您設定 OpsCenter 時，您可以在自動建立 OpsItems 的 Amazon EventBridge 中啟用預設規則。下表說明自動建立 OpsItems 的預設 EventBridge 規則。您可以在 **OpsItem 規則**下的 OpsCenter **設定**頁面中停用 EventBridge 規則。

**重要**  
系統針對預設規則建立的 OpsItems 向您的帳戶收取費用。如需詳細資訊，請參閱[AWS Systems Manager定價](https://aws.amazon.com/systems-manager/pricing/)。


****  

| 規則名稱 | 描述 | 
| --- | --- | 
|  SSMOpsItems-Autoscaling-instance-launch-failure  |  此規則會在 EC2 自動擴展執行個體啟動失敗時建立 OpsItems。  | 
|  SSMOpsItems-Autoscaling-instance-termination-failure  |  此規則會在 EC2自動擴展執行個體終止失敗時建立 OpsItems。  | 
|  SSMOpsItems-EBS-snapshot-copy-failed  |  此規則會在系統複製 Amazon Elastic Block Store (Amazon EBS) 快照失敗時建立 OpsItems。  | 
|  SSMOpsItems-EBS-snapshot-creation-failed  |  此規則會在系統建立 Amazon EBS 快照失敗時建立 OpsItems。  | 
|  SSMOpsItems-EBS-volume-performance-issue  |  此規則對應於 AWS Health 追蹤規則。該規則會在 Amazon EBS 磁碟區 (運作狀態事件 = `AWS_EBS_DEGRADED_EBS_VOLUME_PERFORMANCE`) 發生效能問題時建立 OpsItems。  | 
|  SSMOpsItems-EC2-issue  |  此規則對應於影響 AWS 服務或資源的未預期事件的 AWS Health 追蹤規則。該規則會建立 OpsItems，例如，服務傳送有關造成服務降級之操作問題的通訊，或提高本地化資源層級問題的意識。例如，此規則會為下列事件建立 OpsItem：`AWS_EC2_OPERATIONAL_ISSUE`。  | 
|  SSMOpsItems-EC2-scheduled-change  |  此規則對應於 AWS Health 追蹤規則。AWS 可為執行個體排程事件，例如重新開機、停止或啟動執行個體。該規則會為 EC2 已排程事件建立 OpsItems。如需有關已排程事件的詳細資訊，請參閱《Amazon EC2 使用者指南》**中的 [Scheduled events for your instances](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/monitoring-instances-status-check_sched.html)。  | 
|  SSMOpsItems-RDS-issue  |  此規則對應於影響 AWS 服務或資源的未預期事件的 AWS Health 追蹤規則。該規則會建立 OpsItems，例如，服務傳送有關造成服務降級之操作問題的通訊，或提高本地化資源層級問題的意識。例如，此規則會為下列事件建立 OpsItem：`AWS_RDS_MYSQL_DATABASE_CRASHING_REPEATEDLY`、`AWS_RDS_EXPORT_TASK_FAILED` 和 `AWS_RDS_CONNECTIVITY_ISSUE`。  | 
|  SSMOpsItems-RDS-scheduled-change  |  此規則對應於 AWS Health 追蹤規則。該規則會為 Amazon RDS 已排程事件建立 OpsItems。已排程事件會提供 Amazon RDS 資源即將發生之變更的相關資訊。部分事件可能會建議您採取行動以避免服務中斷。其他事件會自動發生，您無需採取任何動作。在已排定變更活動期間，您的資源可能暫時無法使用。例如，此規則會為下列事件建立 OpsItem：`AWS_RDS_SYSTEM_UPGRADE_SCHEDULED` 和 `AWS_RDS_MAINTENANCE_SCHEDULED`。如需有關已排程事件的詳細資訊，請參閱《*AWS Health 使用者指南*》中的[事件類型類別](https://docs.aws.amazon.com/health/latest/ug/aws-health-concepts-and-terms.html#event-type-categories)。  | 
|  SSMOpsItems-SSM-maintenance-window-execution-failed  |  此規則會在處理 Systems Manager 維護視窗失敗時建立 OpsItems。  | 
|  SSMOpsItems-SSM-maintenance-window-execution-timedout  |  此規則會在啟動「系統維護」視窗逾時時建立 OpsItems。  | 

使用下列程序來設定 OpsCenter。

**設定 OpsCenter**

1. 開啟位於 [https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 的 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 在 OpsCenter 首頁上，選擇**入門**。

1. 在 OpsCenter 設定頁面上，選擇**啟用此選項，讓 Explorer 設定 AWS Config 和 Amazon CloudWatch Events 以根據常用規則和事件自動建立 OpsItems**。如果不選擇此選項，OpsCenter 會保持停用。
**注意**  
Amazon EventBridge (前稱為 Amazon CloudWatch Events) 不僅提供 CloudWatch Events 的所有功能，還提供一些新功能，例如自訂事件匯流排、第三方事件來源和結構描述登錄檔。

1. 選擇 **啟用OpsCenter** 。

啟用 OpsCenter 後，您可以從**設定**執行以下操作：
+ 使用**打開 CloudWatch 主控台**按鈕建立 CloudWatch 警示。如需更多詳細資訊，請參閱 [設定 CloudWatch 警示以建立 OpsItems](OpsCenter-create-OpsItems-from-CloudWatch-Alarms.md)。
+ 啟用操作洞察。如需更多詳細資訊，請參閱 [分析操作洞察以減少 OpsItems](OpsCenter-working-operational-insights.md)。
+ 啟用 AWS Security Hub CSPM 問題清單警示。如需更多詳細資訊，請參閱 [了解與 的OpsCenter整合 AWS Security Hub CSPM](OpsCenter-applications-that-integrate.md#OpsCenter-integrate-with-security-hub)。

**Topics**
+ [(選用) 設定 OpsCenter 以跨帳戶集中管理 OpsItems](OpsCenter-setting-up-cross-account.md)
+ [(選用) 設定 Amazon SNS 以接收有關 OpsItems 的通知](OpsCenter-getting-started-sns.md)

# (選用) 設定 OpsCenter 以跨帳戶集中管理 OpsItems
<a name="OpsCenter-setting-up-cross-account"></a>

您可以使用 Systems Manager OpsCenter 集中管理所選 AWS 帳戶 中的OpsItems多個 AWS 區域。在 中設定您的組織後，即可使用此功能 AWS Organizations。 AWS Organizations 是一種帳戶管理服務，可讓您將多個 AWS 帳戶合併到您建立並集中管理的組織。 AWS Organizations 包含帳戶管理和合併帳單功能，可讓您更完善地滿足業務的預算、安全和合規需求。如需詳細資訊，請參閱*AWS Organizations 《 使用者指南*》中的[什麼是 AWS Organizations？](https://docs.aws.amazon.com/organizations/latest/userguide/orgs_introduction.html) 

屬於 AWS Organizations 管理帳戶的使用者可以為 Systems Manager 設定委派管理員帳戶。對於 OpsCenter 而言，受委派管理員可以建立、編輯和檢視成員帳戶中的 OpsItems。委派管理員也可以使用 Systems Manager Automation Runbook 大量解決OpsItems或修復產生 AWS 的資源問題OpsItems。

**注意**  
您只能將一個帳戶指定為 Systems Manager 的受委派管理員。如需詳細資訊，請參閱[為 Systems Manager 建立 AWS Organizations 委派管理員](setting_up_delegated_admin.md)。

Systems Manager 提供下列方法來設定 OpsCenter 以跨多個 AWS 帳戶集中管理 OpsItems。
+ **Quick Setup**：Quick Setup 是 Systems Manager 中的工具，可簡化 Systems Manager 工具的設定和組態任務。如需詳細資訊，請參閱[AWS Systems Manager Quick Setup](systems-manager-quick-setup.md)。

  OpsCenter 的快速設定可協助您完成實現跨帳戶管理 OpsItems 所需進行的下列任務：
  + 將一個帳戶註冊為受委派管理員 (如果尚未指定受委派管理員)
  + 建立 required AWS Identity and Access Management (IAM) 政策和角色
  + 指定委派管理員可以OpsItems跨帳戶管理 AWS Organizations 的組織或組織單位 (OUs)

  如需詳細資訊，請參閱[(選用) 使用 Quick Setup 設定 OpsCenter 以跨帳戶管理 OpsItems](OpsCenter-quick-setup-cross-account.md)。
**注意**  
快速設定不適用於目前可使用 Systems Manager 的所有 AWS 區域 。如果您使用的區域無法使用快速設定對 OpsCenter 進行設定以實現跨多個帳戶集中管理 OpsItems，則您必須使用手動方法。若要檢視可使用快速設定 AWS 區域 的位置清單，請參閱 [Quick Setup 中的 可用性 AWS 區域](systems-manager-quick-setup.md#quick-setup-getting-started-regions)。
+ **手動設定**：如果您使用的區域無法使用快速設定對 OpsCenter 進行設定以實現跨多個帳戶集中管理 OpsItems，則您可以使用手動方法實現。如需詳細資訊，請參閱[(選用) 手動設定 OpsCenter 以跨帳戶集中管理 OpsItems](OpsCenter-getting-started-multiple-accounts.md)。

# (選用) 使用 Quick Setup 設定 OpsCenter 以跨帳戶管理 OpsItems
<a name="OpsCenter-quick-setup-cross-account"></a>

Quick Setup中的工具 AWS Systems Manager可簡化 Systems Manager 工具的設定和組態任務。 Quick Setup for OpsCenter可協助您完成下列OpsItems跨帳戶管理任務：
+ 指定受委派管理員帳戶
+ 建立 required AWS Identity and Access Management (IAM) 政策和角色
+ 指定 AWS Organizations 組織或成員帳戶的子集，委派管理員可以OpsItems跨帳戶管理

當您設定 OpsCenter 以使用快速設定跨帳號管理 OpsItems 時，Quick Setup 會在指定的帳戶中建立下列資源。這些資源提供指定帳戶使用 的許可OpsItems，並使用 Automation Runbook 修正產生 之 AWS 資源的問題OpsItems。


****  

| Resources | 帳戶 | 
| --- | --- | 
|  `AWSServiceRoleForAmazonSSM_AccountDiscovery` AWS Identity and Access Management (IAM) 服務連結的角色 如需有關此角色的詳細資訊，請參閱 [使用 角色來收集 OpsCenter和 AWS 帳戶 的資訊 Explorer](using-service-linked-roles-service-action-2.md)。  |  AWS Organizations 管理帳戶和委派管理員帳戶  | 
|  `OpsItem-CrossAccountManagementRole` IAM 角色  `AWS-SystemsManager-AutomationAdministrationRole` IAM 角色  |  委派管理員帳戶  | 
|  `OpsItem-CrossAccountExecutionRole` IAM 角色  `AWS-SystemsManager-AutomationExecutionRole` IAM 角色  適用於預設 OpsItem 群組 (`OpsItemGroup`) 的 `AWS::SSM::ResourcePolicy` Systems Manager 資源政策  |  所有 AWS Organizations 成員帳戶  | 

**注意**  
如果您先前OpsCenter已設定使用[手動方法](https://docs.aws.amazon.com/systems-manager/latest/userguide/OpsCenter-getting-started-multiple-accounts.html)OpsItems跨帳戶管理 ，則必須刪除在該程序的步驟 4 和 5 期間建立的 AWS CloudFormation 堆疊或堆疊集。當您完成以下程序時，如果這些資源存在於您的帳戶中，則 Quick Setup 無法正確設定跨帳戶 OpsItem 管理。

**使用快速設定設定 OpsCenter 以跨帳戶管理 OpsItems**

1.  AWS 管理主控台 使用 AWS Organizations 管理帳戶登入 。

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Quick Setup**。

1. 選擇**程式庫**索引標籤。

1. 捲動至底部並找到 **OpsCenter** 組態圖磚。選擇**建立**。

1. 在 Quick Setup OpsCenter 頁面的**受委派管理員**區段中，輸入帳戶 ID。如果您無法編輯此欄位，則表示已為 Systems Manager 指定受委派管理員帳戶。

1. 在 **Targets** (目標) 區段中，選擇一個選項。如果您選擇**自訂**，請選取您要跨帳戶管理 OpsItems 的組織單位 (OU)。

1. 選擇**建立**。

Quick Setup 會建立 OpsCenter 組態並將必要的 AWS 資源部署到指定的 OU。

**注意**  
如果您不想跨多個帳戶管理 OpsItems，可以從 Quick Setup 中刪除相關組態。刪除組態時，Quick Setup 會刪除最初部署組態時建立的下列 IAM 政策和角色：  
受委派管理員帳戶的 `OpsItem-CrossAccountManagementRole`
來自所有 Organizations 成員帳戶的 `OpsItem-CrossAccountExecutionRole` 和 `SSM::ResourcePolicy`
Quick Setup 會移除所有組織單位以及最初部署組態的 AWS 區域 中的組態。

## 使用 OpsCenter 的 Quick Setup 組態診斷並解決問題
<a name="OpsCenter-quick-setup-cross-account-troubleshooting"></a>

本節包含的資訊可協助您在使用 Quick Setup 設定跨帳戶 OpsItem 管理時診斷並解決問題。

**Topics**
+ [部署到這些堆疊集失敗：delegatedAdmin](#OpsCenter-quick-setup-cross-account-troubleshooting-stack-set-failed)
+ [Quick Setup 組態狀態顯示失敗](#OpsCenter-quick-setup-cross-account-troubleshooting-configuration-failed)

### 部署到這些堆疊集失敗：delegatedAdmin
<a name="OpsCenter-quick-setup-cross-account-troubleshooting-stack-set-failed"></a>

建立 OpsCenter 組態時，Quick Setup 會在 Organizations 管理帳戶中部署兩個 AWS CloudFormation 堆疊集。這些堆疊集使用以下字首：`AWS-QuickSetup-SSMOpsCenter`。如果 Quick Setup 顯示以下錯誤：`Deployment to these StackSets failed: delegatedAdmin` 使用以下程序來修正此問題。

**診斷並解決 "StackSets failed:delegatedAdmin" 錯誤**

1. 如果您在Quick Setup主控台的紅色橫幅中收到`Deployment to these StackSets failed: delegatedAdmin`錯誤，請登入委派管理員帳戶，並將 AWS 區域 指定為Quick Setup主要區域。

1. 在 https：//[https://console.aws.amazon.com/cloudformation](https://console.aws.amazon.com/cloudformation/) 開啟 CloudFormation 主控台。

1. 選擇 Quick Setup 組態建立的堆疊。堆疊名稱包含下列項目：**AWS-QuickSetup-SSMOpsCenter**。
**注意**  
CloudFormation 有時會刪除失敗的堆疊部署。如果堆疊在**堆疊**資料表中不可用，請從篩選條件清單中選擇**已刪除**。

1. 檢視 **Status** (狀態) 和 **Status reason** (狀態原因)。如需堆疊狀態的詳細資訊，請參閱《AWS CloudFormation 使用者指南**》中的[堆疊狀態碼](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/cfn-console-view-stack-data-resources.html#cfn-console-view-stack-data-resources-status-codes)。

1. 要想了解失敗的確切步驟，請在**事件**標籤中檢視每個事件的**狀態**。如需詳細資訊，請參閱《AWS CloudFormation 使用者指南》**中的[故障診斷](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/troubleshooting.html)一節。

**注意**  
如果無法使用 CloudFormation 故障診斷步驟解決部署失敗問題，請刪除組態後再試一次。

### Quick Setup 組態狀態顯示失敗
<a name="OpsCenter-quick-setup-cross-account-troubleshooting-configuration-failed"></a>

如果**組態詳細資訊**頁面上的**組態詳細資訊**資料表顯示 的組態狀態`Failed`，請登入失敗的 AWS 帳戶 和 區域。

**診斷並解決因 Quick Setup 失敗而無法建立 OpsCenter 組態的問題**

1. 登入失敗發生的 AWS 帳戶 和 AWS 區域 。

1. 在 https：//[https://console.aws.amazon.com/cloudformation](https://console.aws.amazon.com/cloudformation/) 開啟 CloudFormation 主控台。

1. 選擇 Quick Setup 組態建立的堆疊。堆疊名稱包含下列項目：**AWS-QuickSetup-SSMOpsCenter**。
**注意**  
CloudFormation 有時會刪除失敗的堆疊部署。如果堆疊在**堆疊**資料表中不可用，請從篩選條件清單中選擇**已刪除**。

1. 檢視 **Status** (狀態) 和 **Status reason** (狀態原因)。如需堆疊狀態的詳細資訊，請參閱《AWS CloudFormation 使用者指南**》中的[堆疊狀態碼](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/cfn-console-view-stack-data-resources.html#cfn-console-view-stack-data-resources-status-codes)。

1. 要想了解失敗的確切步驟，請在**事件**標籤中檢視每個事件的**狀態**。如需詳細資訊，請參閱《AWS CloudFormation 使用者指南》**中的[故障診斷](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/troubleshooting.html)一節。

#### 成員帳戶組態顯示 ResourcePolicyLimitExceededException
<a name="OpsCenter-quick-setup-cross-account-troubleshooting-policy-limit-exception"></a>

如果某個堆疊的狀態顯示為 "`ResourcePolicyLimitExceededException`"，則表示該帳戶先前已使用[手動方法](https://docs.aws.amazon.com/systems-manager/latest/userguide/OpsCenter-getting-started-multiple-accounts.html)加入 OpsCenter 跨帳戶管理。若要解決此問題，您必須刪除在手動加入程序的步驟 4 和 5 期間建立的 AWS CloudFormation 堆疊或堆疊集。如需詳細資訊，請參閱*AWS CloudFormation 《 使用者指南*》中的[刪除堆疊集](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-delete.html)和[刪除 CloudFormation 主控台上的堆疊](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/cfn-console-delete-stack.html)。

# (選用) 手動設定 OpsCenter 以跨帳戶集中管理 OpsItems
<a name="OpsCenter-getting-started-multiple-accounts"></a>

本節說明如何手動設定 OpsCenter 以跨帳戶管理 OpsItem。儘管此程序仍然受到支援，但它已被使用 Systems Manager Quick Setup 的新程序所取代。如需詳細資訊，請參閱[(選用) 使用 Quick Setup 設定 OpsCenter 以跨帳戶管理 OpsItems](OpsCenter-quick-setup-cross-account.md)。

您可以設定一个中央帳戶，以便為成員帳戶手動建立 OpsItems，管理並修正這些 OpsItems。中央帳戶可以是管理帳戶，也可以是 AWS Organizations AWS Organizations 管理帳戶和 Systems Manager 委派管理員帳戶。我們建議您使用 Systems Manager 受委派的管理員帳戶作為中央帳戶。在設定 AWS Organizations之後才能使用此功能。

使用 AWS Organizations，您可以將多個 合併 AWS 帳戶 到您集中建立和管理的組織。中央帳戶使用者可以為所有選取的成員帳戶同時建立 OpsItems，並管理這些 OpsItems。

使用本節中的程序，在 Organizations 中啟用 Systems Manager 服務主體，並設定 AWS Identity and Access Management (IAM) 許可以OpsItems跨帳戶使用 。

**Topics**
+ [開始之前](#OpsCenter-before-you-begin)
+ [步驟 1：建立資源資料同步](#OpsCenter-getting-started-multiple-accounts-onboarding-rds)
+ [步驟 2：在 中啟用 Systems Manager 服務主體 AWS Organizations](#OpsCenter-getting-started-multiple-accounts-onboarding-service-principal)
+ [步驟 3：建立 `AWSServiceRoleForAmazonSSM_AccountDiscovery` 服務連結角色](#OpsCenter-getting-started-multiple-accounts-onboarding-SLR)
+ [步驟 4：設定跨帳戶使用 OpsItems 的許可](#OpsCenter-getting-started-multiple-accounts-onboarding-resource-policy)
+ [步驟 5：設定跨帳戶使用相關資源的許可](#OpsCenter-getting-started-multiple-accounts-onboarding-related-resources-permissions)

**注意**  
跨帳戶使用 OpsCenter 時，僅支援 `/aws/issue` 類型的 OpsItems。

## 開始之前
<a name="OpsCenter-before-you-begin"></a>

在設定 OpsItems 來跨帳戶使用 OpsCenter 之前，請確定您已設定下列項目：
+ Systems Manager 委派管理員帳戶。如需詳細資訊，請參閱[設定 Explorer 的委派管理員](Explorer-setup-delegated-administrator.md)。
+ 在 Organizations 中設定了一個組織。如需詳細資訊，請參閱 *AWS Organizations 使用者指南*中的[建立和管理組織](https://docs.aws.amazon.com/organizations/latest/userguide/orgs_manage_org.html)。
+ 您已將 Systems Manager Automation 設定為跨多個 AWS 區域 和 AWS 帳戶執行自動化 Runbook。如需詳細資訊，請參閱[在多個 AWS 區域 和 帳戶中執行自動化](running-automations-multiple-accounts-regions.md)。

## 步驟 1：建立資源資料同步
<a name="OpsCenter-getting-started-multiple-accounts-onboarding-rds"></a>

在您設定 和 之後 AWS Organizations，您可以透過建立資源資料同步OpsCenter來彙總整個組織的 OpsItems 。如需詳細資訊，請參閱[刪除資源資料同步](Explorer-resource-data-sync-configuring-multi.md)。建立同步時，在**新增帳戶**區段中，請務必選擇**包含我 AWS Organizations 組態中的所有帳戶**選項。

## 步驟 2：在 中啟用 Systems Manager 服務主體 AWS Organizations
<a name="OpsCenter-getting-started-multiple-accounts-onboarding-service-principal"></a>

若要讓使用者跨OpsItems帳戶使用 ，必須在其中啟用 Systems Manager 服務主體 AWS Organizations。如果您先前使用其他工具來設定多帳戶案例的 Systems Manager，則 Systems Manager 服務主體可能已在 Organizations 中設定。在 AWS Command Line Interface (AWS CLI) 中執行以下命令以進行驗證。如果您*尚未*針對其他多帳戶案例設定 Systems Manager，則請跳至下一個程序：*啟用 AWS Organizations中的 Systems Manager 服務主體*。

**若要驗證已在 中啟用 Systems Manager 服務主體 AWS Organizations**

1. 將最新版本的 [下載](https://aws.amazon.com/cli/) AWS CLI 到您的本機電腦。

1. 開啟 AWS CLI，並執行下列命令來指定您的登入資料和 AWS 區域。

   ```
   aws configure
   ```

   系統會提示您指定下列項目。在下列範例中，將每個*使用者輸入預留位置*取代為您自己的資訊。

   ```
   AWS Access Key ID [None]: key_name
   AWS Secret Access Key [None]: key_name
   Default region name [None]: region
   Default output format [None]: ENTER
   ```

1. 執行以下命令，驗證已為 AWS Organizations啟用 Systems Manager 服務主體。

   ```
   aws organizations list-aws-service-access-for-organization
   ```

   此命令會傳回與以下範例中的內容相似的資訊。

   ```
   {
       "EnabledServicePrincipals": [
           {
               "ServicePrincipal": "member.org.stacksets.cloudformation.amazonaws.com",
               "DateEnabled": "2020-12-11T16:32:27.732000-08:00"
           },
           {
               "ServicePrincipal": "opsdatasync.ssm.amazonaws.com",
               "DateEnabled": "2022-01-19T12:30:48.352000-08:00"
           },
           {
               "ServicePrincipal": "ssm.amazonaws.com",
               "DateEnabled": "2020-12-11T16:32:26.599000-08:00"
           }
       ]
   }
   ```

**在 中啟用 Systems Manager 服務主體 AWS Organizations**

如果您先前沒有為 Organizations 設定 Systems Manager 服務主體，則請使用以下程序進行設定。如需有關此命令的詳細資訊，請參閱《AWS CLI 命令參考》**中的 [enable-aws-service-access](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/organizations/enable-aws-service-access.html)。

1. 如果您尚未安裝和設定 AWS Command Line Interface (AWS CLI)。如需詳細資訊，請參閱[安裝 CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html) 以及[設定 CLI](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)。

1. 將最新版本的 [下載](https://aws.amazon.com/cli/) AWS CLI 到您的本機電腦。

1. 開啟 AWS CLI，並執行下列命令來指定您的登入資料和 AWS 區域。

   ```
   aws configure
   ```

   系統會提示您指定下列項目。在下列範例中，將每個*使用者輸入預留位置*取代為您自己的資訊。

   ```
   AWS Access Key ID [None]: key_name
   AWS Secret Access Key [None]: key_name
   Default region name [None]: region
   Default output format [None]: ENTER
   ```

1. 執行以下命令，啟用 AWS Organizations的 Systems Manager 服務主體。

   ```
   aws organizations enable-aws-service-access --service-principal "ssm.amazonaws.com"
   ```

## 步驟 3：建立 `AWSServiceRoleForAmazonSSM_AccountDiscovery` 服務連結角色
<a name="OpsCenter-getting-started-multiple-accounts-onboarding-SLR"></a>

例如 `AWSServiceRoleForAmazonSSM_AccountDiscovery`角色的服務連結角色是直接連結至 的唯一 IAM 角色類型 AWS 服務，例如 Systems Manager。服務連結角色是由服務預先定義，並包含服務 AWS 服務 代表您呼叫其他 所需的所有許可。如需 `AWSServiceRoleForAmazonSSM_AccountDiscovery` 服務連結角色的詳細資訊，請參閱[適用於 Systems Manager 帳戶探索的服務連結角色許可](using-service-linked-roles-service-action-2.md#service-linked-role-permissions-service-action-2)。

透過使用 AWS CLI，使用以下程序來建立 `AWSServiceRoleForAmazonSSM_AccountDiscovery` 服務連結角色。如需有關此程序中所用命令的詳細資訊，請參閱《AWS CLI 命令參考》**中的 [create-service-linked-role](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/iam/create-service-linked-role.html)。

**建立 `AWSServiceRoleForAmazonSSM_AccountDiscovery` 服務連結角色**

1. 登入 AWS Organizations 管理帳戶。

1. 登入 Organizations 管理帳戶時，請執行以下命令。

   ```
   aws iam create-service-linked-role \
       --aws-service-name accountdiscovery.ssm.amazonaws.com \
       --description "Systems Manager account discovery for AWS Organizations service-linked role"
   ```

## 步驟 4：設定跨帳戶使用 OpsItems 的許可
<a name="OpsCenter-getting-started-multiple-accounts-onboarding-resource-policy"></a>

使用 AWS CloudFormation 堆疊集建立 `OpsItemGroup` 資源政策和 IAM 執行角色，提供使用者OpsItems跨帳戶使用 的許可。若要開始使用，請下載並解壓縮 [https://docs.aws.amazon.com/systems-manager/latest/userguide/samples/OpsCenterCrossAccountMembers.zip](https://docs.aws.amazon.com/systems-manager/latest/userguide/samples/OpsCenterCrossAccountMembers.zip) 檔案。此檔案包含 `OpsCenterCrossAccountMembers.yaml` CloudFormation 範本檔案。當您使用此範本建立堆疊集時，CloudFormation 會自動在帳戶中建立 `OpsItemCrossAccountResourcePolicy` 資源政策和 `OpsItemCrossAccountExecutionRole` 執行角色。如需有關建立堆疊集的詳細資訊，請參閱《AWS CloudFormation 使用者指南》**中的[建立堆疊集](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/stacksets-getting-started-create.html)。

**重要**  
記下有關此任務的以下重要資訊。  
您必須在登入 AWS Organizations 管理帳戶時部署堆疊集。
您必須在登入到您希望跨帳戶使用 OpsItems 的*每個**指定*帳戶時重複此過程，包括委派管理員帳戶。
如果您想要在不同的 中啟用跨帳戶OpsItems管理 AWS 區域，請在範本的指定區域區段中選擇**新增所有**區域。 ****選擇加入區域不支援跨帳戶 OpsItem 管理。

## 步驟 5：設定跨帳戶使用相關資源的許可
<a name="OpsCenter-getting-started-multiple-accounts-onboarding-related-resources-permissions"></a>

OpsItem 可包括受影響資源 (例如 Amazon Elastic Compute Cloud (Amazon EC2) 執行個體或 Amazon Simple Storage Service (Amazon S3) 儲存貯體) 的詳細資訊。您在之前步驟 4 中建立的 `OpsItemCrossAccountExecutionRole` 執行角色會為成員帳戶提供 OpsCenter 唯讀許可，以便檢視相關資源。您還必須建立 IAM 角色，以便為管理帳戶提供檢視相關資源並與之互動的許可，您將在此任務中完成。

若要開始使用，請下載並解壓縮 [https://docs.aws.amazon.com/systems-manager/latest/userguide/samples/OpsCenterCrossAccountManagementRole.zip](https://docs.aws.amazon.com/systems-manager/latest/userguide/samples/OpsCenterCrossAccountManagementRole.zip) 檔案。此檔案包含 `OpsCenterCrossAccountManagementRole.yaml` CloudFormation 範本檔案。當您使用此範本建立堆疊時，CloudFormation 會自動在帳戶中建立 `OpsCenterCrossAccountManagementRole` IAM 角色。如需建立堆疊的詳細資訊，請參閱*AWS CloudFormation 《 使用者指南*》中的[在 AWS CloudFormation 主控台上建立堆疊](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/cfn-console-create-stack.html)。

**重要**  
記下有關此任務的以下重要資訊。  
如果您打算將帳戶指定為 的委派管理員OpsCenter，請務必在建立堆疊 AWS 帳戶 時指定該帳戶。
您必須在登入 AWS Organizations 管理帳戶時執行此程序，並在登入委派管理員帳戶時再次執行此程序。

# (選用) 設定 Amazon SNS 以接收有關 OpsItems 的通知
<a name="OpsCenter-getting-started-sns"></a>

您可以設定 OpsCenter，以在系統建立 OpsItem 或更新現有 OpsItem 時，將通知傳送至 Amazon Simple Notification Service (Amazon SNS) 主題。

完成下列步驟以接收 OpsItems 的通知。
+ [步驟 1：建立並訂閱 Amazon SNS 主題](#OpsCenter-getting-started-sns-create-topic)
+ [步驟 2：更新 Amazon SNS 存取政策](#OpsCenter-getting-started-sns-encryption-policy)
+ [步驟 3：更新 AWS KMS 存取政策](#OpsCenter-getting-started-sns-KMS-policy)
**注意**  
如果您在步驟 2 中開啟 AWS Key Management Service (AWS KMS) 伺服器端加密，則必須完成步驟 3。否則，可以略過步驟 3。
+ [步驟 4：開啟預設 OpsItems 規則以傳送有關新 OpsItems 的通知](#OpsCenter-getting-started-sns-default-rules)

## 步驟 1：建立並訂閱 Amazon SNS 主題
<a name="OpsCenter-getting-started-sns-create-topic"></a>

若要接收通知，您必須建立並訂閱 Amazon SNS 主題。如需詳細資訊，請參閱《*Amazon Simple Notification Service 開發人員指南*》中的[建立 Amazon SNS 主題](https://docs.aws.amazon.com/sns/latest/dg/CreateTopic.html)和[訂閱 Amazon SNS 主題](https://docs.aws.amazon.com/sns/latest/dg/sns-tutorial-create-subscribe-endpoint-to-topic.html)。

**注意**  
如果您在OpsCenter多個 AWS 區域 或 帳戶中使用 ，則必須在您想要接收OpsItem通知*的每個*區域或帳戶中建立並訂閱 Amazon SNS 主題。

## 步驟 2：更新 Amazon SNS 存取政策
<a name="OpsCenter-getting-started-sns-encryption-policy"></a>

您必須將 Amazon SNS 主題與 OpsItems 相關聯。使用以下程序設定 Amazon SNS 存取政策，讓 Systems Manager 可以將 OpsItems 通知發佈至您在步驟 1 中建立的 Amazon SNS 主題。

1. 登入 AWS 管理主控台 並開啟位於 https：//[https://console.aws.amazon.com/sns/v3/home](https://console.aws.amazon.com/sns/v3/home) 的 Amazon SNS 主控台。

1. 在導覽窗格中，選擇**主題**。

1. 選擇在步驟 1 中建立的主題，然後選擇**編輯**。

1. 展開 **Access policy (存取政策)**。

1. 將以下 `Sid` 區塊新增至現有的政策。將每個*範例資源預留位置*取代為您自己的資訊。

   ```
   {
         "Sid": "Allow OpsCenter to publish to this topic",
         "Effect": "Allow",
         "Principal": {
           "Service": "ssm.amazonaws.com"
         },
         "Action": "SNS:Publish",
         "Resource": "arn:aws:sns:region:account ID:topic name", // Account ID of the SNS topic owner
         "Condition": {
         "StringEquals": {
           "AWS:SourceAccount": "account ID" //  Account ID of the OpsItem owner
         }
      }
   }
   ```
**注意**  
`aws:SourceAccount` 全域條件金鑰可防止混淆代理人情境。若要使用此條件金鑰，請將值設定為相應 OpsItem 擁有者的帳戶 ID。如需詳細資訊，請參閱《IAM 使用者指南》**中的[混淆代理](https://docs.aws.amazon.com//IAM/latest/UserGuide/confused-deputy.html)一節。

1. 選擇**儲存變更**。

現在，建立或更新 OpsItems 時，系統會傳送通知給 Amazon SNS 主題。

**重要**  
如果您在步驟 2 中使用 AWS Key Management Service (AWS KMS) 伺服器端加密金鑰設定 Amazon SNS 主題，請完成步驟 3。否則，可以略過步驟 3。

## 步驟 3：更新 AWS KMS 存取政策
<a name="OpsCenter-getting-started-sns-KMS-policy"></a>

如果您開啟 Amazon SNS 主題的 AWS KMS 伺服器端加密，您還必須更新 AWS KMS key 設定主題時所選 的存取政策。使用下列程序更新存取政策，讓 Systems Manager 可以將 OpsItem 通知發佈至您在步驟 1 中建立的 Amazon SNS 主題。

**注意**  
OpsCenter 不支援將 OpsItems 發佈至以 AWS 受管金鑰設定的 Amazon SNS 主題。

1. 在 https：//[https://console.aws.amazon.com/kms](https://console.aws.amazon.com/kms) 開啟 AWS KMS 主控台。

1. 若要變更 AWS 區域，請使用頁面右上角的區域選擇器。

1. 在導覽窗格中，選擇 **Customer managed keys** (客戶受管金鑰)。

1. 選擇您在建立主題時所選擇 KMS 金鑰的 ID。

1. 在 **Key policy (金鑰政策)** 區段中，選擇 **Switch to policy view (切換至政策檢視)**。

1. 選擇**編輯**。

1. 將以下 `Sid` 區塊新增至現有的政策。將每個*範例資源預留位置*取代為您自己的資訊。

   ```
   {
         "Sid": "Allow OpsItems to decrypt the key",
         "Effect": "Allow",
         "Principal": {
           "Service": "ssm.amazonaws.com"
         },
         "Action": ["kms:Decrypt", "kms:GenerateDataKey*"],
          "Resource": "arn:aws:kms:region:account ID:key/key ID"
       }
   ```

    在以下範例中，第 14 行輸入新區塊。  
![\[編輯 Amazon SNS 主題的 AWS KMS 存取政策。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_SNS_KMS_access_policy.png)

1. 選擇**儲存變更**。

## 步驟 4：開啟預設 OpsItems 規則以傳送有關新 OpsItems 的通知
<a name="OpsCenter-getting-started-sns-default-rules"></a>

Amazon EventBridge 中的預設 OpsItems 規則未設定 Amazon Resource Name (ARN) 來傳送 Amazon SNS 通知。使用下列程序在 EventBridge 中編輯規則並輸入 `notifications` 區塊。

**將通知區塊新增至預設 OpsItem 規則**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 **OpsItems** 索引標籤，然後選擇 **Configure sources (設定來源)**。

1. 選擇您要以 `notifications` 區塊設定的來源規則名稱，如下列範例所示。  
![\[選擇 Amazon EventBridge 規則來新增 Amazon SNS 通知區塊。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_SNS_Setup_2.png)

   規則在 Amazon EventBridge 中開啟。

1. 在規則詳細資訊頁面的 **Targets** (目標) 索引標籤上，選擇 **Edit** (編輯)。

1. 在 **Additional settings** (其他設定) 區段中，選擇 **Configure input transformer** (設定輸入轉換器)。

1. 在**範本**方塊中，以下列格式新增 `notifications` 區塊。

   ```
   "notifications":[{"arn":"arn:aws:sns:region:account ID:topic name"}],
   ```

   範例如下。

   ```
   "notifications":[{"arn":"arn:aws:sns:us-west-2:1234567890:MySNSTopic"}],
   ```

   輸入 `resources` 區塊前的通知區塊，如下列美國西部 (奧勒岡) (us-west-2) 區域範例所示。

   ```
   {
       "title": "EBS snapshot copy failed",
       "description": "CloudWatch Event Rule SSMOpsItems-EBS-snapshot-copy-failed was triggered. Your EBS snapshot copy has failed. See below for more details.",
       "category": "Availability",
       "severity": "2",
       "source": "EC2",
       "notifications": [{
           "arn": "arn:aws:sns:us-west-2:1234567890:MySNSTopic"
       }],
       "resources": <resources>,
       "operationalData": {
           "/aws/dedup": {
               "type": "SearchableString",
               "value": "{\"dedupString\":\"SSMOpsItems-EBS-snapshot-copy-failed\"}"
           },
           "/aws/automations": {
               "value": "[ { \"automationType\": \"AWS:SSM:Automation\", \"automationId\": \"AWS-CopySnapshot\" } ]"
           },
           "failure-cause": {
               "value": <failure - cause>
           },
           "source": {
               "value": <source>
           },
           "start-time": {
               "value": <start - time>
           },
           "end-time": {
               "value": <end - time>
           }
       }
   }
   ```

1. 選擇**確認**。

1. 選擇**下一步**。

1. 選擇**下一步**。

1. 選擇**更新規則**。

系統下次為預設規則建立 OpsItem 時，就會將通知發佈至 Amazon SNS 主題。

# OpsCenter 與其他 整合 AWS 服務
<a name="OpsCenter-applications-that-integrate"></a>

OpsCenter是 中的工具 AWS Systems Manager，可與多個 整合， AWS 服務 以診斷和修復 AWS 資源的問題。您必須先設定 ， AWS 服務 才能將其與 整合OpsCenter。

根據預設，下列項目 AWS 服務 會與 整合OpsCenter，並且可以OpsItems自動建立：
+ [Amazon CloudWatch](#OpsCenter-about-cloudwatch)
+ [Amazon CloudWatch Application Insights](#OpsCenter-about-cloudwatch-insights)
+ [Amazon EventBridge](#OpsCenter-about-eventbridge)
+ [AWS Config](#OpsCenter-about-AWS-config)
+ [AWS Systems Manager Incident Manager](#OpsCenter-about-incident-manager)

您必須將下列服務與 OpsCenter 整合，才能自動建立 OpsItems：
+ [Amazon DevOps Guru](#OpsCenter-integrate-with-devops-guru)
+ [AWS Security Hub CSPM](#OpsCenter-integrate-with-security-hub)

這些服務中的任何一項建立 OpsItem 後，您可以在 OpsCenter 中管理並修復 OpsItem。如需詳細資訊，請參閱[管理 OpsItems](OpsCenter-working-with-OpsItems.md)及[修正 OpsItem 問題](OpsCenter-remediating.md)。

如需每個 AWS 服務 及其如何與 整合的詳細資訊OpsCenter，請參閱下列主題。

**Topics**
+ [了解 OpsCenter 與 Amazon CloudWatch 的整合](#OpsCenter-about-cloudwatch)
+ [了解 OpsCenter 與 Amazon CloudWatch Application Insights 的整合](#OpsCenter-about-cloudwatch-insights)
+ [了解 OpsCenter 與 Amazon DevOps Guru 的整合](#OpsCenter-integrate-with-devops-guru)
+ [了解 OpsCenter 與 Amazon EventBridge 的整合](#OpsCenter-about-eventbridge)
+ [了解與 的OpsCenter整合 AWS Config](#OpsCenter-about-AWS-config)
+ [了解與 的OpsCenter整合 AWS Security Hub CSPM](#OpsCenter-integrate-with-security-hub)
+ [了解 OpsCenter 與 Incident Manager 的整合](#OpsCenter-about-incident-manager)

## 了解 OpsCenter 與 Amazon CloudWatch 的整合
<a name="OpsCenter-about-cloudwatch"></a>

Amazon CloudWatch 會監控您的 AWS 資源和服務，並在 AWS 服務 您使用的每個 上顯示指標。警示進入警示狀態時，CloudWatch 會建立 OpsItem。例如，如果 Application Load Balancer 產生的 HTTP 錯誤突然增加，則您可以設定警示來自動建立 OpsItem。

以下清單顯示了您可在 CloudWatch 中設定以建立 OpsItems 的一些警示：
+ Amazon DynamoDB：資料庫讀取和寫入動作達到閾值
+ Amazon EC2：CPU 使用率達到閾值
+ AWS 計費：預估費用達到閾值
+ Amazon EC2：執行個體未通過狀態檢查
+ Amazon Elastic Block Store (EBS)：磁碟空間使用率達到閾值

您可以建立警示，也可以編輯現有警示來建立 OpsItem。如需詳細資訊，請參閱[設定 CloudWatch 警示以建立 OpsItems](OpsCenter-create-OpsItems-from-CloudWatch-Alarms.md)。

使用整合式設定啟用 OpsCenter 後，它會將 CloudWatch 與 OpsCenter 整合。

## 了解 OpsCenter 與 Amazon CloudWatch Application Insights 的整合
<a name="OpsCenter-about-cloudwatch-insights"></a>

使用 Amazon CloudWatch Application Insights，您可以為您應用程式資源設定最佳監控器，以持續分析應用程式問題跡象資料。在 CloudWatch Application Insights 中設定應用程式資源時，可以選擇讓系統在 OpsCenter 中建立 OpsItems。針對應用程式偵測到的每個問題，會在 OpsCenter 主控台上建立一個 OpsItem。如需相關資訊，請參閱《Amazon CloudWatch 使用者指南》**中的[設定、配置和管理應用程式以進行監控](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/appinsights-setting-up.html)。

**注意**  
從 2023 年 10 月 16 日起，CloudWatch Application Insights 所建立之 OpsItems 的標題和描述現在會使用下述改良格式：

```
OpsItem title: [<APPLICATION NAME>: <RESOURCE ID>] <PROBLEM SUMMARY>

OpsItem description:       

CloudWatch Application Insights has detected a problem in application <APPLICATION NAME>.
Problem summary: <PROBLEM SUMMARY>
Problem ID: <PROBLEM ID> (hyperlinks to the Application Insights problem summary page)
Problem Status: <PROBLEM STATUS>
Insight: <INSIGHT>
```

請見此處範例：

![\[顯示從 CloudWatch Insights 建立的 OpsItem 之新格式的螢幕擷取畫面。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItem-CWinsight.png)


## 了解 OpsCenter 與 Amazon DevOps Guru 的整合
<a name="OpsCenter-integrate-with-devops-guru"></a>

Amazon DevOps Guru 採用機器學習來分析操作資料、應用程式指標和應用程式事件，以識別偏離正常操作模式的行為。如果啟用 DevOps Guru 以在 OpsCenter 中產生 OpsItem，則每個洞見都會產生一個新的 OpsItem。您可以使用 OpsCenter 來管理您的 OpsItems。

DevOps Guru 會自動建立 OpsItems。您可以啟用 Amazon DevOps Guru 來使用 Quick Setup (Systems Manager 中的工具) 建立 OpsItems。系統會使用 [AWSServiceRoleForDevOpsGuru](https://docs.aws.amazon.com/devops-guru/latest/userguide/using-service-linked-roles.html) AWS Identity and Access Management (IAM) 服務連結角色OpsItems來建立 。

**將 OpsCenter 與 DevOps Guru 整合**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **Quick Setup**。

1. 在**自訂 DevOps Guru 組態選項**頁面中，選擇**程式庫**索引標籤。

1. 在 **DevOps Guru** 窗格中，選擇**建立**。

1. 針對**組態選項**，選取**啟用 AWS Systems Manager OpsItems。**

1. 完成設定後，選取**建立**。

## 了解 OpsCenter 與 Amazon EventBridge 的整合
<a name="OpsCenter-about-eventbridge"></a>

Amazon EventBridge 提供描述 AWS 資源變更的事件串流。使用整合式設定啟用 OpsCenter 後，它會將 EventBridge 與 OpsCenter 整合，並啟用預設的 EventBridge 規則。EventBridge 會根據這些規則建立 OpsItems。您可以使用規則篩選事件並將事件路由至 OpsCenter，以進行調查和修復。

**注意**  
Amazon EventBridge (前稱為 Amazon CloudWatch Events) 不僅提供 CloudWatch Events 的所有功能，還提供一些新功能，例如自訂事件匯流排、第三方事件來源和結構描述登錄檔。

以下是一些您可以在 EventBridge 中設定以建立 OpsItem 的規則：
+ Security Hub CSPM：發出安全提醒
+ Amazon DynamoDB 限流事件
+ Amazon Elastic Compute Cloud Auto Scaling：無法啟動執行個體 
+ Systems Manager：無法執行自動化 
+ AWS Health：排定維護的提醒
+ Amazon EC2：執行個體狀態從「執行中」變更為「停止」 

您可以根據需求建立規則或編輯現有規則來建立 OpsItems。如需有關如何編輯規則以建立 OpsItem 的詳細資訊，請參閱[設定 EventBridge 規則以建立 OpsItems](OpsCenter-automatically-create-OpsItems-2.md)。

## 了解與 的OpsCenter整合 AWS Config
<a name="OpsCenter-about-AWS-config"></a>

AWS Config 提供 中 AWS 資源組態的詳細檢視 AWS 帳戶。

AWS Config 不會*直接*與 整合OpsCenter。反之，您可以建立將事件傳送至 Amazon EventBridge 的 AWS Config 規則，例如 AWS Config 偵測到不合規的執行個體時。然後，EventBridge 會根據您建立的 EventBridge 規則評估該事件。如果事件與規則相符，則 EventBridge 會將事件轉換為 OpsItem，並將其傳送至目的地目標 OpsCenter。

使用此 OpsItem，您可以追蹤不合規資源的詳細資訊、記錄調查動作，並提供對一致修復動作的存取權。

**相關資訊**

[設定 EventBridge 規則以建立 OpsItems](OpsCenter-automatically-create-OpsItems-2.md)

[使用 AWS Systems Manager OpsCenter 和 AWS Config 進行合規監控](https://aws.amazon.com/blogs/mt/using-aws-systems-manager-opscenter-and-aws-config-for-compliance-monitoring/)

## 了解與 的OpsCenter整合 AWS Security Hub CSPM
<a name="OpsCenter-integrate-with-security-hub"></a>

AWS Security Hub CSPM 從跨 AWS 帳戶 和 服務收集稱為*調查結果*的安全資料。使用一組規則來偵測和產生問題清單，Security Hub CSPM 可協助您識別、排定優先順序，並修復您所管理資源的安全問題。設定整合後，如本主題所述，Systems Manager 會在 中OpsItems為 Security Hub CSPM 調查結果建立 OpsCenter。

**注意**  
OpsCenter 具有與 Security Hub CSPM 的雙向整合。這表示如果您更新與安全調查結果OpsItem相關的 **的狀態**或**嚴重性**欄位，系統會將變更與 Security Hub CSPM 同步。同樣的，對調查結果所做的任何變更都會自動在 OpsCenter 中的對應 OpsItems 中得到更新。  
從 Security Hub CSPM 調查結果建立 OpsItem 時，Security Hub CSPM 中繼資料會自動新增至 的操作資料欄位OpsItem。如果刪除這些中繼資料，雙向更新將無法再運作。

根據預設，Systems Manager 可為「關鍵」和「高」安全性調查結果建立 OpsItems。您可以手動設定 OpsCenter 為中低嚴重性調查結果建立 OpsItems。OpsCenter 不會為資訊性調查結果建立 OpsItems，因為此類調查結果不要求採取修補措施。如需 Security Hub CSPM 嚴重性等級的詳細資訊，請參閱 *AWS Security Hub API 參考*中的[嚴重性](https://docs.aws.amazon.com//securityhub/1.0/APIReference/API_Severity.html)。

**開始之前**  
OpsCenter 設定 OpsItems 根據 Security Hub CSPM 調查結果建立 之前，請確認您已完成 Security Hub CSPM 設定任務。如需詳細資訊，請參閱*AWS Security Hub 《 使用者指南*》中的[設定 Security Hub CSPM](https://docs.aws.amazon.com/securityhub/latest/userguide/securityhub-settingup.html)。

當您將 Security Hub CSPM 與 整合時OpsCenter，系統會使用 IAM `AWSServiceRoleForSystemsManagerOpsDataSync` 服務連結角色OpsItems建立 。如需有關此角色的詳細資訊，請參閱 [使用角色為 OpsItems 建立 OpsData 和 Explorer：](using-service-linked-roles-service-action-3.md)。

**警告**  
請注意下列有關與 Security Hub CSPM OpsCenter整合定價的重要資訊：  
如果您在設定 OpsCenter和 Security Hub CSPM 整合時登入 Security Hub CSPM 管理員帳戶，系統會OpsItems為管理員*和*所有成員帳戶中的問題清單建立 。所有 OpsItems 都會*在管理員帳戶中*建立。根據各種因素，這可能會導致來自 的意外大額帳單 AWS。  
如果您在設定整合時使用成員帳戶登入，則系統只會針對該個別帳戶中的調查結果建立 OpsItems。如需 Security Hub CSPM 管理員帳戶、成員帳戶及其與 EventBridge 事件摘要之關聯的詳細資訊，請參閱*AWS Security Hub 《 使用者指南*》中的 [Security Hub CSPM 與 EventBridge 整合的類型](https://docs.aws.amazon.com/securityhub/latest/userguide/securityhub-cwe-integration-types.html)。
針對每個建立 OpsItem 的調查結果，系統會按照標準價格向您收取建立 OpsItem 的費用。如果您編輯 OpsItem或在 Security Hub CSPM 中更新對應的調查結果 （這會觸發OpsItem更新），也會向您收取費用。
 OpsItems 與 整合所建立的 目前 AWS Security Hub CSPM *不受*區域中OpsItems每個帳戶 500，000 個配額上限的限制。因此，Security Hub CSPM 提醒可以在帳戶中OpsItems的每個區域中建立超過 500，000 個收費項目。  
因此，對於高生產環境，我們建議將 Security Hub CSPM 問題清單的範圍限制為僅高嚴重性的問題。

**設定 OpsCenter為 Security Hub OpsItems CSPM 調查結果建立**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇**設定**。

1. 在 **Security Hub CSPM 調查結果**區段中，選擇**編輯。**

1. 選擇滑桿以將**已停用**變更為**已啟用**。

1. 如果您希望系統針對中度或低嚴重性調查結果建立 OpsItems，請切換這些選項。

1. 選擇 **Save (儲存)** 以儲存您的組態。

如果您不再希望系統OpsItems為 Security Hub CSPM 調查結果建立 ，請使用下列程序。

**停止接收 Security Hub OpsItems CSPM 問題清單**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇**設定**。

1. 在 **Security Hub CSPM 調查結果**區段中，選擇**編輯。**

1. 選擇滑桿以將**已啟用**變更為**已停用**。如果您無法切換滑桿，表示尚未為您的 啟用 Security Hub CSPM AWS 帳戶。

1. 選擇**儲存**以儲存您的組態。 OpsCenter 不再OpsItems根據 Security Hub CSPM 調查結果建立 。

**重要**  
Systems Manager 委派管理員或 AWS Organizations 管理帳戶可以在 中OpsCenter為多個帳戶啟用 Security Hub CSPM 調查結果， AWS 區域 並在 中建立資源資料同步Explorer。如果在 中啟用 **Security Hub CSPM** 來源，Explorer且存在以停用 Security Hub CSPM 整合的成員帳戶為目標的資源資料同步，則管理員選取的設定優先。 會OpsCenter繼續OpsItems為 Security Hub CSPM 調查結果建立 。若要停止在以資源資料同步為目標的成員帳戶中OpsItems建立 Security Hub CSPM 調查結果，請聯絡您的管理員，並要求他們從資源資料同步中移除您的帳戶，或在 中關閉 **Security Hub CSPM** 來源Explorer。如需有關變更 Explorer 中設定的詳細資訊，請參閱[編輯 Systems Manager Explorer 資料來源](Explorer-using-editing-data-sources.md)。

## 了解 OpsCenter 與 Incident Manager 的整合
<a name="OpsCenter-about-incident-manager"></a>

Incident Manager 是 中的工具 AWS Systems Manager，提供事件管理主控台，協助您減輕並復原影響 AWS 託管應用程式的事件。*事件*是指任何意外中斷或服務質量下降。設定和配置 [Incident Manager](https://docs.aws.amazon.com/incident-manager/latest/userguide/what-is-incident-manager.html) 後，系統會自動在 OpsCenter 中建立 OpsItems。

系統在 Incident Manager 中建立事件時，它也會在 OpsCenter 中建立 OpsItem，並將事件顯示為相關項目。如果 OpsItem 已存在，則 Incident Manager 不會建立 OpsItem。第一個 OpsItem 稱為父系 OpsItem。如果事件的規模和範圍成長，則您可以新增事件至現有 OpsItem。如有必要，您可以為 OpsItem 手動建立事件。事件關閉後，您可以在 Incident Manager 中建立分析，以檢閱並改進類似問題的修復程序。

依預設，OpsCenter 會與 Incident Manager 整合。如果未設定 Incident Manager，OpsCenter 頁面會顯示設定 Incident Manager 的訊息。Incident Manager 建立 OpsItem 後，您可以在 OpsCenter 中管理並修復 OpsItem。如需有關為 OpsItem 建立事件的指示，請參閱[為 OpsItem 建立事件](OpsCenter-working-with-OpsItems-create-an-incident.md)。

# 建立 OpsItems
<a name="OpsCenter-create-OpsItems"></a>

設定 OpsCenter (AWS Systems Manager 中的工具) 並將其與您的 AWS 服務整合之後，您的 AWS 服務會根據預設規則、事件或警示自動建立 OpsItems。

您可以檢視預設 Amazon EventBridge 規則的狀態和嚴重性等級。如果需要，您可以在 Amazon EventBridge 中建立或編輯這些規則。您也可以在 Amazon CloudWatch 中檢視警示，並建立或編輯警示。您可以使用規則和警示來設定事件，以便為事件自動產生 OpsItems。

系統建立 OpsItem 後，它會處於**待處理**狀態。開始調查 OpsItem 後，您可以將狀態變更為**進行中**，在修復 OpsItem 之後可以將狀態變更為**已解決**。如需有關如何在 AWS 服務 中設定警示和規則以建立 OpsItems 和如何手動建立 OpsItems 的詳細資訊，請參閱下列主題。

**Topics**
+ [設定 EventBridge 規則以建立 OpsItems](OpsCenter-automatically-create-OpsItems-2.md)
+ [設定 CloudWatch 警示以建立 OpsItems](OpsCenter-create-OpsItems-from-CloudWatch-Alarms.md)
+ [手動建立 OpsItems](OpsCenter-manually-create-OpsItems.md)

# 設定 EventBridge 規則以建立 OpsItems
<a name="OpsCenter-automatically-create-OpsItems-2"></a>

Amazon EventBridge 收到事件後，它會根據預設規則建立新的 OpsItem。您可以建立規則或編輯現有的規則，以將 OpsCenter 設定為 EventBridge 事件的目標。如需有關如何建立事件規則的詳細資訊，請參閱《Amazon EventBridge 使用者指南》**中的[為 AWS 服務建立規則](https://docs.aws.amazon.com/eventbridge/latest/userguide/create-eventbridge-rule.html)。

**設定 EventBridge 規則以在 OpsCenter 中建立 OpsItems**

1. 前往 [https://console.aws.amazon.com/events/](https://console.aws.amazon.com/events/) 開啟 Amazon EventBridge 主控台。

1. 在導覽窗格中，選擇**規則**。

1. 在 **Rules** (規則) 頁面，針對 **Event bus** (事件匯流排)，選擇 **default** (預設值)。

1. 在**規則**中，選取名稱旁的核取方塊，以選擇規則。

1. 選取規則的名稱，開啟其詳細資訊頁面。在**規則詳細資訊**中，確認**狀態**已設定為**已啟用**。
**注意**  
如有必要，您可以使用頁面右上角的**編輯**來更新狀態。

1. 選擇 **Targets (目標)** 標籤。

1. 在 **Targets (目標)** 索引標籤上，選擇 **Edit (編輯)**。

1. 對於**目標類型**，請選取 **AWS 服務**。

1. 針對 **Select a target** (選取目標)，請選擇 **Systems Manager OpsItem**。

1. 對於許多目標類型，EventBridge 需要許可才能將事件傳送到目標。在這些情況下，EventBridge 可以建立執行規則所需的 AWS Identity and Access Management (IAM) 角色：
   + 若要自動建立 IAM 角色，請選擇**為此特定資源建立新角色**。
   + 若要使用您建立的 IAM 角色授予 EventBridge 許可，以在 OpsCenter 中建立 OpsItems，請選擇 **Use existing role** (使用現有的角色)。

1. 在**其他設定**的**設定目標輸入**中，選擇**輸入轉換器**。

   您可以使用**輸入轉換器**選項，指定重複資料刪除字串和 OpsItems 的其他重要資訊，例如標題和嚴重性。

1. 選擇**設定輸入轉換器**。

1. 在**目標輸入轉換器**的**輸入路徑**中，指定針對觸發事件要剖析的值。例如，若要透過觸發規則的事件來剖析開始時間、結束時間和其他詳細資訊，請使用下列 JSON。

   ```
   {
       "end-time": "$.detail.EndTime",
       "failure-cause": "$.detail.cause",
       "resources": "$.resources[0]",
       "source": "$.detail.source",
       "start-time": "$.detail.StartTime"
   }
   ```

1. 針對 **Template** (範本)，指定要傳送至目標的資訊。例如，使用下列 JSON 將資訊傳遞至 OpsCenter。該資訊用於建立 OpsItem。
**注意**  
如果輸入範本為 JSON 格式，則範本中的物件值不能包含引號。例如，資源、失敗原因、來源、開始時間和結束時間的值不能加引號。

   ```
   {
       "title": "EBS snapshot copy failed",
       "description": "CloudWatch Event Rule SSMOpsItems-EBS-snapshot-copy-failed was triggered. Your EBS snapshot copy has failed. See below for more details.",
       "category": "Availability",
       "severity": "2",
       "source": "EC2",
       "operationalData": {
           "/aws/dedup": {
               "type": "SearchableString",
               "value": "{\"dedupString\":\"SSMOpsItems-EBS-snapshot-copy-failed\"}"
           },
           "/aws/automations": {
               "value": "[ { \"automationType\": \"AWS:SSM:Automation\", \"automationId\": \"AWS-CopySnapshot\" } ]"
           },
           "failure-cause": {
               "value": <failure-cause>
           },
           "source": {
               "value": <source>
           },
           "start-time": {
               "value": <start-time>
           },
           "end-time": {
               "value": <end-time>
           },
            },
           "resources": {
               "value": <resources>
           }
       }
   }
   ```

   如需這些欄位的詳細資訊，請參閱《*Amazon EventBridge 使用者指南*》中的[轉換目標輸入](https://docs.aws.amazon.com/eventbridge/latest/userguide/transform-input.html)。

1. 選擇**確認**。

1. 選擇**下一步**。

1. 選擇**下一步**。

1. 選擇**更新規則**。

從事件建立 OpsItem 之後，您就可以開啟 OpsItem 並向下捲動至 **Private operational data (私有營運資料)** 區段，檢視事件詳細資訊。如需如何在 OpsItem 中設定選項的資訊，請參閱 [管理 OpsItems](OpsCenter-working-with-OpsItems.md)。

# 設定 CloudWatch 警示以建立 OpsItems
<a name="OpsCenter-create-OpsItems-from-CloudWatch-Alarms"></a>

在 中OpsCenter工具 的整合設定期間 AWS Systems Manager，您可以讓 Amazon CloudWatch OpsItems 根據常見警示自動建立 。您可以建立警示，也可以編輯現有警示來在 OpsCenter 中建立 OpsItems。

當您設定警示以建立 時，CloudWatch 會在 AWS Identity and Access Management (IAM) 中建立新的服務連結角色OpsItems。新角色已命名為 `AWSServiceRoleForCloudWatchAlarms_ActionSSM`。如需有關 CloudWatch 服務連結角色的詳細資訊，請參閱《Amazon CloudWatch 使用者指南》**中的[使用 CloudWatch 的服務連結角色](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/using-service-linked-roles.html)。

CloudWatch 警示產生 OpsItem 後，OpsItem 會顯示 **CloudWatch 警示 - '*alarm\$1name*' 處於 ALARM 狀態**。

若要檢視特定 OpsItem 的詳細資訊，選擇 OpsItem，然後選擇**相關資源詳細資訊**索引標籤。您可以手動編輯 OpsItems 來變更詳細資訊，例如嚴重性或類別。不過，當您編輯警示的嚴重性或類別時，Systems Manager 無法更新已從警示建立之 OpsItems 的嚴重性或類別。如果警報建立了 OpsItem 而且如果您指定了重複資料刪除字串，則警示不會建立額外的 OpsItems，即使您在 CloudWatch 中編輯警示也是如此。如果 OpsItem 已在 OpsCenter 中解決，CloudWatch 將建立新的 OpsItem。

如需有關設定 CloudWatch 警示的詳細資訊，請參閱下列主題。

**Topics**
+ [設定 CloudWatch 警示以建立 OpsItems (主控台)](OpsCenter-creating-or-editing-existing-alarm-console.md)
+ [設定現有的 CloudWatch 警示以建立 OpsItems (以程式設計方式)](OpsCenter-configuring-an-existing-alarm-programmatically.md)

# 設定 CloudWatch 警示以建立 OpsItems (主控台)
<a name="OpsCenter-creating-or-editing-existing-alarm-console"></a>

您可以手動建立警示或更新現有警示，以便在 Amazon CloudWatch 中建立 OpsItems。

**建立 CloudWatch 警示並將 Systems Manager 設定為該警示的目標**

1. 完成《Amazon CloudWatch 使用者指南》**內[根據靜態閾值建立 CloudWatch 警示](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/ConsoleAlarms.html)中指定的步驟 1–9。

1. 在 **Systems Manager 動作**區段中，選擇**新增 Systems Manager OpsCenter 動作**。

1. 選擇 **OpsItems**。

1. 在**嚴重性**中，選擇 1 到 4。

1. (選用) 在**類別**中，選擇 OpsItem 的類別。

1. 完成《Amazon CloudWatch 使用者指南》**內[根據靜態閾值建立 CloudWatch 警示](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/ConsoleAlarms.html)中指定的步驟 11–13。

1. 選擇 **Next** (下一步) 並完成精靈。

**編輯現有的警示，並將 Systems Manager 設定為該警示的目標**

1. 透過 [https://console.aws.amazon.com/cloudwatch/](https://console.aws.amazon.com/cloudwatch/) 開啟 CloudWatch 主控台。

1. 在導覽窗格中，選擇 **Alarms** (警示)。

1. 選取警示，然後選擇 **Actions** (動作)、**Edit** (編輯)。

1. (選用) 變更 **Metrics** (指標) 和 **Conditions** (條件) 選項中的設定，然後選擇 **Next** (下一步)。

1. 在 **Systems Manager** (Systems Manager) 區段中，選擇 **Add Systems Manager OpsCenter action** (新增 Systems Manager OpsCenter 動作)。

1. 對於 **Severity** (嚴重性)，選擇數字。
**注意**  
嚴重性是使用者定義的值。您或您的組織會決定每個嚴重性值的含義，以及與每個嚴重性相關的任何服務水準協議。

1. (選用) 對於 **Category** (類別)，選擇一個選項。

1. 選擇 **Next** (下一步) 並完成精靈。

# 設定現有的 CloudWatch 警示以建立 OpsItems (以程式設計方式)
<a name="OpsCenter-configuring-an-existing-alarm-programmatically"></a>

您可以使用 AWS Command Line Interface (AWS CLI)、 AWS CloudFormation 範本或Java程式碼片段，設定 Amazon CloudWatch 警示以OpsItems程式設計方式建立 。

**Topics**
+ [開始之前](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-before-you-begin)
+ [設定 CloudWatch 警示以建立 OpsItems (AWS CLI)](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-manually-configure-cli)
+ [設定 CloudWatch 警示以建立或更新 OpsItems (CloudFormation)](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-programmatically-configure-CloudFormation)
+ [設定 CloudWatch 警示以建立或更新 OpsItems (Java)](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-programmatically-configure-java)

## 開始之前
<a name="OpsCenter-create-OpsItems-from-CloudWatch-Alarms-before-you-begin"></a>

如果以程式設計方式編輯現有的警示，或建立警示 (該警示會建立 OpsItems)，則您必須指定 Amazon Resource Name (ARN)。此 ARN 可識別 Systems Manager OpsCenter 作為從警示建立之 OpsItems 的目標。您可以自訂 ARN，以便從警示建立之 OpsItems 包含特定資訊，例如嚴重性或類別。每個 ARN 包含下表中所述的資訊。


****  

| 參數 | 詳細資訊 | 
| --- | --- | 
|  `Region` (必要)  |   AWS 區域 警示所在的 。例如：`us-west-2`。如需您可在其中使用 OpsCenter 之 AWS 區域 相關資訊，請參閱 [AWS Systems Manager 端點和配額](https://docs.aws.amazon.com/general/latest/gr/ssm.html)。  | 
|  `account_ID` (必要)  |  用來建立警示的相同 AWS 帳戶 ID。例如：`123456789012`。帳戶 ID 後面必須加上冒號 (`:`) 和參數 `opsitem`，如下列範例所示。  | 
|  `severity` (必要)  |  從警示建立之 OpsItems 的使用者定義嚴重性層級。有效值：`1`、`2`、`3`、`4`  | 
|  `Category` (選用)  |  從警示建立之 OpsItems 的類別 有效值：`Availability`、`Cost`、`Performance`、`Recovery` 和 `Security`。  | 

使用下列語法建立 ARN。此 ARN 不包含選用的 `Category` 參數。

```
arn:aws:ssm:Region:account_ID:opsitem:severity
```

以下是範例。

```
arn:aws:ssm:us-west-2:123456789012:opsitem:3
```

若要建立使用選用 `Category` 參數的 ARN，請使用下列語法。

```
arn:aws:ssm:Region:account_ID:opsitem:severity#CATEGORY=category_name
```

以下是範例。

```
arn:aws:ssm:us-west-2:123456789012:opsitem:3#CATEGORY=Security
```

## 設定 CloudWatch 警示以建立 OpsItems (AWS CLI)
<a name="OpsCenter-create-OpsItems-from-CloudWatch-Alarms-manually-configure-cli"></a>

此命令要求您為 `alarm-actions` 參數指定 ARN。如需如何建立 ARN 的相關資訊，請參閱 [開始之前](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-before-you-begin)。

**設定 CloudWatch 警示以建立 OpsItems (AWS CLI)**

1. 如果您尚未安裝並設定 AWS Command Line Interface (AWS CLI)，請安裝並設定 。

   如需相關資訊，請參閱[安裝或更新最新版本的 AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)。

1. 執行下列命令以收集您要設定之警示的相關資訊。

   ```
   aws cloudwatch describe-alarms --alarm-names "alarm name"
   ```

1. 執行下列命令以更新警示。將每個*範例資源預留位置*取代為您自己的資訊。

   ```
   aws cloudwatch put-metric-alarm --alarm-name name \
   --alarm-description "description" \
   --metric-name name --namespace namespace \
   --statistic statistic --period value --threshold value \
   --comparison-operator value \
   --dimensions "dimensions" --evaluation-periods value \
       --alarm-actions arn:aws:ssm:Region:account_ID:opsitem:severity#CATEGORY=category_name \
   --unit unit
   ```

   範例如下。

------
#### [ Linux & macOS ]

   ```
   aws cloudwatch put-metric-alarm --alarm-name cpu-mon \
   --alarm-description "Alarm when CPU exceeds 70 percent" \
   --metric-name CPUUtilization --namespace AWS/EC2 \
   --statistic Average --period 300 --threshold 70 \
   --comparison-operator GreaterThanThreshold \
   --dimensions "Name=InstanceId,Value=i-12345678" --evaluation-periods 2 \
   --alarm-actions arn:aws:ssm:us-east-1:123456789012:opsitem:3#CATEGORY=Security \
   --unit Percent
   ```

------
#### [ Windows ]

   ```
   aws cloudwatch put-metric-alarm --alarm-name cpu-mon ^
   --alarm-description "Alarm when CPU exceeds 70 percent" ^
   --metric-name CPUUtilization --namespace AWS/EC2 ^
   --statistic Average --period 300 --threshold 70 ^
   --comparison-operator GreaterThanThreshold ^
   --dimensions "Name=InstanceId,Value=i-12345678" --evaluation-periods 2 ^
   --alarm-actions arn:aws:ssm:us-east-1:123456789012:opsitem:3#CATEGORY=Security ^
   --unit Percent
   ```

------

## 設定 CloudWatch 警示以建立或更新 OpsItems (CloudFormation)
<a name="OpsCenter-create-OpsItems-from-CloudWatch-Alarms-programmatically-configure-CloudFormation"></a>

本節包含可用來設定 CloudWatch 警示以自動建立或更新 的 AWS CloudFormation 範本OpsItems。每個範本都要求您為 `AlarmActions` 參數指定 ARN。如需如何建立 ARN 的相關資訊，請參閱 [開始之前](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-before-you-begin)。

**指標警示** – 使用下列 CloudFormation 範本來建立或更新 CloudWatch 指標警示。此範本中指定的警示會監控 Amazon Elastic Compute Cloud (Amazon EC2) 執行個體狀態檢查。如果警示進入 `ALARM` 狀態，它會在 OpsCenter 中建立 OpsItem。

```
    {
      "AWSTemplateFormatVersion": "2010-09-09",
      "Parameters" : {
        "RecoveryInstance" : {
          "Description" : "The EC2 instance ID to associate this alarm with.",
          "Type" : "AWS::EC2::Instance::Id"
        }
      },
      "Resources": {
        "RecoveryTestAlarm": {
          "Type": "AWS::CloudWatch::Alarm",
          "Properties": {
            "AlarmDescription": "Run a recovery action when instance status check fails for 15 consecutive minutes.",
            "Namespace": "AWS/EC2" ,
            "MetricName": "StatusCheckFailed_System",
            "Statistic": "Minimum",
            "Period": "60",
            "EvaluationPeriods": "15",
            "ComparisonOperator": "GreaterThanThreshold",
            "Threshold": "0",
            "AlarmActions": [ {"Fn::Join" : ["", ["arn:arn:aws:ssm:Region:account_ID:opsitem:severity#CATEGORY=category_name", { "Ref" : "AWS::Partition" }, ":ssm:", { "Ref" : "AWS::Region" }, { "Ref" : "AWS:: AccountId" }, ":opsitem:3" ]]} ],
            "Dimensions": [{"Name": "InstanceId","Value": {"Ref": "RecoveryInstance"}}]
          }
        }
      }
    }
```

**複合警示** – 使用下列 CloudFormation 範本來建立或更新複合警示。複合警示由多個指標警示組成。如果警示進入 `ALARM` 狀態，它會在 OpsCenter 中建立 OpsItem。

```
"Resources":{
       "HighResourceUsage":{
          "Type":"AWS::CloudWatch::CompositeAlarm",
          "Properties":{
             "AlarmName":"HighResourceUsage",
             "AlarmRule":"(ALARM(HighCPUUsage) OR ALARM(HighMemoryUsage)) AND NOT ALARM(DeploymentInProgress)",
             "AlarmActions":"arn:aws:ssm:Region:account_ID:opsitem:severity#CATEGORY=category_name",
             "AlarmDescription":"Indicates that the system resource usage is high while no known deployment is in progress"
          },
          "DependsOn":[
             "DeploymentInProgress",
             "HighCPUUsage",
             "HighMemoryUsage"
          ]
       },
       "DeploymentInProgress":{
          "Type":"AWS::CloudWatch::CompositeAlarm",
          "Properties":{
             "AlarmName":"DeploymentInProgress",
             "AlarmRule":"FALSE",
             "AlarmDescription":"Manually updated to TRUE/FALSE to disable other alarms"
          }
       },
       "HighCPUUsage":{
          "Type":"AWS::CloudWatch::Alarm",
          "Properties":{
             "AlarmDescription":"CPUusageishigh",
             "AlarmName":"HighCPUUsage",
             "ComparisonOperator":"GreaterThanThreshold",
             "EvaluationPeriods":1,
             "MetricName":"CPUUsage",
             "Namespace":"CustomNamespace",
             "Period":60,
             "Statistic":"Average",
             "Threshold":70,
             "TreatMissingData":"notBreaching"
          }
       },
       "HighMemoryUsage":{
          "Type":"AWS::CloudWatch::Alarm",
          "Properties":{
             "AlarmDescription":"Memoryusageishigh",
             "AlarmName":"HighMemoryUsage",
             "ComparisonOperator":"GreaterThanThreshold",
             "EvaluationPeriods":1,
             "MetricName":"MemoryUsage",
             "Namespace":"CustomNamespace",
             "Period":60,
             "Statistic":"Average",
             "Threshold":65,
             "TreatMissingData":"breaching"
          }
       }
    }
```

## 設定 CloudWatch 警示以建立或更新 OpsItems (Java)
<a name="OpsCenter-create-OpsItems-from-CloudWatch-Alarms-programmatically-configure-java"></a>

本節包含 Java 程式碼片段，您可以用這些程式碼片段來設定 CloudWatch 警示以自動建立或更新 OpsItems。每個程式碼片段都要求您為 `validSsmActionStr` 參數指定 ARN。如需如何建立 ARN 的相關資訊，請參閱 [開始之前](#OpsCenter-create-OpsItems-from-CloudWatch-Alarms-before-you-begin)。

**特定警示** – 使用以下 Java 程式碼片段來建立或更新 CloudWatch 警示。此範本中指定的警示會監控 Amazon EC2 執行個體狀態檢查。如果警示進入 `ALARM` 狀態，它會在 OpsCenter 中建立 OpsItem。

```
import com.amazonaws.services.cloudwatch.AmazonCloudWatch;
    import com.amazonaws.services.cloudwatch.AmazonCloudWatchClientBuilder;
    import com.amazonaws.services.cloudwatch.model.ComparisonOperator;
    import com.amazonaws.services.cloudwatch.model.Dimension;
    import com.amazonaws.services.cloudwatch.model.PutMetricAlarmRequest;
    import com.amazonaws.services.cloudwatch.model.PutMetricAlarmResult;
    import com.amazonaws.services.cloudwatch.model.StandardUnit;
    import com.amazonaws.services.cloudwatch.model.Statistic;
     
    private void putMetricAlarmWithSsmAction() {
        final AmazonCloudWatch cw =
                AmazonCloudWatchClientBuilder.defaultClient();
     
        Dimension dimension = new Dimension()
                .withName("InstanceId")
                .withValue(instanceId);
     
        String validSsmActionStr = "arn:aws:ssm:Region:account_ID:opsitem:severity#CATEGORY=category_name";
     
        PutMetricAlarmRequest request = new PutMetricAlarmRequest()
                .withAlarmName(alarmName)
                .withComparisonOperator(
                        ComparisonOperator.GreaterThanThreshold)
                .withEvaluationPeriods(1)
                .withMetricName("CPUUtilization")
                .withNamespace("AWS/EC2")
                .withPeriod(60)
                .withStatistic(Statistic.Average)
                .withThreshold(70.0)
                .withActionsEnabled(false)
                .withAlarmDescription(
                        "Alarm when server CPU utilization exceeds 70%")
                .withUnit(StandardUnit.Seconds)
                .withDimensions(dimension)
                .withAlarmActions(validSsmActionStr);
     
        PutMetricAlarmResult response = cw.putMetricAlarm(request);
    }
```

**更新所有警示** – 使用以下 Java 程式碼片段來更新 AWS 帳戶 中的所有 CloudWatch 警示，以在警示進入 `ALARM` 狀態時建立 OpsItems。

```
import com.amazonaws.services.cloudwatch.AmazonCloudWatch;
    import com.amazonaws.services.cloudwatch.AmazonCloudWatchClientBuilder;
    import com.amazonaws.services.cloudwatch.model.DescribeAlarmsRequest;
    import com.amazonaws.services.cloudwatch.model.DescribeAlarmsResult;
    import com.amazonaws.services.cloudwatch.model.MetricAlarm;
     
    private void listMetricAlarmsAndAddSsmAction() {
        final AmazonCloudWatch cw = AmazonCloudWatchClientBuilder.defaultClient();
     
        boolean done = false;
        DescribeAlarmsRequest request = new DescribeAlarmsRequest();
     
        String validSsmActionStr = "arn:aws:ssm:Region:account_ID:opsitem:severity#CATEGORY=category_name";
     
        while(!done) {
     
            DescribeAlarmsResult response = cw.describeAlarms(request);
     
            for(MetricAlarm alarm : response.getMetricAlarms()) {
                // assuming there are no alarm actions added for the metric alarm
                alarm.setAlarmActions(ImmutableList.of(validSsmActionStr));
            }
     
            request.setNextToken(response.getNextToken());
     
            if(response.getNextToken() == null) {
                done = true;
            }
        }
    }
```

# 手動建立 OpsItems
<a name="OpsCenter-manually-create-OpsItems"></a>

發現操作問題後，您可以在 OpsCenter (AWS Systems Manager 中的工具) 中手動建立 OpsItem，以管理並解決問題。

如果為 OpsCenter 設定了跨帳戶管理，Systems Manager 委派管理員或 AWS Organizations 管理帳戶可以為成員帳戶建立 OpsItems。如需更多詳細資訊，請參閱 [(選用) 手動設定 OpsCenter 以跨帳戶集中管理 OpsItems](OpsCenter-getting-started-multiple-accounts.md)。

您可以使用 AWS Systems Manager 主控台、AWS Command Line Interface (AWS CLI) 或 AWS Tools for Windows PowerShell 來建立 OpsItems。

**Topics**
+ [手動建立 OpsItems (主控台)](OpsCenter-creating-OpsItems-console.md)
+ [手動建立 OpsItems (AWS CLI)](OpsCenter-creating-OpsItems-CLI.md)
+ [手動建立 OpsItems (PowerShell)](OpsCenter-creating-OpsItems-Powershell.md)

# 手動建立 OpsItems (主控台)
<a name="OpsCenter-creating-OpsItems-console"></a>

 您可以使用 OpsItems AWS Systems Manager 主控台手動建立 。建立 OpsItem 後，它會顯示在您的 OpsCenter 帳戶中。如果為 OpsCenter 設定了跨帳戶管理，則 OpsCenter 會向委派管理員或管理帳戶提供為選定成員帳戶建立 OpsItems 的選項。如需詳細資訊，請參閱[(選用) 手動設定 OpsCenter 以跨帳戶集中管理 OpsItems](OpsCenter-getting-started-multiple-accounts.md)。

**OpsItem 使用 AWS Systems Manager 主控台建立**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 **Create OpsItem** (建立 OpsItem)。如果您沒有看到此按鈕，請選擇 **OpsItems** 索引標籤，然後選擇 **Create OpsItem** (建立 OpsItem)。

1.  (選用) 選擇**其他帳戶**，然後選擇您要建立 OpsItem 的帳戶。
**注意**  
如果您要為會員帳戶建立 OpsItems，則需要執行此步驟。

1. 針對 **Title (標題)**，輸入描述名稱，協助您了解 OpsItem 的用途。

1. 對於 **Source** (來源)，輸入受影響的 AWS 資源類型或其他來源資訊，協助使用者了解 OpsItem 的根源。
**注意**  
建立 OpsItem 後，您不能編輯 **Source** (來源) 欄位。

1. (選用) 對於 **Priority** (優先順序)，選擇優先順序層級。

1. (選用) 對於 **Severity** (嚴重性)，選擇嚴重性層級。

1. (選用) 對於 **Category** (類別)，選擇類別。

1. 針對 **Description (描述)**，輸入此 OpsItem 的資訊，包括 (如合適) 重現問題的步驟。
**注意**  
主控台支援 OpsItem 描述欄位中的大多數 Markdown 格式。如需詳細資訊，請參閱《 AWS 管理主控台 入門指南》**中的[在主控台中使用 Markdown](https://docs.aws.amazon.com/awsconsolehelpdocs/latest/gsg/aws-markdown.html)。

1. 在**重複資料刪除字串**中，輸入系統可用來檢查重複 OpsItems 的單字。如需重複資料刪除字串的詳細資訊，請參閱[管理重複的 OpsItems](OpsCenter-working-deduplication.md)。

1. (選用) 在**通知**中，指定您希望 OpsItem 更新時發送通知的 Amazon SNS 主題的 Amazon Resource Name (ARN)。您必須指定與 相同的 AWS 區域 Amazon SNS ARNOpsItem。

1. (選用) 在**相關資源**中，選擇**新增**，指定受影響資源和任何相關資源的 ID 或 ARN。

1. 選擇**建立OpsItem**。

如果成功，頁面會顯示 OpsItem。委派管理員或管理帳戶為選取的成員帳戶建立 OpsItem 後，新 OpsItems 會顯示在管理員和成員帳戶的 OpsCenter 中。如需如何在 OpsItem 中設定選項的資訊，請參閱 [管理 OpsItems](OpsCenter-working-with-OpsItems.md)。

# 手動建立 OpsItems (AWS CLI)
<a name="OpsCenter-creating-OpsItems-CLI"></a>

下列處理程序說明如何使用 AWS Command Line Interface (AWS CLI) 建立 OpsItem。

**OpsItem 使用 建立 AWS CLI**

1. 如果您尚未安裝並設定 AWS Command Line Interface (AWS CLI)，請安裝並設定 。

   如需相關資訊，請參閱[安裝或更新最新版本的 AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)。

1. 開啟 AWS CLI 並執行下列命令來建立 OpsItem。將每個*範例資源預留位置*取代為您自己的資訊。

   ```
   aws ssm create-ops-item \
       --title "Descriptive_title" \
       --description "Information_about_the_issue" \
       --priority Number_between_1_and_5 \
       --source Source_of_the_issue \
       --operational-data Up_to_20_KB_of_data_or_path_to_JSON_file \
       --notifications Arn="SNS_ARN_in_same_Region" \
       --tags "Key=key_name,Value=a_value"
   ```

   **從檔案指定營運資料**

   當您建立 OpsItem 時，您可以從檔案指定營運資料。這個檔案必須是 JSON 檔案，且檔案內容必須使用以下格式。

   ```
   {
     "key_name": {
       "Type": "SearchableString",
       "Value": "Up to 20 KB of data"
     }
   }
   ```

   請見此處範例。

   ```
   aws ssm create-ops-item ^
       --title "EC2 instance disk full" ^
       --description "Log clean up may have failed which caused the disk to be full" ^
       --priority 2 ^
       --source ec2 ^
       --operational-data file:///Users/TestUser1/Desktop/OpsItems/opsData.json ^
       --notifications Arn="arn:aws:sns:us-west-1:12345678:TestUser1" ^
       --tags "Key=EC2,Value=Production"
   ```
**注意**  
如需如何在不同的本機作業系統的命令列輸入 JSON 格式參數的資訊，請參閱《*AWS Command Line Interface 使用者指南*》中的[在 AWS CLI中搭配字串使用引號](https://docs.aws.amazon.com/cli/latest/userguide/cli-usage-parameters-quoting-strings.html)。

   系統會傳回如下資訊。

   ```
   {
       "OpsItemId": "oi-1a2b3c4d5e6f"
   }
   ```

1. 執行以下命令來檢視您建立的 OpsItem 的詳細資訊。

   ```
   aws ssm get-ops-item --ops-item-id ID
   ```

   系統會傳回如下資訊。

   ```
   {
       "OpsItem": {
           "CreatedBy": "arn:aws:iam::12345678:user/TestUser",
           "CreatedTime": 1558386334.995,
           "Description": "Log clean up may have failed which caused the disk to be full",
           "LastModifiedBy": "arn:aws:iam::12345678:user/TestUser",
           "LastModifiedTime": 1558386334.995,
           "Notifications": [
               {
                   "Arn": "arn:aws:sns:us-west-1:12345678:TestUser"
               }
           ],
           "Priority": 2,
           "RelatedOpsItems": [],
           "Status": "Open",
           "OpsItemId": "oi-1a2b3c4d5e6f",
           "Title": "EC2 instance disk full",
           "Source": "ec2",
           "OperationalData": {
               "EC2": {
                   "Value": "12345",
                   "Type": "SearchableString"
               }
           }
       }
   }
   ```

1. 執行下列命令以更新 OpsItem。此命令會將狀態從 `Open` (預設值) 變更成 `InProgress`。

   ```
   aws ssm update-ops-item --ops-item-id ID --status InProgress
   ```

   此命令無輸出。

1. 再次執行以下命令，確認狀態是否已變更為 `InProgress`。

   ```
   aws ssm get-ops-item --ops-item-id ID
   ```

## 建立 OpsItem 的範例
<a name="OpsCenter_creating_OpsItems-CLI_examples"></a>

以下範例會說明如何使用 Linux 管理入口網站、macOS 或 Windows Server 建立 OpsItem。

**Linux 管理入口網站或 macOS**

以下命令會在 Amazon Elastic Compute Cloud (Amazon EC2) 執行個體磁碟已滿時建立 OpsItem。

```
aws ssm create-ops-item \
    --title "EC2 instance disk full" \
    --description "Log clean up may have failed which caused the disk to be full" \
    --priority 2 \
    --source ec2 \
    --operational-data '{"EC2":{"Value":"12345","Type":"SearchableString"}}' \
    --notifications Arn="arn:aws:sns:us-west-1:12345678:TestUser1" \
    --tags "Key=EC2,Value=ProductionServers"
```

以下命令會在 `OperationalData` 中使用 `/aws/resources` 金鑰，來建立含 Amazon DynamoDB 相關資源的 OpsItem。

```
aws ssm create-ops-item \
    --title "EC2 instance disk full" \
    --description "Log clean up may have failed which caused the disk to be full" \
    --priority 2 \
    --source ec2 \
    --operational-data '{"/aws/resources":{"Value":"[{\"arn\": \"arn:aws:dynamodb:us-west-2:12345678:table/OpsItems\"}]","Type":"SearchableString"}}' \
    --notifications Arn="arn:aws:sns:us-west-2:12345678:TestUser"
```

以下命令會在 `OperationalData` 中使用 `/aws/automations` 金鑰，來建立可將 `AWS-ASGEnterStandby` 文件指定為相關聯的 Automation 執行手冊的 OpsItem。

```
aws ssm create-ops-item \
    --title "EC2 instance disk full" \
    --description "Log clean up may have failed which caused the disk to be full" \
    --priority 2 \
    --source ec2 \
    --operational-data '{"/aws/automations":{"Value":"[{\"automationId\": \"AWS-ASGEnterStandby\", \"automationType\": \"AWS::SSM::Automation\"}]","Type":"SearchableString"}}' \
    --notifications Arn="arn:aws:sns:us-west-2:12345678:TestUser"
```

**Windows**

以下命令會在 Amazon Relational Database Service (Amazon RDS) 執行個體未回應時建立 OpsItem。

```
aws ssm create-ops-item ^
    --title "RDS instance not responding" ^
    --description "RDS instance not responding to ping" ^
    --priority 1 ^
    --source RDS ^
    --operational-data={\"RDS\":{\"Value\":\"abcd\",\"Type\":\"SearchableString\"}} ^
    --notifications Arn="arn:aws:sns:us-west-1:12345678:TestUser1" ^
    --tags "Key=RDS,Value=ProductionServers"
```

以下命令會在 `OperationalData` 中使用 `/aws/resources` 金鑰，來建立含 Amazon EC2 執行個體相關資源的 OpsItem。

```
aws ssm create-ops-item ^
    --title "EC2 instance disk full" ^
    --description "Log clean up may have failed which caused the disk to be full" ^
    --priority 2 ^
    --source ec2 ^
    --operational-data={\"/aws/resources\":{\"Value\":\"[{\\"""arn\\""":\\"""arn:aws:ec2:us-east-1:123456789012:instance/i-1234567890abcdef0\\"""}]\",\"Type\":\"SearchableString\"}}
```

以下命令會在 `OperationalData` 中使用 `/aws/automations` 金鑰，來建立可將 `AWS-RestartEC2Instance` 執行手冊指定為相關聯的 Automation 執行手冊的 OpsItem。

```
aws ssm create-ops-item ^
    --title "EC2 instance disk full" ^
    --description "Log clean up may have failed which caused the disk to be full" ^
    --priority 2 ^
    --source ec2 ^
    --operational-data={\"/aws/automations\":{\"Value\":\"[{\\"""automationId\\""":\\"""AWS-RestartEC2Instance\\”"",\\"""automationType\\""":\\"""AWS::SSM::Automation\\"""}]\",\"Type\":\"SearchableString\"}}
```

# 手動建立 OpsItems (PowerShell)
<a name="OpsCenter-creating-OpsItems-Powershell"></a>

下列程序說明如何使用 AWS Tools for Windows PowerShell建立 OpsItem。

**OpsItem 使用 建立 AWS Tools for Windows PowerShell**

1. 開啟 AWS Tools for Windows PowerShell 並執行下列命令來指定您的登入資料。

   ```
   Set-AWSCredentials –AccessKey key-name –SecretKey key-name
   ```

1. 執行下列命令， AWS 區域 為您的PowerShell工作階段設定 。

   ```
   Set-DefaultAWSRegion -Region Region
   ```

1. 執行下列命令以建立新的 OpsItem。將每個*範例資源預留位置*取代為您自己的資訊。這個命令會指定 Systems Manager Automation Runbook 來修復此 OpsItem。

   ```
   $opsItem = New-Object Amazon.SimpleSystemsManagement.Model.OpsItemDataValue
   $opsItem.Type = [Amazon.SimpleSystemsManagement.OpsItemDataType]::SearchableString 
   $opsItem.Value = '[{\"automationId\":\"runbook_name\",\"automationType\":\"AWS::SSM::Automation\"}]'
   $newHash = @{" /aws/automations"=[Amazon.SimpleSystemsManagement.Model.OpsItemDataValue]$opsItem}
   
   New-SSMOpsItem `
       -Title "title" `
       -Description "description" `
       -Priority priority_number `
       -Source AWS_service `
       -OperationalData $newHash
   ```

   如果成功，命令會輸出新 OpsItem 的 ID。

以下範例指定受損 Amazon Elastic Compute Cloud (Amazon EC2) 執行個體的 Amazon Resource Name (ARN)。

```
$opsItem = New-Object Amazon.SimpleSystemsManagement.Model.OpsItemDataValue
$opsItem.Type = [Amazon.SimpleSystemsManagement.OpsItemDataType]::SearchableString 
$opsItem.Value = '[{\"arn\":\"arn:aws:ec2:us-east-1:123456789012:instance/i-1234567890abcdef0\"}]'
$newHash = @{" /aws/resources"=[Amazon.SimpleSystemsManagement.Model.OpsItemDataValue]$opsItem}
New-SSMOpsItem -Title "EC2 instance disk full still" -Description "Log clean up may have failed which caused the disk to be full" -Priority 2 -Source ec2 -OperationalData $newHash
```

# 管理 OpsItems
<a name="OpsCenter-working-with-OpsItems"></a>

OpsCenter是 中的工具 AWS Systems Manager，OpsItems會從建立追蹤到解析。如果為 OpsCenter 設定了跨帳戶管理，則委派管理員或管理帳戶可以從其帳戶管理 OpsItems。如需詳細資訊，請參閱[(選用) 手動設定 OpsCenter 以跨帳戶集中管理 OpsItems](OpsCenter-getting-started-multiple-accounts.md)。

您可以使用 Systems Manager 主控台中的下列頁面來檢視和管理 OpsItems：
+ **摘要** – 顯示「待處理」和「進行中」的 OpsItems 計數、依來源和存在時間分類的 OpsItems 計數，以及操作洞察的計數。您可以依來源和 OpsItems 狀態來篩選 OpsItems。
+ **OpsItems** – 顯示包含多個資訊欄位的 OpsItems 清單，其例如標題、ID、優先順序、描述、OpsItem 的來源以及上次更新日期和時間。您可以使用此頁面手動建立 OpsItems、設定來源、變更 OpsItem 的狀態，以及依新事件篩選 OpsItems。您可以選擇 OpsItem 以顯示其 **OpsItems 詳細資訊**頁面。
+ **OpsItem 詳細資訊** – 提供詳細的洞察和工具，供您用來管理 OpsItem。OpsItems 詳細資訊頁面包含下列索引標籤：
  + **概觀** – 顯示相關資源、過去 30 天內執行的執行手冊，以及您可以執行的可用執行手冊清單。您還可以檢視類似的 OpsItems，新增操作資料和新增相關的 OpsItems。
  + **相關資源詳細資訊** – 顯示來自數個 AWS 服務的資源相關資訊。展開**資源詳細資訊**區段，以檢視託管資源 AWS 的服務所提供的資源相關資訊。您也可以使用 **Related resources** (相關資源) 清單切換與此 OpsItem 關聯的其他相關資源。

如需有關如何管理 OpsItems 的詳細資訊，請參閱下列主題。

**Topics**
+ [檢視 OpsItem 的詳細資訊](OpsCenter-working-with-OpsItems-viewing-details.md)
+ [編輯 OpsItem](OpsCenter-working-with-OpsItems-editing-details.md)
+ [將相關的資源新增至 OpsItem](OpsCenter-working-with-OpsItems-adding-related-resources.md)
+ [將相關的 OpsItems 新增至 OpsItem](OpsCenter-working-with-OpsItems-adding-related-OpsItems.md)
+ [將操作資料新增至 OpsItem](OpsCenter-working-with-OpsItems-adding-operational-data.md)
+ [為 OpsItem 建立事件](OpsCenter-working-with-OpsItems-create-an-incident.md)
+ [管理重複的 OpsItems](OpsCenter-working-deduplication.md)
+ [分析操作洞察以減少 OpsItems](OpsCenter-working-operational-insights.md)
+ [檢視 OpsCenter 日誌和報告](OpsCenter-logging-auditing.md)

# 檢視 OpsItem 的詳細資訊
<a name="OpsCenter-working-with-OpsItems-viewing-details"></a>

若要全面檢視 OpsItem，請使用 OpsCenter 主控台中的 **OpsItem 詳細資訊**頁面。**概觀**頁面會顯示以下資訊：
+ **OpsItems 詳細資訊** – 顯示所選 OpsItem 的一般資訊。
+ **相關資源** – 相關資源是受影響的資源，或啟動建立 OpsItem 之事件的資源。
+ **過去 30 天的自動化執行** – 過去 30 天內執行的執行手冊清單。
+ **執行手冊** – 您可以從可用的執行手冊清單中選擇一個執行手冊。
+ **類似的 OpsItem** – 這是系統產生的 OpsItems 清單，其可能是與您有關或是您感興趣的項目。若要產生清單，系統會掃描所有 OpsItems 的標題和描述，並傳回使用類似字詞的 OpsItems。
+ **操作資料** – 操作資料是自訂的資料，可提供有關 OpsItem 的實用參考詳細資訊。例如，您可以指定日誌檔案、錯誤字串、授權金鑰、故障診斷秘訣，或其他相關資料。
+ **相關的 OpsItem** – 您可指定以某種方式與目前 OpsItem 相關之 OpsItems 的 ID。
+ **相關資源詳細資訊** – 顯示資料提供者，包括來自 的 Amazon CloudWatch 指標和警示、 AWS CloudTrail 日誌和詳細資訊 AWS Config。

**檢視 OpsItem 的詳細資訊**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 OpsItem 來檢視其詳細資訊。

# 編輯 OpsItem
<a name="OpsCenter-working-with-OpsItems-editing-details"></a>

**OpsItem 詳細資訊**區段包含有關 OpsItem 的資訊，包括描述、標題、來源、OpsItem ID 和狀態。  您可以編輯單一 OpsItem，或可以選取多個 OpsItems，然後編輯下列欄位：**狀態**、**優先順序**、**嚴重性**、**類別**。

Amazon EventBridge 建立 OpsItem 時，會填入**標題**、**來源**和**描述**欄位。您可以編輯**標題**和**描述**欄位，但無法編輯**來源**欄位。

**注意**  
主控台支援 OpsItem 描述欄位中的大多數 Markdown 格式。如需詳細資訊，請參閱《 入門指南》中的[在主控台中使用 Markdown](https://docs.aws.amazon.com/awsconsolehelpdocs/latest/gsg/aws-markdown.html)。 * AWS 管理主控台 *

一般而言，您可以編輯 OpsItem 的下列可設定資料：
+ **標題** – OpsItem 的名稱。來源會建立 OpsItem 的標題。
+ **描述** – 關於此 OpsItem 的資訊，包含 (如合適) 重現問題的步驟。
+ **狀態**：OpsItem 的狀態。如需有效狀態值的清單，請參閱《AWS Systems Manager API 參考》**中的 [OpsItem Status](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_OpsItem.html#systemsmanager-Type-OpsItem-Status)。
+ **優先順序** – OpsItem 的優先順序可以介於 1 至 5 之間。建議您的組織決定每個優先順序層級的意義，及各層級對應的服務水準協議。
+ **嚴重性** – OpsItem 的嚴重性可以介於 1 至 4 之間，其中 1 為嚴重，2 為高，3 為中等，4 為低。
+ **類別** – OpsItem 的類別可以是可用性、成本、效能、復原或安全性。
+ **通知** – 編輯 OpsItem 時，可以在**通知**欄位中指定 Amazon Simple Notification Service 主題的 Amazon Resource Name (ARN)。透過指定 ARN，您確保所有利害關係人都會在編輯 OpsItem 時收到通知，包括狀態變更。如需詳細資訊，請參閱《[https://docs.aws.amazon.com/sns/latest/dg/](https://docs.aws.amazon.com/sns/latest/dg/)》。
**重要**  
Amazon SNS 主題必須存在於與 AWS 區域 相同的 中OpsItem。如果主題和 OpsItem 分屬不同區域，系統會傳回錯誤。

OpsCenter 具有與 的雙向整合 AWS Security Hub CSPM。當您更新與安全性調查結果相關的OpsItem狀態和嚴重性時，這些變更會自動傳送至 Security Hub CSPM，以確保您始終看到最新且正確的資訊。

從 Security Hub CSPM 調查結果建立 OpsItem 時，Security Hub CSPM 中繼資料會自動新增至 的操作資料欄位OpsItem。如果刪除這些中繼資料，雙向更新將無法再運作。

**編輯 OpsItem 詳細資訊**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 OpsItem ID 以開啟詳細資訊頁面或選擇多個 OpsItems。如果選擇多個 OpsItems，則您只能編輯狀態、優先順序、嚴重性或類別。如果編輯多個 OpsItems，則 OpsCenter 會在您選擇新的狀態、優先順序、嚴重性或類別時立即更新並儲存您的變更。

1. 在 **OpsItem details (OpsItem 詳細資訊)** 區段，選擇 **Edit (編輯)**。

1. 根據您組織指定的需求和準則編輯 OpsItem 的詳細資訊。

1. 完成後，請選擇**儲存**。

# 將相關的資源新增至 OpsItem
<a name="OpsCenter-working-with-OpsItems-adding-related-resources"></a>

每個 OpsItem 都包含**相關資源**區段，此區域會列出相關資源的 Amazon Resource Name (ARN)。*相關資源*是需要調查的受影響 AWS 資源。

如果 Amazon EventBridge 建立 OpsItem，系統會自動使用資源的 ARN 填入 OpsItem。您可以手動指定相關資源的 ARN。針對某些 ARN 類型，OpsCenter 會自動建立深層連結，在 OpsCenter 主控台中直接顯示資源的詳細資訊。例如，如果您將一個 Amazon Elastic Compute Cloud (Amazon EC2) 執行個體的 ARN 指定為相關資源，則 OpsCenter 會提取該 EC2 執行個體的詳細資訊。這可讓您檢視受影響 AWS 資源的詳細資訊，而不必離開 OpsCenter。

**檢視相關資源並新增至 OpsItem**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 ** (OpsItems)** 索引標籤。

1. 選擇 OpsItem ID。  
![\[OpsCenter 概觀頁面的新 OpsItem。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_working_scenario_1.png)

1. 若要檢視受影響資源的資訊，請選擇 **Related resources details (相關資源詳細資訊)** 標籤。  
![\[檢視 OpsItem 的「相關資源詳細資訊」索引標籤。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_working_scenario_1_5.png)

   這個索引標籤會顯示來自多種 AWS 服務之資源的相關資訊。展開**資源詳細資訊**區段，以檢視託管資源的 AWS 服務 所提供的資源相關資訊。您也可以使用 **Related resources** (相關資源) 清單切換與此 OpsItem 關聯的其他相關資源。

1. 若要新增其他相關資源，請選擇 **Overview (概觀)** 標籤。

1. 在 **Related resources (相關資源)** 區段中，選擇 **Add (新增)**。

1. 對於 **Resource Type** (資源類型)，選擇清單中的資源。

1. 對於 **Resource ID** (資源 ID)，輸入 ID 或 Amazon Resource Name (ARN)。您所選擇的資訊類型取決於您在上個步驟所選擇的資源。

**注意**  
您可以手動新增其他相關資源的 ARN。每個 OpsItem 最多可以列出 100 個相關的資源 ARN。

下表列出了會自動建立相關資源深層連結的資源類型。


**支援的資源類型**  

| 資源名稱 | ARN 格式 | 
| --- | --- | 
|  AWS Certificate Manager 憑證  |  <pre>arn:aws:acm:region:account-id:certificate/certificate-id</pre>  | 
|  Amazon EC2 Auto Scaling 群組  |  <pre>arn:aws:autoscaling:region:account-id:autoScalingGroup:groupid:autoScalingGroupName/groupfriendlyname</pre>  | 
|  Amazon CloudFront 分佈  |  <pre>arn:aws:cloudfront::account-id:*</pre>  | 
|  AWS CloudFormation 堆疊  |  <pre>arn:aws:cloudformation:region:account-id:stack/stackname/additionalidentifier</pre>  | 
|  Amazon CloudWatch 警示  |  <pre>arn:aws:cloudwatch:region:account-id:alarm:alarm-name</pre>  | 
|  AWS CloudTrail 線索  |  <pre>arn:aws:cloudtrail:region:account-id:trail/trailname</pre>  | 
|  AWS CodeBuild 專案  |  <pre>arn:aws:codebuild:region:account-id:resourcetype/resource</pre>  | 
|  AWS CodePipeline  |  <pre>arn:aws:codepipeline:region:account-id:resource-specifier</pre>  | 
|  Amazon DevOps Guru 洞察  |  <pre>arn:aws:devops-guru:region:account-id:insight/proactive or reactive/resource-id</pre>  | 
|  Amazon DynamoDB 資料表  |  <pre>arn:aws:dynamodb:region:account-id:table/tablename</pre>  | 
|  Amazon Elastic Compute Cloud (Amazon EC2) 客戶閘道  |  <pre>arn:aws:ec2:region:account-id:customer-gateway/cgw-id</pre>  | 
|  Amazon EC2 彈性 IP  |  <pre>arn:aws:ec2:region:account-id:eip/eipalloc-id</pre>  | 
|  Amazon EC2 專用主機  |  <pre>arn:aws:ec2:region:account-id:dedicated-host/host-id</pre>  | 
|  Amazon EC2 執行個體  |  <pre>arn:aws:ec2:region:account-id:instance/instance-id</pre>  | 
|  Amazon EC2 網際網路閘道  |  <pre>arn:aws:ec2:region:account-id:internet-gateway/igw-id</pre>  | 
|  Amazon EC2 網路存取控制清單 (network ACL)  |  <pre>arn:aws:ec2:region:account-id:network-acl/nacl-id</pre>  | 
|  Amazon EC2 網路界面  |  <pre>arn:aws:ec2:region:account-id:network-interface/eni-id</pre>  | 
|  Amazon EC2 路由表  |  <pre>arn:aws:ec2:region:account-id:route-table/route-table-id</pre>  | 
|  Amazon EC2 安全群組  |  <pre>arn:aws:ec2:region:account-id:security-group/security-group-id</pre>  | 
|  Amazon EC2 子網路  |  <pre>arn:aws:ec2:region:account-id:subnet/subnet-id</pre>  | 
|  Amazon EC2 磁碟區  |  <pre>arn:aws:ec2:region:account-id:volume/volume-id</pre>  | 
|  Amazon EC2 VPC  |  <pre>arn:aws:ec2:region:account-id:vpc/vpc-id</pre>  | 
|  Amazon EC2 VPN 連接  |  <pre>arn:aws:ec2:region:account-id:vpn-connection/vpn-id</pre>  | 
|  Amazon EC2 VPN 閘道  |  <pre>arn:aws:ec2:region:account-id:vpn-gateway/vgw-id</pre>  | 
|  AWS Elastic Beanstalk 應用程式  |  <pre>arn:aws:elasticbeanstalk:region:account-id:application/applicationname</pre>  | 
|  Elastic Load Balancing (Classic Load Balancer)  |  <pre>arn:aws:elasticloadbalancing:region:account-id:loadbalancer/name</pre>  | 
|  Elastic Load Balancing (Application Load Balancer)  |  <pre>arn:aws:elasticloadbalancing:region:account-id:loadbalancer/app/load-balancer-name/load-balancer-id</pre>  | 
|  Elastic Load Balancing (Network Load Balancer)  |  <pre>arn:aws:elasticloadbalancing:region:account-id:loadbalancer/net/load-balancer-name/load-balancer-id</pre>  | 
|  AWS Identity and Access Management (IAM) 群組  |  <pre>arn:aws:iam::account-id:group/group-name</pre>  | 
|  IAM 政策  |  <pre>arn:aws:iam::account-id:policy/policy-name</pre>  | 
|  IAM 角色  |  <pre>arn:aws:iam::account-id:role/role-name</pre>  | 
|  IAM 使用者  |  <pre>arn:aws:iam::account-id:user/user-name</pre>  | 
|  AWS Lambda 函數  |  <pre>arn:aws:lambda:region:account-id:function:function-name</pre>  | 
|  Amazon Relational Database Service (Amazon RDS) 叢集  |  <pre>arn:aws:rds:region:account-id:cluster:db-cluster-name</pre>  | 
|  Amazon RDS 資料庫執行個體  |  <pre>arn:aws:rds:region:account-id:db:db-instance-name</pre>  | 
|  Amazon RDS 訂閱  |  <pre>arn:aws:rds:region:account-id:es:subscription-name</pre>  | 
|  Amazon RDS 安全群組  |  <pre>arn:aws:rds:region:account-id:secgrp:security-group-name</pre>  | 
|  Amazon RDS 叢集快照  |  <pre>arn:aws:rds:region:account-id:cluster-snapshot:cluster-snapshot-name</pre>  | 
|  Amazon RDS 子網路群組  |  <pre>arn:aws:rds:region:account-id:subgrp:subnet-group-name</pre>  | 
|  Amazon Redshift 叢集  |  <pre>arn:aws:redshift:region:account-id:cluster:cluster-name</pre>  | 
|  Amazon Redshift 參數群組  |  <pre>arn:aws:redshift:region:account-id:parametergroup:parameter-group-name</pre>  | 
|  Amazon Redshift 安全群組  |  <pre>arn:aws:redshift:region:account-id:securitygroup:security-group-name</pre>  | 
|  Amazon Redshift 叢集快照  |  <pre>arn:aws:redshift:region:account-id:snapshot:cluster-name/snapshot-name</pre>  | 
|  Amazon Redshift 子網路群組  |  <pre>arn:aws:redshift:region:account-id:subnetgroup:subnet-group-name</pre>  | 
|  Amazon Simple Storage Service (Amazon S3) 儲存貯體  |  <pre>arn:aws:s3:::bucket_name</pre>  | 
|  AWS Config 受 AWS Systems Manager 管節點庫存的記錄  |  <pre>arn:aws:ssm:region:account-id:managed-instance-inventory/node_id</pre>  | 
|  Systems Manager State Manager 關聯  |  <pre>arn:aws:ssm:region:account-id:association/association_ID</pre>  | 

# 將相關的 OpsItems 新增至 OpsItem
<a name="OpsCenter-working-with-OpsItems-adding-related-OpsItems"></a>

透過使用 **OpsItems 詳細資訊**頁面**相關的 OpsItems**，您可以調查操作問題並提供問題的情境。OpsItems 能以不同的方式建立關聯，包括 OpsItems 之間的上/下層關係、根本原因或重複性。您可以將一個 OpsItem 與另一個建立關聯，以便在**相關的 OpsItem**區段中顯示。您可以為與目前 OpsItem 相關的其他 OpsItems 指定最多 10 個 ID。

![\[檢視相關的 OpsItems。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_working_scenario_4.png)


**新增相關 OpsItem**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 OpsItem ID 以開啟詳細資訊頁面。

1. 在 **Related (相關的 OpsItem)** 區段中，選擇 **Add (新增)**。

1. 針對 **OpsItem ID**，指定 ID。

1. 選擇**新增**。

# 將操作資料新增至 OpsItem
<a name="OpsCenter-working-with-OpsItems-adding-operational-data"></a>

操作資料是自訂的資料，可提供有關 OpsItem 的實用參考詳細資訊。您可以輸入多個營運資料的金鑰/值對。例如，您可以指定日誌檔案、錯誤字串、授權金鑰、故障診斷秘訣，或其他相關資料。索引鍵的最大長度可以是 128 個字元，值的大小上限可以是 20 KB。

![\[檢視 OpsItem 的營運資料。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_working_scenario_7.png)


您可以讓帳戶中的其他使用者可搜尋此資料，也可以限制搜尋的存取權。可搜尋資料表示，所有能存取 OpsItem **概觀**頁面的使用者 (如 [DescribeOpsItems](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DescribeOpsItems.html) API 操作所提供) 都可以檢視和搜尋指定的資料。只有能夠存取 OpsItem 的使用者可檢視非可搜尋操作資料 (如 [GetOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsItem.html) API 動作所提供)。

**將營運資料新增到 OpsItem**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 OpsItem ID 以開啟其詳細資訊頁面。

1. 展開**操作資料**。

1. 如果沒有 OpsItem 的操作資料，則選擇**新增**。如果已有 OpsItem 的營運資料，請選擇 **Manage (管理)**。

   在您建立營運資料之後，您可以選擇 **Manage (管理)**，編輯金鑰和值、移除營運資料，或新增其他金鑰/值對。

1. 針對 **Key (金鑰)**，指定一或多個字詞，協助使用者了解資料的用途。
**重要**  
操作資料金鑰*無法*以下列項目開頭：`amazon`、`aws`、`amzn`、`ssm`、`/amazon`、`/aws`、`/amzn`、`/ssm`。

1. 針對 **Value (值)**，指定資料。

1. 選擇**儲存**。

**注意**  
您可以透過使用 **OpsItems** 頁面上的 **Operational data (營運資料)** 運算子來篩選 OpsItems。在**搜尋**方塊中，選擇**操作資料**，然後以 JSON 輸入索引鍵/值組。您必須使用以下格式來輸入索引鍵/值組：`{"key":"key_name","value":"a_value"}`

# 為 OpsItem 建立事件
<a name="OpsCenter-working-with-OpsItems-create-an-incident"></a>

使用下列程序為 OpsItem 手動建立事件以追蹤和管理事件 AWS Systems Manager Incident Manager，這是 中的工具 AWS Systems Manager。*事件*是指任何意外中斷或服務質量下降。如需有關 Incident Manager 的詳細資訊，請參閱 [OpsCenter 與其他 整合 AWS 服務](OpsCenter-applications-that-integrate.md)。

**手動建立 OpsItem 事件**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 如果 Incident Manager 為您建立 OpsItem，請選擇它並前往步驟 5。如果沒有，請選擇 **Create OpsItem** (建立 OpsItem) 並填寫表格。如果您沒有看到此按鈕，請選擇 **OpsItems** 索引標籤，然後選擇 **Create OpsItem** (建立 OpsItem)。

1. 如果建立了 OpsItem，則請將其開啟。

1. 選擇 **Start Incident** (開始事件)。

1. 在**回應計劃**中，選擇您要指派給此事件的 Incident Manager 回應計劃。

1. (選用) 對於 **Title** (標題) 中，輸入描述名稱，以協助其他團隊成員了解事件的本質。如果不輸入新的標題，OpsCenter 會使用回應計劃中的標題建立 OpsItem 和 Incident Manager 中的對應事件。

1. (選用)對於 **Incident impact** (事件影響)，選擇此事件的影響層級。如果您沒有選擇影響層級，OpsCenter 會使用回應計劃中的標題建立 OpsItem 和 Incident Manager 中的對應事件。

1. 選擇 **開始使用**。

# 管理重複的 OpsItems
<a name="OpsCenter-working-deduplication"></a>

OpsCenter 可以從多個 AWS 服務接收單一來源的多個重複 OpsItems。OpsCenter 會使用內建邏輯和可設定重複資料刪除字串的組合來避免建立重複的 OpsItems。在呼叫 [CreateOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateOpsItem.html) API 操作時， AWS Systems Manager 會套用重複資料刪除內建邏輯。

AWS Systems Manager 使用以下重複資料刪除邏輯：

1. 建立 OpsItem 時，Systems Manager 會根據重複資料刪除字串和起始 OpsItem 的資源來建立會和存放雜湊。

1. 如果收到了另一個建立 OpsItem 的請求，系統會檢查新請求的重複資料刪除字串。

1. 如果此重複資料刪除字串存在相符的雜湊，Systems Manager 會檢查現有 OpsItem 的狀態。如果現有 OpsItem 的狀態為「待處理」或「進行中」，則不會建立 OpsItem。如果已解決現有的 OpsItem，Systems Manager 會建立新的 OpsItem。

建立 OpsItem 後，您就*不能*在該 OpsItem 中編輯或變更重複資料刪除字串。

若要管理重複的 OpsItems，可以執行以下操作：
+ 編輯針對以 OpsCenter 為目標的 Amazon EventBridge 規則的重複資料刪除字串。如需詳細資訊，請參閱[編輯預設 EventBridge 規則中的重複資料刪除字串](#OpsCenter-working-deduplication-editing-cwe)。
+ 請在您手動建立 OpsItem 時，指定重複資料刪除字串。如需詳細資訊，請參閱[使用 指定重複資料刪除字串 AWS CLI](#OpsCenter-working-deduplication-configuring-manual-cli)。
+ 使用操作洞察來檢閱和解決重複的 OpsItems。您可以使用執行手冊來解決重複的 OpsItems。

  為協助您解決重複的 OpsItems 並減少來源建立之 OpsItems 的數量，Systems Manager 提供了自動化執行手冊。如需相關資訊，請參閱[根據洞察解決重複 OpsItems](OpsCenter-working-operational-insights.md#OpsCenter-working-operational-insights-resolve)。

## 編輯預設 EventBridge 規則中的重複資料刪除字串
<a name="OpsCenter-working-deduplication-editing-cwe"></a>

使用下列處理程序指定以 OpsCenter 為目標之 EventBridge 規則的重複資料刪除字串。

**編輯 EventBridge 規則的重複資料刪除字串**

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

1. 在導覽窗格中，選擇**規則**。

1. 選擇規則，然後選擇 **Edit** (編輯)。

1. 前往 **Select target(s)** (選擇目標) 頁面。

1. 在 **Additional settings** (其他設定) 區段中，選擇 **Configure input transformer** (設定輸入轉換器)。

1. 在 **Template** (範本) 方塊中，尋找 `"operationalData": { "/aws/dedup"` JSON 項目和您要編輯的重複資料刪除字串。

   EventBridge 規則中的重複資料刪除字串項目使用下列 JSON 格式。

   ```
   "operationalData": { "/aws/dedup": {"type": "SearchableString","value": "{\"dedupString\":\"Words the system should use to check for duplicate OpsItems\"}"}}
   ```

   請見此處範例。

   ```
   "operationalData": { "/aws/dedup": {"type": "SearchableString","value": "{\"dedupString\":\"SSMOpsCenter-EBS-volume-performance-issue\"}"}}
   ```

1. 編輯重複資料刪除字串，然後選擇**確認**。

1. 選擇**下一步**。

1. 選擇**下一步**。

1. 選擇**更新規則**。

## 使用 指定重複資料刪除字串 AWS CLI
<a name="OpsCenter-working-deduplication-configuring-manual-cli"></a>

當您OpsItem使用 AWS Systems Manager 主控台或 手動建立新的 時，可以指定重複資料刪除字串 AWS CLI。如需在主控台手動建立 OpsItem 時輸入重複資料刪除字串的詳細資訊，請參閱 [手動建立 OpsItems](OpsCenter-manually-create-OpsItems.md)。如果使用的是 AWS CLI，則可以為 `OperationalData` 參數輸入重複資料刪除字串。參數語法要使用 JSON，如下範例所示。

```
--operational-data '{"/aws/dedup":{"Value":"{\"dedupString\": \"Words the system should use to check for duplicate OpsItems\"}","Type":"SearchableString"}}'
```

這裡的範例命令會指定 `disk full` 的重複資料刪除字串。

------
#### [ Linux & macOS ]

```
aws ssm create-ops-item \
    --title "EC2 instance disk full" \
    --description "Log clean up may have failed which caused the disk to be full" \
    --priority 1 \
    --source ec2 \
    --operational-data '{"/aws/dedup":{"Value":"{\"dedupString\": \"disk full\"}","Type":"SearchableString"}}' \
    --tags "Key=EC2,Value=ProductionServers" \
    --notifications Arn="arn:aws:sns:us-west-1:12345678:TestUser"
```

------
#### [ Windows ]

```
aws ssm create-ops-item ^
    --title "EC2 instance disk full" ^
    --description "Log clean up may have failed which caused the disk to be full" ^
    --priority 1 ^
    --source EC2 ^
    --operational-data={\"/aws/dedup\":{\"Value\":\"{\\"""dedupString\\""":\\"""disk full\\"""}\",\"Type\":\"SearchableString\"}} ^
    --tags "Key=EC2,Value=ProductionServers" --notifications Arn="arn:aws:sns:us-west-1:12345678:TestUser"
```

------

# 分析操作洞察以減少 OpsItems
<a name="OpsCenter-working-operational-insights"></a>

OpsCenter *操作洞察*會顯示有關重複的 OpsItems 的資訊。OpsCenter 會自動分析您帳戶中的 OpsItems 並產生三種類型的*洞察結果*。您可以在 OpsCenter **摘要**索引標籤的**操作洞察**區段中檢視此資訊。
+ **重複的 OpsItems**：當八個或更多 OpsItems 具有相同資源的相同標題時，便會產生一個洞察結果。
+ **最常見的標題**：當超過 50 個 OpsItems 具有相同的標題時，便會產生一個洞察結果。
+ **產生最多的資源 OpsItems** – 當 AWS 資源有超過 10 個開啟的 時，會產生洞見OpsItems。這些洞察結果及其對應的資源會顯示在 OpsCenter **摘要**索引標籤中的**產生最多 OpsItems 資源**表格中。資源會以 OpsItem 計數遞減的順序列出。

**注意**  
OpsCenter 會為下列資源類型建立**產生最多 OpsItems 的資源**洞察結果：  
Amazon Elastic Compute Cloud (Amazon EC2) 執行個體
Amazon EC2 安全群組
Amazon EC2 Auto Scaling 群組
Amazon Relational Database Service (Amazon RDS) 資料庫
Amazon RDS 叢集
AWS Lambda 函數
Amazon DynamoDB 資料表
Elastic Load Balancing 負載平衡器
Amazon Redshift 叢集
AWS Certificate Manager 憑證
Amazon Elastic Block Store 磁碟區

OpsCenter 強制執行每種類型最多 15 個洞察結果的限制。如果某個類型達到此限制，則 OpsCenter 不再顯示該類型的更多洞察結果。若要檢視更多洞察結果，您必須解決與該類型的操作洞察結果相關聯的所有 OpsItems。如果因為 15 個洞察結果限制而無法在主控台中顯示某個待處理的洞察結果，則在關閉另一個洞察結果之後，該洞察結果就會顯示出來。

選擇洞察後，OpsCenter 會顯示受影響 OpsItems 和資源的相關資訊。以下螢幕擷取畫面顯示範例，其中包含重複 OpsItem 洞察的詳細資訊。

![\[OpsCenter 洞察結果的詳細資訊檢視，其中包含 OpsItems 的相關資訊。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsCenter-insights-detailed.png)


操作洞察預設為關閉。如需有關使用操作洞察的詳細資訊，請參閱下列主題。

**Topics**
+ [啟用操作洞察](#OpsCenter-working-operational-insights-viewing)
+ [根據洞察解決重複 OpsItems](#OpsCenter-working-operational-insights-resolve)
+ [停用操作洞察](#OpsCenter-working-operational-insights-disable)

## 啟用操作洞察
<a name="OpsCenter-working-operational-insights-viewing"></a>

您可以在 Systems Manager 主控台的 **OpsCenter** 頁面上啟用操作洞察。啟用操作洞察後，Systems Manager 會建立稱為 `AWSServiceRoleForAmazonSSM_OpsInsights` 的 AWS Identity and Access Management (IAM) 服務連結角色。服務連結角色是直接連結至 Systems Manager 的特殊 IAM 角色類型。服務連結角色是預先定義的，並包含服務 AWS 服務 代表您呼叫其他 所需的所有許可。如需 `AWSServiceRoleForAmazonSSM_OpsInsights` 服務連結角色的詳細資訊，請參閱[使用角色在 Systems Manager OpsCenter 中建立操作洞察 OpsItems](using-service-linked-roles-service-action-4.md)。

**注意**  
記下以下重要資訊：  
您的 AWS 帳戶 需支付操作洞察費用。如需詳細資訊，請參閱[AWS Systems Manager 定價](https://aws.amazon.com/systems-manager/pricing/)。
OpsCenter 會定期使用批次處理重新整理洞察。這表示顯示在 OpsCenter 中的洞察清單可能不同步。

使用以下程序以在 OpsCenter 中啟用和檢視操作洞察。

**啟用和檢視操作洞察**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 在**操作洞察可用**訊息方塊中，選擇**啟用**。如果您沒有看到此訊息，請向下捲動至**操作洞察**區段，然後選擇**啟用**。

1. 啟用此功能後，在**摘要**索引標籤上，向下捲動至**操作洞察**區段。

1. 若要檢視已篩選的洞察結果清單，請選擇**重複的 OpsItems**、**最常見的標題**或**產生最多 OpsItems 的資源**旁的連結。若要檢視所有洞察，請選擇 **View all operational insights** (檢視所有操作洞察)。

1. 選擇洞察 ID 以檢視詳細資訊。

## 根據洞察解決重複 OpsItems
<a name="OpsCenter-working-operational-insights-resolve"></a>

若要解決洞察，您必須先解決與洞察相關聯的所有 OpsItems。您可以使用 `AWS-BulkResolveOpsItemsForInsight` Runbook 來解決與洞察相關聯的 OpsItems。

為協助您解決重複的 OpsItems 並減少來源建立之 OpsItems 的數量，Systems Manager 提供了下列自動化執行手冊：
+ `AWS-BulkResolveOpsItems` Runbook 會解決符合指定篩選條件的 OpsItems。
+ `AWS-AddOpsItemDedupStringToEventBridgeRule` 執行手冊新增了與指定 Amazon EventBridge 規則相關聯之所有 OpsItem 目標的重複資料刪除字串。如果規則已經有重複資料刪除字串，則執行手冊不會新增重複資料刪除字串。
+ 如果規則產生數十或數百個 OpsItems，則 `AWS-DisableEventBridgeRule` 會關閉 EventBridge 中的規則。

**解決操作洞察結果**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 在 **Overview** (概觀) 索引標籤上，向下捲動至 **Operational insights** (操作洞察)。

1. 選擇**檢視所有操作洞察結果**。

1. 選擇洞察 ID 以檢視詳細資訊。

1. 選擇一個執行手冊，然後選擇**執行**。

## 停用操作洞察
<a name="OpsCenter-working-operational-insights-disable"></a>

關閉操作洞察後，系統會停止建立新的洞察，並停止在主控台中顯示洞察。任何作用中的洞察都會在系統中保持不變，儘管您不會在主控台中看到這些資訊。如果再次啟用此功能，則系統會顯示先前未解決的洞察，並開始建立新的洞察。使用下列程序來關閉操作洞察。

**關閉操作洞察**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇**設定**。

1. 在 **Operational insights** (操作洞察) 區段中，選擇 **Edit** (編輯)，然後切換 **Disable** (停用) 選項。

1. 選擇**儲存**。

# 檢視 OpsCenter 日誌和報告
<a name="OpsCenter-logging-auditing"></a>

AWS CloudTrail 會記錄 AWS Systems Manager OpsCenter對 主控台、 AWS Command Line Interface (AWS CLI) 和 SDK 的 API 呼叫。您可以在 CloudTrail 主控台中，或在 Amazon Simple Storage Service (Amazon S3) 儲存貯體中檢視資訊。Amazon S3 會使用儲存貯體存放您帳戶的所有 CloudTrail 日誌。

OpsCenter 動作的日誌顯示建立、更新、取得和描述 OpsItem 活動。如需檢視和使用 Systems Manager 活動的 CloudTrail 日誌的詳細資訊，請參閱 [使用 記錄 AWS Systems Manager API 呼叫 AWS CloudTrail](monitoring-cloudtrail-logs.md)。

AWS Systems Manager OpsCenter 為您提供下列有關 的資訊OpsItems：
+ **OpsItem 狀態摘要** – 依狀態 (「待處理和正在進行」、「待處理」或「正在進行」) 提供 OpsItems 摘要。
+ **最多開啟的來源 OpsItems** – 提供開啟 的頂端明細 AWS 服務 OpsItems。
+ **OpsItems (依來源和存在時間) ** – 提供依來源和建立天數分組的 OpsItems 計數。

**檢視 OpsCenter 報告摘要**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 在 OpsItems **概觀**頁面上，選擇**摘要**。

1. 在 **OpsItems by source and age** (依來源和年齡的 OpsItem) 下，選擇搜尋列以根據 **Source** (來源) 篩選 OpsItems。使用清單來根據 **Status (狀態)** 進行篩選。

# 刪除 OpsItems
<a name="OpsCenter-delete-OpsItems"></a>

您可以使用 AWS Command Line Interface 或 AWS SDK OpsItem呼叫[刪除OpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_DeleteOpsItem.html) API 操作來刪除個人。您無法刪除 AWS 管理主控台中的 OpsItem。若要刪除 OpsItem，您的 AWS Identity and Access Management (IAM) 使用者、群組或角色必須具有管理員許可，或者您必須獲得呼叫 `DeleteOpsItem` API 操作的許可。

**重要**  
請留意有關此操作的下列重要資訊。  
刪除 OpsItem 是無法復原的動作。您無法復原已刪除的 OpsItem。
此操作會使用*最終一致性模式*，這表示系統可能需要幾分鐘的時間才能完成此操作。如果您刪除 OpsItem 並立即呼叫 (例如 [GetOpsItem](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_GetOpsItem.html))，則已刪除的 OpsItem 可能仍會出現在回應中。
此為等冪操作。如果您為相同的 OpsItem 重複呼叫此操作，則系統不會拋出異常。如果第一次呼叫成功，所有其他呼叫均會傳回與第一次呼叫相同的成功回應。
此操作不支援跨帳戶呼叫。委派管理員或管理帳戶無法刪除其他帳戶中的 OpsItems，即使 OpsCenter 已設定了跨帳戶管理亦然。如需有關跨帳戶管理的詳細資訊，請參閱 [(選用) 設定 OpsCenter 以跨帳戶集中管理 OpsItems](OpsCenter-setting-up-cross-account.md)。
如果您收到 `OpsItemLimitExceededException`，您就可以刪除一或多個 OpsItems，以減少低於配額限制的 OpsItems 總數。如需此例外狀況的詳細資訊，請參閱 [使用 OpsCenter 來疑難排解問題](OpsCenter-troubleshooting.md)。

## 刪除 OpsItem
<a name="OpsCenter-delete-OpsItems-deleting"></a>

使用下列程序來刪除 OpsItem。

**刪除 OpsItem**

1. 如果您尚未安裝和設定 AWS CLI。如需詳細資訊，請參閱[安裝或更新最新版本的 AWS CLI](https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html)。

1. 執行下列命令。以您要刪除的 OpsItem 之 ID 來取代 *ID*。

   ```
   aws ssm delete-ops-item --ops-item-id ID
   ```

如果成功，此命令不會傳回任何資料。

# 修正 OpsItem 問題
<a name="OpsCenter-remediating"></a>

使用 AWS Systems Manager Automation Runbook，您可以修復 中識別 AWS 的資源問題OpsItem。自動化使用預先定義的 Runbook 來修復 AWS 資源的常見問題。

每個 OpsItem 都包括**執行手冊**區段，其中提供了可用於修復的執行手冊清單。當您從清單中選擇 Automation 執行手冊時，OpsCenter 會自動顯示一些執行文件所需的欄位。執行 Automation 執行手冊時，系統會將執行手冊與 OpsItem 的相關資源建立關聯。Amazon EventBridge 建立 OpsItem 後，它會將執行手冊與該 OpsItem 建立關聯。OpsCenter 會為 OpsItem 保留 30 天的 Automation 執行手冊記錄。

 您可以選擇狀態來檢視有關該執行手冊的重要詳細資訊，例如自動化失敗的原因，以及發生失敗時 Automation 執行手冊執行的步驟，如下列範例所示。

![\[上次執行 Automation Runbook 的狀態資訊。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_automation_results.png)


所選 OpsItem 的 **Related resource details** (相關資源詳細資訊) 頁面包括 **Run automation** (執行自動化) 清單。您可以選擇最近或資源特定的 Automation 執行手冊進行執行以修復問題。此頁面也包含資料提供者，包括 Amazon CloudWatch 指標和警示、 AWS CloudTrail 日誌，以及來自 的詳細資訊 AWS Config。

![\[「相關資源」索引標籤上可用的指標。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_automation_related_resource_details.png)


您可以在主控台中選擇 Runbook 名稱或使用 [Systems Manager Automation Runbook Reference](automation-documents-reference.md)，檢視 Automation Runbook 資訊。

## 使用執行手冊修復 OpsItem
<a name="OpsCenter-remediating-how-to"></a>

在您使用 Automation 執行手冊來修復 OpsItem 問題之前，請執行下列動作：
+ 驗證您是否具有執行 Systems Manager Automation Runbook 的許可。如需詳細資訊，請參閱[設定自動化](automation-setup.md)。
+ 收集要執行之自動化的資源特定 ID 資訊。例如，如果想要執行可重新啟動 EC2 執行個體的自動化，則必須指定要重新啟動的 EC2 執行個體 ID。

**執行 Automation Runbook 修復 OpsItem 問題**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇 OpsItem ID 以開啟詳細資訊頁面。  
![\[OpsCenter 概觀頁面上的新 OpsItem。\]](http://docs.aws.amazon.com/zh_tw/systems-manager/latest/userguide/images/OpsItems_working_scenario_1.png)

1. 捲動至 **Runbooks** 區段。

1. 使用搜尋列或右上角的號碼尋找您要執行的 Automation 執行手冊。

1. 選擇 Runbook，然後選擇 **Execute (執行)**。

1. 輸入執行手冊所需的資訊，然後選擇**提交**。

   啟動執行手冊，系統會返回上一個畫面並顯示狀態。

1. 在**過去 30 天的 Automation 執行**區段中，選擇**執行 ID** 連結以檢視步驟和執行狀態。

## 使用關聯的執行手冊修復 OpsItem
<a name="OpsCenter-remediating-associated-runbooks"></a>

在您執行 OpsItem 的 Automation 執行手冊之後，OpsCenter 會將執行手冊與該 OpsItem 建立關聯。*相關聯*的執行手冊排名會高於**執行手冊**清單中的其他執行手冊。

使用下列處理程序執行已與 OpsItem 中相關資源建立關聯的 Automation Runbook。如需新增相關資源的資訊，請參閱 [管理 OpsItems](OpsCenter-working-with-OpsItems.md)。

**執行與資源相關聯之 Runbook 以修復 OpsItem 問題**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 開啟 OpsItem。

1. 在 **Related resources** (相關資源) 區段中，選擇您要執行 Automation Runbook 的資源。

1. 選擇 **Run automation** (執行自動化)，然後選擇您要執行的相關聯 Automation Runbook。

1. 輸入 Runbook 所需的資訊，然後選擇 **Execute (執行)**。

   啟動執行手冊，系統會返回上一個畫面並顯示狀態。

1. 在**過去 30 天的 Automation 執行**區段中，選擇**執行 ID** 連結以檢視步驟和執行狀態。

# 檢視 OpsCenter 摘要報告
<a name="OpsCenter-reports"></a>

AWS Systems Manager OpsCenter 包含會自動顯示下列資訊的摘要頁面：
+ **OpsItem 狀態摘要**：按狀態列出的 OpsItems 摘要，例如 `Open` 和 `In progress`。
+ **有最多待處理 OpsItem 的來源 OpsItems**：有待處理 OpsItems 之前幾項 AWS 服務 的明細。
+ **OpsItems (依來源和存在時間) **：依來源和建立天數分組的 OpsItems 計數。

**檢視 OpsCenter 摘要報告**

1. 開啟位於 AWS Systems Managerhttps://console.aws.amazon.com/systems-manager/ 的主控台。[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/)

1. 在導覽窗格中，選擇 **OpsCenter**，然後選擇**摘要**索引標籤。

1. 在 **OpsItems (依來源和存在時間)** 區段中，執行下列操作：

   1. (選用) 在篩選欄位中，選擇**來源**，選取 `Equal`、`Begin With`、或 `Not Equal`，然後輸入搜尋參數。

   1. 在相鄰的清單中選取下列狀態值之一：
      + `Open`
      + `In progress`
      + `Resolved`
      + `Open and in progress`
      + `All`

# 使用 OpsCenter 來疑難排解問題
<a name="OpsCenter-troubleshooting"></a>

本主題包含的資訊可協助您針對 OpsCenter 的常見錯誤和問題進行疑難排解。

## 您收到 OpsItemLimitExceededException
<a name="OpsCenter-troubleshooting-OpsItemLimitExceededException"></a>

如果您的 AWS 帳戶 已達到呼叫 CreateOpsItem API 操作時OpsItems允許的數目上限，您會收到 `OpsItemLimitExceededException`。如果您OpsItems的呼叫超過下列任一配額的 數目上限，則 會OpsCenter傳回例外狀況：
+ OpsItems AWS 帳戶 每個區域 （包括 `Open`和 `Resolved` OpsItems) 的總數：500，000 
+ OpsItems AWS 帳戶 每月數量上限：10，000

這些配額適用於從任何來源建立的 OpsItems，但下列項目除外：
+ OpsItems 由 AWS Security Hub CSPM 問題清單建立
+ 當事件管理員事件開啟時自動生成的 OpsItems

從這些來源建立的 OpsItems 不會計入您的 OpsItem 配額中，但會針對每個 OpsItem 向您收取費用。

如果您收到 `OpsItemLimitExceededException`，您就可以手動刪除 OpsItems，直到您低於使您無法建立新 OpsItem 的配額為止。同樣地，刪除為 Security Hub CSPM 調查結果或 Incident Manager 事件OpsItems建立的 ，並不會減少配額OpsItems強制執行的總數。您必須從其他來源刪除 OpsItems。如需有關如何刪除 OpsItem 的資訊，請參閱 [刪除 OpsItems](OpsCenter-delete-OpsItems.md)。

## 您收到來自 的大量 AWS 自動產生的大型帳單 OpsItems
<a name="OpsCenter-troubleshooting-auto-generated-OpsItems"></a>

如果您已設定與 的整合 AWS Security Hub CSPM， 會OpsItems為 Security Hub CSPM 調查結果OpsCenter建立 。根據 Security Hub CSPM 產生的調查結果數量，以及您在設定整合時登入的帳戶， OpsCenter可以產生大量 OpsItems，但需付費。以下是與 Security Hub CSPM 調查結果OpsItems所產生的相關更具體的詳細資訊：
+ 如果您在設定 OpsCenter和 Security Hub CSPM 整合時登入 Security Hub CSPM 管理員帳戶，系統會OpsItems為管理員*和*所有成員帳戶中的問題清單建立 。所有 OpsItems 都會*在管理員帳戶中*建立。取決於各種因素，這可能導致您需要向 AWS支付超乎預期的大帳單。

  如果您在設定整合時使用成員帳戶登入，則系統只會針對該個別帳戶中的調查結果建立 OpsItems。如需 Security Hub CSPM 管理員帳戶、成員帳戶及其與 EventBridge 事件摘要之調查結果關聯的詳細資訊，請參閱*AWS Security Hub 《 使用者指南*》中的 [Security Hub CSPM 與 EventBridge 整合的類型](https://docs.aws.amazon.com/securityhub/latest/userguide/securityhub-cwe-integration-types.html)。
+ 針對每個建立 OpsItem 的調查結果，系統會按照標準價格向您收取建立 OpsItem 的費用。如果您編輯 OpsItem或在 Security Hub CSPM 中更新對應的調查結果 （這會觸發OpsItem更新），也會向您收取費用。
+ OpsItems 與 整合所建立的 目前 AWS Security Hub CSPM *不受*區域中OpsItems每個帳戶 500，000 個配額上限的限制。因此，Security Hub CSPM 警示可以在帳戶中OpsItems的每個區域中建立超過 500，000 個收費項目。

  因此，對於高生產環境，我們建議將 Security Hub CSPM 問題清單的範圍限制為僅高嚴重性的問題。

**重要**  
如果您認為大量 OpsItems 是錯誤建立的，且您的 AWS 帳單未經保證，請聯絡 支援。

如果您不再希望系統OpsItems為 Security Hub CSPM 調查結果建立 ，請使用下列程序。

**停止接收 Security Hub OpsItems CSPM 問題清單**

1. 在 https：//[https://console.aws.amazon.com/systems-manager/](https://console.aws.amazon.com/systems-manager/) 開啟 AWS Systems Manager 主控台。

1. 在導覽窗格中，選擇 **OpsCenter**。

1. 選擇**設定**。

1. 在 **Security Hub CSPM 調查結果**區段中，選擇**編輯。**

1. 選擇滑桿以將**已啟用**變更為**已停用**。如果您無法切換滑桿，表示您的 尚未啟用 Security Hub CSPM AWS 帳戶。

1. 選擇**儲存**以儲存您的組態。 OpsCenter 不再OpsItems根據 Security Hub CSPM 調查結果建立 。

**重要**  
如果 將設定OpsCenter切換回**已啟用**並繼續OpsItems為問題清單建立，請登入 Systems Manager 委派管理員帳戶或 AWS Organizations 管理帳戶，然後重複此程序。如果您沒有登入這些帳戶的許可，請聯絡您的系統管理員，並要求他們重複此程序以停用帳戶的整合功能。

# 使用 Systems Manager 託管的 Amazon CloudWatch 儀表板
<a name="systems-manager-cloudwatch-dashboards"></a>

Amazon CloudWatch 儀表板是 CloudWatch 主控台中可自訂的首頁，可讓您在單一檢視中監控資源，甚至是分散在不同 AWS 區域的那些資源。您可以使用 CloudWatch 儀表板，為您的 AWS 資源建立指標和警示的自訂檢視。您可以利用儀表板來建立以下項目：
+ 選取指標和警示的單一檢視，可協助您評估在一或多個 AWS 區域之資源和應用程式的運作狀態。您可以選取在每個圖形上用於每個指標的顏色，如此您就可以追蹤跨多個圖形的相同指標。
+ 運作手冊，其會提供運作事件期間適用於團隊成員與如何回應特定事件的指導。
+ 關鍵資源和應用程式測量的常用檢視，可以由團隊成員共用以在運作事件期間形成較快的通訊流程。

您可以使用 主控台、 AWS Command Line Interface (AWS CLI) 或使用 CloudWatch `PutDashboard` API 來建立儀表板。如需詳細資訊，請參閱《*Amazon CloudWatch 使用者指南*》中的[使用 Amazon CloudWatch 儀表板](https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Dashboards.html)。