AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.
ByFilter (Default)
Get-EC2Volume-Filter <Filter[]>-MaxResult <Int32>-NextToken <String>-Select <String>-PassThru <SwitchParameter>-NoAutoIteration <SwitchParameter>ByID
Get-EC2Volume-VolumeId <String[]>-Select <String>-PassThru <SwitchParameter>-NoAutoIteration <SwitchParameter>
MaxResults
parameter sets the maximum number of results returned in a single page. If the list of results exceeds your MaxResults
value, then that number of results is returned along with a NextToken
value that can be passed to a subsequent DescribeVolumes
request to retrieve the remaining results.
For more information about EBS volumes, see Amazon EBS volumes in the Amazon Elastic Compute Cloud User Guide. attachment.attach-time
- The time stamp when the attachment initiated.attachment.delete-on-termination
- Whether the volume is deleted on instance termination.attachment.device
- The device name specified in the block device mapping (for example, /dev/sda1
).attachment.instance-id
- The ID of the instance the volume is attached to.attachment.status
- The attachment state (attaching
| attached
| detaching
).availability-zone
- The Availability Zone in which the volume was created.create-time
- The time stamp when the volume was created.encrypted
- Indicates whether the volume is encrypted (true
| false
)multi-attach-enabled
- Indicates whether the volume is enabled for Multi-Attach (true
| false
)fast-restored
- Indicates whether the volume was created from a snapshot that is enabled for fast snapshot restore (true
| false
).size
- The size of the volume, in GiB.snapshot-id
- The snapshot from which the volume was created.status
- The state of the volume (creating
| available
| in-use
| deleting
| deleted
| error
).tag
:<key> - The key/value combination of a tag assigned to the resource. Use the tag key in the filter name and the tag value as the filter value. For example, to find all resources that have a tag with the key Owner
and the value TeamA
, specify tag:Owner
for the filter name and TeamA
for the filter value.tag-key
- The key of a tag assigned to the resource. Use this filter to find all resources assigned a tag with a specific key, regardless of the tag value.volume-id
- The volume ID.volume-type
- The Amazon EBS volume type (gp2
| gp3
| io1
| io2
| st1
| sc1
| standard
)Required? | False |
Position? | 2 |
Accept pipeline input? | True (ByPropertyName) |
Aliases | Filters |
DescribeVolumes
in paginated output. When this parameter is used, DescribeVolumes
only returns MaxResults
results in a single page along with a NextToken
response element. The remaining results of the initial request can be seen by sending another DescribeVolumes
request with the returned NextToken
value. This value can be between 5 and 500; if MaxResults
is given a value larger than 500, only 500 results are returned. If this parameter is not used, then DescribeVolumes
returns all results. You cannot specify this parameter and the volume IDs parameter in the same request.Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | MaxItems, MaxResults |
NextToken
value returned from a previous paginated DescribeVolumes
request where MaxResults
was used and the results exceeded the value of that parameter. Pagination continues from the end of the previous results that returned the NextToken
value. This value is null
when there are no more results to return.Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | 1 |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Aliases | VolumeIds |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | AK |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByValue, ByPropertyName) |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | AWSProfilesLocation, ProfilesLocation |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | StoredCredentials, AWSProfileName |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | RegionToCall |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | SK, SecretAccessKey |
Required? | False |
Position? | Named |
Accept pipeline input? | True (ByPropertyName) |
Aliases | ST |
Get-EC2Volume -VolumeId vol-12345678
Attachments : {}
AvailabilityZone : us-west-2c
CreateTime : 7/17/2015 4:35:19 PM
Encrypted : False
Iops : 90
KmsKeyId :
Size : 30
SnapshotId : snap-12345678
State : in-use
Tags : {}
VolumeId : vol-12345678
VolumeType : standardThis example describes the specified EBS volume.
Get-EC2Volume -Filter @{ Name="status"; Values="available" }
Attachments : {}
AvailabilityZone : us-west-2c
CreateTime : 12/21/2015 2:31:29 PM
Encrypted : False
Iops : 60
KmsKeyId :
Size : 20
SnapshotId : snap-12345678
State : available
Tags : {}
VolumeId : vol-12345678
VolumeType : gp2
...
This example describes your EBS volumes that have the status 'available'.
Get-EC2VolumeThis example describes all your EBS volumes.
AWS Tools for PowerShell: 2.x.y.z