CloudFormation删除堆栈失败

0

【以下的问题经过翻译处理】 我已经完成了Mythical Mysfits教程,现在正在尝试删除所有内容,但是在尝试删除MythicalMysfitsCoreStack的五个资源(InternetGateway、PublicSubnetTwo、VPC、GatewayAttachement、PublicSubnetOne)时出现了失败的情况。

我怀疑最初是在VPC或EC2页面单独删除了一些内容,然后再试图通过CloudFormation页面进行删除,这可能是问题的原因。

任何帮助都将不胜感激。

谢谢


当我尝试通过AWS控制台删除时,我会收到以下错误。

Delete VPC (vpc-0fac336b2f059ec69) gives the following error: The VPC contains one or more in-use network interfaces, and cannot be deleted until those network interfaces have been deleted. View in-use network interfaces in the VPC. eni-0a9df062d49c3dec2 eni-07d10b3c3b852ce70

Delete Subnet (subnet-0206d2073c87a04f3) gives the following error: Note that the following subnets cannot be deleted: The following subnets contain one or more network interfaces, and cannot be deleted until those network interfaces have been deleted. Click here to view your network interfaces. subnet-0206d2073c87a04f3

Detach Network Interface (eni-0a9df062d49c3dec2) gives the following error: Error detaching network interface eni-0a9df062d49c3dec2: You are not allowed to manage 'ela-attach' attachments.

以下是从CloudFormation页面的Delete Stack尝试的输出。

我已经完成了Mythical Mysfits教程,现在正在尝试删除所有内容,但是在尝试删除MythicalMysfitsCoreStack的五个资源(InternetGateway、PublicSubnetTwo、VPC、GatewayAttachement、PublicSubnetOne)时出现了失败的情况。

我怀疑最初是在VPC或EC2页面单独删除了一些内容,然后再试图通过CloudFormation页面进行删除,这可能是问题的原因。

任何帮助都将不胜感激。

谢谢


当我尝试通过AWS控制台删除时,我会收到以下错误。

Delete VPC (vpc-0fac336b2f059ec69) gives the following error: The VPC contains one or more in-use network interfaces, and cannot be deleted until those network interfaces have been deleted. View in-use network interfaces in the VPC. eni-0a9df062d49c3dec2 eni-07d10b3c3b852ce70

Delete Subnet (subnet-0206d2073c87a04f3) gives the following error: Note that the following subnets cannot be deleted: The following subnets contain one or more network interfaces, and cannot be deleted until those network interfaces have been deleted. Click here to view your network interfaces. subnet-0206d2073c87a04f3

Detach Network Interface (eni-0a9df062d49c3dec2) gives the following error: Error detaching network interface eni-0a9df062d49c3dec2: You are not allowed to manage 'ela-attach' attachments.

以下是从CloudFormation页面的Delete Stack尝试的输出。

Logical ID: GatewayAttachement Physicial ID: Mythi-Gatew-1OYGS4QJHAZKU Type: AWS::EC2::VPCGatewayAttachment Status: DELETE_FAILED Status Reason: Network vpc-0fac336b2f059ec69 has some mapped public address(es). Please unmap those public address(es) before detaching the gateway. (Service: AmazonEC2; Status Code: 400; Error Code: DependencyViolation; Request ID: 8a6f95a2-e228-4248-8cfc-e9795dc0f4ac)

另外四个都是由于 "dependencies cannot be deleted" 原因:

Logical ID: InternetGateway Physical ID: igw-073adf8f593324462 Type: AWS::EC2::InternetGateway Status: DELETE_FAILED Reason: The internetGateway 'igw-073adf8f593324462' has dependencies and cannot be deleted. (Service: AmazonEC2; Status Code: 400; Error Code: DependencyViolation; Request ID: f96f89cd-2307-4cbf-91cb-8283b3568720)

Logical ID: PublicSubnetOne Physical ID: subnet-0206d2073c87a04f3 Type: AWS: EC2::Subnet Status: DELETE_FAILED Reason: The subnet 'subnet-0206d2073c87a04f3' has dependencies and cannot be deleted. (Service: AmazonEC2; Status Code: 400; Error Code: DependencyViolation; Request ID: b6986282-6d4f-414c-9eb3-92861c88cc64)

Logical ID: PublicSubnetTwo Physical ID: subnet-07621c0034b1e8af7 Type: AWS::EC2::Subnet Status: DELETE_FAILED Reason: The subnet 'subnet-07621c0034b1e8af7' has dependencies and cannot be deleted. (Service: AmazonEC2; Status Code: 400; Error Code: DependencyViolation; Request ID: 321b0cc8-e4a2-40c9-85ca-2afef32020ba)

Logical ID: VPC Physical ID: vpc-0fac336b2f059ec69 Type: AWS::EC2::VPC Status: DELETE_FAILED Reason: The vpc 'vpc-0fac336b2f059ec69' has dependencies and cannot be deleted. (Service: AmazonEC2; Status Code: 400; Error Code: DependencyViolation; Request ID: a03aeb29-46c8-49b4-b1f1-0bc769b4be3c)

profile picture
专家
已提问 5 个月前26 查看次数
1 回答
0

【以下的回答经过翻译处理】 看起来还有一些资源在使用你的VPC中的IP地址。 你可以使用EC2管理控制台的网络接口选项卡找到这些资源。 一旦找到附加到该VPC的ENI,你就可以找到单个资源。 具体而言,请查看连接到eni-0a9df062d49c3dec2的任何内容,它可以是任何数量的东西,包括实例、NAT网关、VPC终端或其他资源。

https://docs.aws.amazon.com/zh_cn/AWSEC2/latest/UserGuide/using-eni.html#delete_eni

profile picture
专家
已回答 5 个月前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则