AWS CloudFormation
User Guide (API Version 2010-05-15)

Troubleshooting AWS CloudFormation StackSets

This topic contains some common AWS CloudFormation StackSets issues, and suggested solutions for those issues.

Common reasons for stack operation failure

Problem: A stack operation failed, and the stack instance status is OUTDATED.

Cause: There can be several common causes for stack operation failure.

  • Insufficient permissions in a target account for creating resources that are specified in your template.

  • The AWS CloudFormation template might have errors. Validate the template in AWS CloudFormation and fix errors before trying to create your stack set.

  • The template could be trying to create global resources that must be unique but aren't, such as S3 buckets.

  • A specified target account number doesn't exist. Check the target account numbers that you specified on the Set deployment options page of the wizard.

  • The administrator account does not have a trust relationship with the target account.

  • The maximum number of a resource that is specified in your template already exists in your target account. For example, you might have reached the limit of allowed IAM roles in a target account, but the template creates more IAM roles.

  • You have reached the maximum number of stacks that are allowed in a stack set. The maximum is 50.

Solution: For more information about the permissions required of target and administrator accounts before you can create stack sets, see Account Setup.

Retrying failed stack creation or update operations

Problem: A stack creation or update failed, and the stack instance status is OUTDATED. To troubleshoot why a stack creation or update failed, open the AWS CloudFormation console, and view the events for the stack, which will have a status of DELETED (for failed create operations) or FAILED (for failed update operations). Browse the stack events, and find the Status reason column. The value of Status reason explains why the stack operation failed.

After you have fixed the underlying cause of the stack creation failure, and you are ready to retry stack creation, perform the following steps.

Solution: Perform the following steps to retry your stack operation.

  1. In the console, select the stack set that contains the stack on which the operation failed.

  2. In the Actions menu, choose Manage stacks in stack set.

  3. On the Select action page, choose Edit stacks to retry creating or updating stacks.

  4. On the Select template page, to use the same AWS CloudFormation template, keep the default option, Current template. If your stack operation failed because the template required changes, and you want to upload a revised template, choose Upload a template to Amazon S3 instead, and then choose Browse to select your updated template. When you are finished uploading your revised template, choose Next.

  5. On the Specify details page, if you are not changing any parameters that are specific to your template, choose Next.

  6. On the Set deployment options page, change defaults for Maximum concurrent accounts and Failure tolerance, if desired. For more information about these settings, see Stack set operation options.

  7. On the Tags page, add tags if desired. For more information about tags, see Stack set operation options. When you are finished adding tags, choose Next.

  8. On the Review page, review your selections, and fill the checkbox to acknowledge required IAM capabilities. Choose Update stacks.

  9. If your stack is not successfully updated, repeat this procedure, after you've resolved any underlying issues that are preventing stack creation.