amazon-web-servicesaws-cliamazon-ebs

How can I find list of AWS EBS volumes in my account that have size >=200GIB using AWS CLI?


I am executing the command below in AWS CLI to find volumes that have size>=200GIB but the command returns nothing. But from the AWS console I can see that few volumes have a size >=200GiB

aws ec2 describe-volumes  --filter "Name=size,Values= >=200GiB"

Solution

  • I think correct format is

    aws ec2 describe-volumes --query "Volumes[?Size > 100].{tag:Tags,ID:VolumeId,size:Size,type:VolumeType}"

    Above command is working at my end