ec2-describe-snapshots

Description

Returns information about Amazon EBS snapshots available to the user. Information returned includes volume ID, status, start time, progress, owner ID, volume size, and description. Snapshots available to the user include public snapshots available for any user to launch, private snapshots owned by the user making the request, and private snapshots owned by other users for which the user granted explicit create volume permissions.

The create volume permissions fall into 3 categories:

PermissionDescription
publicThe owner of the snapshot granted create volume permissions for the snapshot to the all group. All users have create volume permissions for these snapshots.
explicitThe owner of the snapshot granted create volume permissions to a specific user.
implicitA user has implicit create volume permissions for all snapshots he or she owns.

The list of snapshots returned can be modified by specifying snapshot IDs, snapshot owners, or users with create volume permissions. If no options are specified, Amazon EC2 returns all snapshots for which the user has create volume permissions.

If you specify one or more snapshot IDs, only snapshots that have the specified IDs are returned. If you specify an invalid snapshot ID, a fault is returned. If you specify a snapshot ID for which you do not have access, it will not be included in the returned results.

If you specify one or more snapshot owners, only snapshots from the specified owners and for which you have access are returned. The results can include the AWS Account IDs of the specified owners, amazon for snapshots owned by Amazon or self for snapshots that you own.

If you specify a list of restorable users, only users that have create snapshot permissions for the snapshots are returned. You can specify AWS Account IDs (if you own the snapshot(s)), self for snapshots for which you own or have explicit permissions, or all for public snapshots.

Syntax

ec2-describe-snapshots [snapshot_id ...] [-a] [-o owner ...] [-r user_id]

Options

NameDescriptionRequired

snapshot_id

The ID of the Amazon EBS snapshot.

Type: String

Default: Describes snapshots for which you have launch permissions.

Example: snap-78a54011

No

-o owner

Returns snapshots owned by the specified owner. Multiple owners can be specified.

Type: String

Valid Values: self | amazon | AWS Account ID

Default: None

Example: 218213537122

No

-r user_id

Account ID of a user that can create volumes from the snapshot.

Type: String

Default: None

Example:

No

Output

The command returns a table that contains the following information:

  • SNAPSHOT identifier

  • ID of the snapshot

  • ID of the volume

  • Snapshot state (e.g., pending, completed, error)

  • Time stamp when snapshot initiated

  • Percentage of completion

  • ID of the owner

  • Size of the volume

  • Description

Amazon EC2 displays errors on stderr.

Examples

Example Request

This example describes snapshot snap-78a54011.

PROMPT> ec2-describe-snapshots snap-78a54011
SNAPSHOT snap-7ddb6e14 vol-9539dcfc completed 2009-09-15T22:06 15+0000
							100% 218213537122 1 Daily Backup