Table Of Contents

Feedback

User Guide

First time using the AWS CLI? See the User Guide for help getting started.

Note: You are viewing the documentation for an older major version of the AWS CLI (version 1).

AWS CLI version 2, the latest major version of AWS CLI, is now stable and recommended for general use. To view this page for the AWS CLI version 2, click here. For more information see the AWS CLI version 2 installation instructions and migration guide.

[ aws . autoscaling ]

describe-instance-refreshes

Description

Describes one or more instance refreshes.

You can determine the status of a request by looking at the Status parameter. The following are the possible statuses:

  • Pending - The request was created, but the operation has not started.
  • InProgress - The operation is in progress.
  • Successful - The operation completed successfully.
  • Failed - The operation failed to complete. You can troubleshoot using the status reason and the scaling activities.
  • Cancelling - An ongoing operation is being cancelled. Cancellation does not roll back any replacements that have already been completed, but it prevents new replacements from being started.
  • Cancelled - The operation is cancelled.

For more information, see Replacing Auto Scaling Instances Based on an Instance Refresh .

See also: AWS API Documentation

See 'aws help' for descriptions of global parameters.

Synopsis

  describe-instance-refreshes
--auto-scaling-group-name <value>
[--instance-refresh-ids <value>]
[--next-token <value>]
[--max-records <value>]
[--cli-input-json <value>]
[--generate-cli-skeleton <value>]

Options

--auto-scaling-group-name (string)

The name of the Auto Scaling group.

--instance-refresh-ids (list)

One or more instance refresh IDs.

(string)

Syntax:

"string" "string" ...

--next-token (string)

The token for the next set of items to return. (You received this token from a previous call.)

--max-records (integer)

The maximum number of items to return with this call. The default value is 50 and the maximum value is 100 .

--cli-input-json (string) Performs service operation based on the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton. If other arguments are provided on the command line, the CLI values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally.

--generate-cli-skeleton (string) Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input, prints a sample input JSON that can be used as an argument for --cli-input-json. If provided with the value output, it validates the command inputs and returns a sample output JSON for that command.

See 'aws help' for descriptions of global parameters.

Examples

To list instance refreshes

The following describe-instance-refreshes example returns a description of all instance refresh requests for the specified Auto Scaling group, including the status messsage and (if available) the status reason.

aws autoscaling describe-instance-refreshes \
    --auto-scaling-group-name my-asg

Output:

{
    "InstanceRefreshes": [
        {
            "InstanceRefreshId": "08b91cf7-8fa6-48af-b6a6-d227f40f1b9b",
            "AutoScalingGroupName": "my-asg",
            "Status": "InProgress",
            "StartTime": "2020-06-02T18:11:27Z",
            "PercentageComplete": 0,
            "InstancesToUpdate": 5
        },
        {
            "InstanceRefreshId": "dd7728d0-5bc4-4575-96a3-1b2c52bf8bb1",
            "AutoScalingGroupName": "my-asg",
            "Status": "Successful",
            "StartTime": "2020-06-02T16:43:19Z",
            "EndTime": "2020-06-02T16:53:37Z",
            "PercentageComplete": 100,
            "InstancesToUpdate": 0
        }
    ]
}

For more information, see Replacing Auto Scaling Instances Based on an Instance Refresh in the Amazon EC2 Auto Scaling User Guide.

Output

InstanceRefreshes -> (list)

The instance refreshes for the specified group.

(structure)

Describes an instance refresh for an Auto Scaling group.

InstanceRefreshId -> (string)

The instance refresh ID.

AutoScalingGroupName -> (string)

The name of the Auto Scaling group.

Status -> (string)

The current status for the instance refresh operation:

  • Pending - The request was created, but the operation has not started.
  • InProgress - The operation is in progress.
  • Successful - The operation completed successfully.
  • Failed - The operation failed to complete. You can troubleshoot using the status reason and the scaling activities.
  • Cancelling - An ongoing operation is being cancelled. Cancellation does not roll back any replacements that have already been completed, but it prevents new replacements from being started.
  • Cancelled - The operation is cancelled.

StatusReason -> (string)

Provides more details about the current status of the instance refresh.

StartTime -> (timestamp)

The date and time at which the instance refresh began.

EndTime -> (timestamp)

The date and time at which the instance refresh ended.

PercentageComplete -> (integer)

The percentage of the instance refresh that is complete. For each instance replacement, Amazon EC2 Auto Scaling tracks the instance's health status and warm-up time. When the instance's health status changes to healthy and the specified warm-up time passes, the instance is considered updated and added to the percentage complete.

InstancesToUpdate -> (integer)

The number of instances remaining to update before the instance refresh is complete.

NextToken -> (string)

A string that indicates that the response contains more items than can be returned in a single response. To receive additional items, specify this string for the NextToken value when requesting the next set of items. This value is null when there are no more items to return.