Bug #5069
Wrong Pithos quotas when moving objects
Status: | New | Start date: | 02/13/2014 | |
---|---|---|---|---|
Priority: | Medium | Due date: | ||
Assignee: | Sofia Papagiannaki | % Done: | 0% |
|
Category: | - | Spent time: | - | |
Target version: | - |
Description
Quotas are not accounted correctly when moving an object to a path
that another object already exists.
To reproduce:
/images/foo.diskdump (size:100GB)
/pithos/foo.diskdump (size:100GB)
At this point the user is accounted for 200GB.
Moving /images/foo.diskdump to /pithos/foo.diskdump will result
in no change in quotas, which is wrong since the user has now only
100GB.
The solution is when moving an object (source) to a path that
another object already exists (dest), to release the quotas for
dest.
History
#1 Updated by Sofia Papagiannaki about 10 years ago
I provide an example case that reproduces the problem:
$ kamaki file list -C c1
649.62MiB centos-6.0-11-x86_64-2.diskdump
649.62MiB centos-6.0-11-x86_64.diskdump
$ kamaki container info pithos|grep x-container-bytes-used
x-container-bytes-used: 1362354176
$ kamaki sharer info |grep x-account-bytes-used
x-account-bytes-used: 1362354176
$ kamaki file move centos-6.0-11-x86_64-2.diskdump centos-6.0-11-x86_64.diskdump f> /pithos/centos-6.0-11-x86_64.diskdump
move /pithos/centos-6.0-11-x86_64-2.diskdump
-
$ kamaki file list
649.62MiB centos-6.0-11-x86_64.diskdump
$ kamaki container info pithos|grep x-container-bytes-used
x-container-bytes-used: 681177088
$ kamaki sharer info |grep x-account-bytes-used
x-account-bytes-used: 1362354176