How can I see the size of my buckets?
    • 18 Dec 2023
    • 2 Minutes to read
    • PDF

    How can I see the size of my buckets?

    • PDF

    Article summary

    Bucket sizes are not shown by default in the Management Console. You'll see a table such as this, but no sizes are shown in this view:

    Screen_Shot_2020-03-27_at_4.01.12_PM.png

    Calculating bucket sizes can be a relatively lengthy task depending on the number of objects contained, which might add significant delays to showing the list of buckets. In the console, you can go to the Settings for your bucket to see this. Click on three vertical dots shown in the screenshot and then Settings

    Screen_Shot_2020-03-27_at_4.04.35_PM.png

    Under Properties page, you need to select Bucket Size where you can see this page:

    Screen_Shot_2020-03-27_at_4.03.50_PM.png

    Note that the size is captured daily so check the timestamp there to see when the calculation was made. Here you can also choose to download the daily statistics in a CSV file to show the size over time. There's also a KB article on this How do I interpret the bucket size .csv file and the bucket size info on the Wasabi UI?

    If you need to see the most current size, you will normally use a separate S3 application or command line to show the size of your bucket. Some examples of this are: 

    AWS CLI

    If you have not installed the AWS CLI tool for the system you use on a daily basis, you probably should. See How do I use AWS CLI with Wasabi?. There are lots of helpful commands that can be run here and it's a great "check" to verify information. There are numerous articles and examples of how to use these commands available online. 

    $ aws s3 ls --summarize --human-readable --recursive s3://mikeo-test-overwrite1 --endpoint-url=https://s3.wasabisys.com 
    
    2019-08-30 11:49:41    1.0 MiB SpeedTest_1MB.db
    2019-08-30 11:49:42    1.0 MiB SpeedTest_1MB1.db
    2019-08-30 11:49:43    1.0 MiB SpeedTest_1MB2.db
    Total Objects: 3
       Total Size: 3.0 MiB

     If you have a large number of Objects you can also just grep for the word "Total" and get the final answer: 

    $ aws s3 ls --summarize --human-readable --recursive s3://mikeo-test-overwrite1 --endpoint-url=https://s3.wasabisys.com | grep Total
    Total Objects: 3
     Total Size: 3.0 MiB

    NOTE: See Below for a note on buckets with VERSIONED objects. 

    Wasabi Explorer

    You can consult the KB article, How do I use Wasabi Explorer with Wasabi? for the full details on the application, but if you right click the bucket you want to see, and select Properties... you will get a pop-up box like this, which shows you the Total Size of the bucket:

    mceclip8.png

    S3 Browser

    S3 Browser has a tab below the bucket selection that Calculates the size. 

    mceclip1.png

    Note that Folders work the same way. There is really no such thing as a "folder" in S3 storage. Each object can be marked with a prefix that can associate objects and make it appear to be separated into folders.

    AWS CLI commands for Versioned Buckets

    Remember that the aws cli ls commands are not going to include the versioned objects. You will have to use something like aws s3api list-object-versions to see all of that, then calculate the total from the output. That can be a bit messy, but here's one sample you can try (notice that you need to install the JQ json command line processor to help here, get that installed before you try this)

    aws s3api list-object-versions --endpoint-url=https://s3.us-west-1.wasabisys.com --bucket bucket-just-to-be-deleted-versioned --query 'Versions[*].Size' | jq add | numfmt  --to=iec-i --suffix=B

    That would show something like this:

    mikeo$ aws s3api list-object-versions --endpoint-url=https://s3.us-west-1.wasabisys.com --bucket bucket-just-to-be-deleted-versioned --query 'Versions[*].Size' | jq add | numfmt  --to=iec-i --suffix=B
    21MiB