4

I use the awscli tools to verify the size of my buckets. First the S3 call (all files without versioning, just an ordinary upload):

$ aws s3 ls s3://XXX --recursive --human-readable --summarize (...) Total Objects: 2 Total Size: 82.5 GiB

Then I used the CloudWatch metric: $ aws cloudwatch get-metric-statistics --namespace "AWS/S3" --start-time 2015-08-29 --end-time 2015-08-31 --metric-name BucketSizeBytes --period 3600 --statistics Average --unit Bytes --dimensions Name=BucketName,Value=XXX Name=StorageType,Value=StandardStorage { "Datapoints": [ { "Timestamp": "2015-08-30T00:00:00Z", "Average": 141012339184.0, "Unit": "Bytes" }, (...)

Now I am wondering why CloudWatch shows a much higher number than the S3 call. I couldn't find any hint from the documentation and therefore would be grateful if anybody could help.

(Same numbers are shown in the management console; about 82.5 GiB on the S3 console and 141,012,339,184 bytes on the CloudWatch console.)

krrrcks
  • 71
  • 1
  • 7
  • 1
    Is versioning enabled on the bucket? Is it possible that you have a large number of abandoned multipart upload operations? (They never time out, and consume storage until you complete or abort them). – Michael - sqlbot Aug 30 '15 at 18:07
  • Versioning is disabled. Thanks for the hint conecerning the abandoned multipart uploads operations. I checked this and found some uploads that weren't completed. – krrrcks Aug 31 '15 at 09:36
  • And after aborting them I now get the same result for the usage. Thanks for the hint! – krrrcks Sep 01 '15 at 05:52

1 Answers1

3

Answering my own question with: There were abandonend multipart uploads that were correctly counted in CloudWatch.

krrrcks
  • 71
  • 1
  • 7