Find Size of Amazon S3 Bucket

From Tech Wiki
Revision as of 19:59, 1 May 2016 by Adam.birds (talk | contribs) (Created page with "'''To find the size of an Amazon S3 Bucket use the following command:''' <pre> aws s3api list-objects --bucket bucketname --output json --query "[sum(Contents[].Size), length...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

To find the size of an Amazon S3 Bucket use the following command:

aws s3api list-objects --bucket bucketname --output json --query "[sum(Contents[].Size), length(Contents[])]"

This requires you to first run:

aws configure

To set up your account credentials with the api.