如何在 Amazon EMR 中解决系统提示“Failed to start the job flow due to an internal error”?

1 分钟阅读
0

我的 Amazon EMR 集群无法启动,我收到错误消息“Failed to start the job flow due to an internal error”。

简短描述

内部错误通常很快就会得到解决。请重试您的请求。如果问题依然存在,请确认已正确配置集群的网络和安全设置。

解决方法

打开 Amazon EMR 控制台,然后再次尝试启动集群。如果您仍然收到“Failed to start the job flow due to an internal error”消息,请验证以下设置。

Amazon EMR 服务角色的权限

加密 Amazon Elastic Block Store (Amazon EBS) 根设备和存储卷的安全配置需要相关权限。对于这些配置,请确保 Amazon EMR 服务角色 (EMR_DefaultRole) 有权限使用指定的 AWS Key Management Service (AWS KMS) 密钥

服务角色需要以下权限才能成功启动 EMR 集群:

{
  "Version": "2012-10-17",
  "Statement": [{
    "Sid": "EmrDiskEncryptionPolicy",
    "Effect": "Allow",
    "Action": [
      "kms:Encrypt",
      "kms:Decrypt",
      "kms:ReEncrypt*",
      "kms:CreateGrant",
      "kms:GenerateDataKeyWithoutPlaintext",
      "kms:DescribeKey"
    ],
    "Resource": [
      "arn:aws:kms:us-west-2:<account-id>:key/<key-id>"
    ]
  }]
}

如果 EMR 集群实例出现故障,则您可能会看到以下任意错误:

2022-10-17 15:59:24,736 attempt 12/1000: http://repo.eu-west-1.amazonaws.com/2018.03/main/mirror.list
2022-10-17 15:59:34,741 exception: [Errno 12] Timeout on http://repo.eu-west-1.amazonaws.com/2018.03/main/mirror.list: (28, 'Connection timed out after 10001 milliseconds')
2022-10-17 15:59:34,741 attempt 13/1000: http://repo.eu-west-1.amazonaws.com/2018.03/main/mirror.list
2022-10-17 15:59:44,749 exception: [Errno 12] Timeout on http://repo.eu-west-1.amazonaws.com/2018.03/main/mirror.list: (28, 'Connection timed out after 10000 milliseconds')

要排查这些错误,请按照以下步骤查看系统日志:

1.    登录 Amazon Elastic Compute Cloud (Amazon EC2) 控制台

2.    选择因集群故障而终止的 EC2 节点。

        注意:已终止的节点在 EC2 控制台上仅可用 1-2 个小时。

3.    选择 Action(操作)下拉列表,然后选择 Monitor(监控)。

4.    选择 Troubleshoot(排查),然后选择 Get system log(获取系统日志)。

虚拟私有云(VPC)子网路由

确保已为您的集群正在使用的数据来源正确配置 VPC 子网路由。按照设置 VPC 托管集群中的步骤操作。

安全组

确保为子网正确配置主安全组和核心/任务安全组。有关更多信息,请参阅使用 Amazon EMR 管理的安全组

EMR 集群中的所有必需操作也必须在默认 Amazon EMR 角色和实例配置文件角色中均被允许。

在配置 VPC 子网路由、安全组和角色之后,启动新集群。


相关信息

配置网络

相关视频

AWS 官方
AWS 官方已更新 1 年前