AWS S3: how do I see how much disk space is using

前端 未结 18 1377
被撕碎了的回忆
被撕碎了的回忆 2020-12-12 10:33

I have AWS account. I\'m using S3 to store backups from different servers. The question is there any information in the AWS console about how much disk space is in use in my

18条回答
  •  生来不讨喜
    2020-12-12 10:44

    Yippe - an update to AWS CLI allows you to recursively ls through buckets...

    aws s3 ls s3:// --recursive  | grep -v -E "(Bucket: |Prefix: |LastWriteTime|^$|--)" | awk 'BEGIN {total=0}{total+=$3}END{print total/1024/1024" MB"}'
    

提交回复
热议问题