Project

General

Profile

Bug #43066

copy object (key) overhead user quota and bucket quota

Added by hoan nv 3 months ago. Updated 11 days ago.

Status:
Triaged
Priority:
Normal
Target version:
-
% Done:

0%

Source:
Tags:
quota
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
upgrade/mimic-p2p
Pull request ID:
Crash signature:

Description

Hi all.

Currently i upload a file to bucket which has quota

"user_quota": {
        "enabled": true,
        "check_on_raw": false,
        "max_size": 10737418240,
        "max_size_kb": 10485760,
        "max_objects": -1
    },

current usage

"rgw.main": {
            "size": 18431279469,
            "size_actual": 18431307776,
            "size_utilized": 18431279469,
            "size_kb": 17999297,
            "size_kb_actual": 17999324,
            "size_kb_utilized": 17999297,
            "num_objects": 9
        },

after copy file to same bucket

"rgw.main": {
            "size": 20735185956,
            "size_actual": 20735217664,
            "size_utilized": 20735185956,
            "size_kb": 20249206,
            "size_kb_actual": 20249236,
            "size_kb_utilized": 20249206,
            "num_objects": 10
        },

Thanks.

History

#1 Updated by Casey Bodley 2 months ago

  • Assignee set to Daniel Gryniewicz

#2 Updated by Daniel Gryniewicz 2 months ago

  • Status changed from New to Need More Info
  • Assignee deleted (Daniel Gryniewicz)

Can you be more specific about what OP you're running? The info you gave is a bit confusing, and I'm not sure exactly what's going on. Did you mean to paste a bucket quota rather than a user quota?

#3 Updated by hoan nv 2 months ago

Daniel Gryniewicz wrote:

Can you be more specific about what OP you're running? The info you gave is a bit confusing, and I'm not sure exactly what's going on. Did you mean to paste a bucket quota rather than a user quota?

I set user quota to to test user with max-size option : "max_size": 10737418240, but i can copy many objects. Total size of user bigger than user and bucket quota.

I thinks it can fix with add this code to function : void RGWCopyObj::execute() on rgw_op.cc file

```
op_ret = store->check_quota(dest_bucket_info.owner.id, dest_bucket,
user_quota, bucket_quota, s->content_length);
if (op_ret < 0) {
ldpp_dout(this, 20) << "check_quota() returned ret=" << op_ret << dendl;
return;
}
op_ret = store->check_bucket_shards(dest_bucket_info, dest_bucket, bucket_quota);
if (op_ret < 0) {
ldpp_dout(this, 20) << "check_bucket_shards() returned ret=" << op_ret << dendl;
return;
}

```

#4 Updated by Casey Bodley about 1 month ago

  • Status changed from Need More Info to New
  • Tags set to quota

#5 Updated by Casey Bodley about 1 month ago

  • Status changed from New to Triaged

#6 Updated by Casey Bodley 11 days ago

  • Assignee set to Daniel Gryniewicz

Also available in: Atom PDF