

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

# `AWSSupport-TroubleshootSUSERegistration`
<a name="automation-awssupport-troubleshoot-suse-registration"></a>

**Description**

`AWSSupport-TroubleshootSUSERegistration` Runbook 可協助您找出向 SUSE Update Infrastructure 註冊 Amazon Elastic Compute Cloud (Amazon EC2) SUSE Linux Enterprise Server執行個體失敗的原因。自動化輸出提供解決問題的步驟，或協助您疑難排解問題。如果執行個體在自動化期間通過所有檢查，執行個體會向 SUSE 更新基礎設施註冊。

[執行此自動化 （主控台）](https://console.aws.amazon.com/systems-manager/automation/execute/AWSSupport-TroubleshootSUSERegistration)

**文件類型**

 自動化

**擁有者**

Amazon

**平台**

Linux

**參數**
+ AutomationAssumeRole

  類型：字串

  描述：（選用） 允許 Systems Manager Automation 代表您執行動作的 (IAM) 角色的 AWS Identity and Access Management Amazon Resource Name (ARN)。如果未指定角色，Systems Manager Automation 會使用啟動此 Runbook 的使用者許可。
+ InstanceId

  類型：字串

  描述：（必要） 您要故障診斷的 Amazon EC2 執行個體 ID。

**必要的 IAM 許可**

`AutomationAssumeRole` 參數需要下列動作才能成功使用 Runbook。
+ `ssm:StartAutomationExecution`
+ `ssm:DescribeInstanceProperties`
+ `ssm:DescribeInstanceInformation`
+ `ssm:ListCommandInvocations`
+ `ssm:SendCommand`
+ `ssm:ListCommands`

**文件步驟**
+ `aws:assertAwsResourceProperty` - 檢查 Amazon EC2 執行個體是否由 管理 AWS Systems Manager。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體平台是否為 SLES。
+ `aws:runCommand` - 檢查套件`cloud-regionsrv-client`版本是否大於或等於所需的 9.0.10 版。
+ `aws:runCommand` - 檢查基本產品的符號連結是否損壞，並修正其損壞的連結。
+ `aws:runCommand` - 檢查主機檔案 (`/etc/hosts`) 是否包含 的記錄`smt-ec2-suscloud.net`。自動化會移除任何重複的項目。
+ `aws:runCommand` - 檢查是否已安裝 `curl`命令。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體是否可以存取執行個體中繼資料服務 (IMDS) 地址 169.254.169.254。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體是否有帳單代碼或 AWS Marketplace 產品代碼。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體是否可以透過 HTTPS 到達至少 1 個區域伺服器。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體是否可以透過 HTTP 連線至 Subscription Management Tool (SMT) 伺服器。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體是否可以透過 HTTPS 連線至 Subscription Management Tool (SMT) 伺服器。
+ `aws:runCommand` - 檢查 Amazon EC2 執行個體是否可以透過 HTTPS 到達`smt-ec2.susecloud.net`地址。
+ `aws:runCommand` - 向 SUSE Update Infrastructure 註冊 Amazon EC2 執行個體。
+ `aws:executeScript` - 收集並輸出所有先前步驟的輸出。