

• 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)。

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

# 使用 Run Command 關閉 Kernel Live Patching
<a name="disable-klp"></a>

若要關閉 Kernel Live Patching，您可以在受管節點上執行 `yum` 命令，或使用 Run Command 和自訂 SSM 文件 `AWS-ConfigureKernelLivePatching`。

**注意**  
如果您不再需要使用 Kernel Live Patching，您可以隨時停用它。在大多數情況下，不需要關閉功能。

如需有關透過直接在受管節點上執行 `yum` 命令來關閉 Kernel Live Patching 的資訊，請參閱《Amazon EC2 使用者指南》**中的[啟用 Kernel Live Patching](https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/al2-live-patching.html#al2-live-patching-enable)。

**注意**  
當您關閉 Kernel Live Patching 時，程序會解除安裝 Kernel Live Patching 外掛程式，然後重新啟動受管節點。

**使用 Run Command 關閉 Kernel Live Patching (主控台)**

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. 在導覽窗格中，選擇 **Run Command**。

1. 選擇**執行命令**。

1. 在 **Command document** (命令文件) 清單中，選擇 SSM 文件 `AWS-ConfigureKernelLivePatching`。

1. 在 **Command parameters (命令參數)** 區段，指定所需的參數值。

1. 如需使用此頁面上其餘控制項的詳細資訊，請參閱[從主控台執行命令](running-commands-console.md)。

1. 選擇**執行**。

**關閉 Kernel Live Patching (AWS CLI)**
+ 使用類似以下的命令：

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

  ```
  aws ssm send-command \
      --document-name "AWS-ConfigureKernelLivePatching" \
      --targets "Key=instanceIds,Values=instance-id" \
      --parameters "EnableOrDisable=Disable"
  ```

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

  ```
  aws ssm send-command ^
      --document-name "AWS-ConfigureKernelLivePatching" ^
      --targets "Key=instanceIds,Values=instance-id" ^
      --parameters "EnableOrDisable=Disable"
  ```

------

  將 i*instance-id* 取代為您要啟用該功能的 Amazon Linux 2 受管節點 ID，例如 i-02573cafcfEXAMPLE。若要在多個受管節點上關閉此功能，您可以使用下列其中一種格式。
  + `--targets "Key=instanceids,Values=instance-id1,instance-id2"`
  + `--targets "Key=tag:tag-key,Values=tag-value"`

  如需可以在命令中使用之其他選項的相關資訊，請參閱《AWS CLI 命令參考》**中的 [https://docs.aws.amazon.com/cli/latest/reference/ssm/send-command.html](https://docs.aws.amazon.com/cli/latest/reference/ssm/send-command.html) 一節。