Bug #23674
can't remove rados objects after copy rgw-object fail
0%
Description
In copy rgw-object, rgw will increate rados objects refcount by using cls_refcount_get, and the ref_tag include '\0', see rgw_rados.cc::RGWRados::copy_obj() { ...ref_tag = tag + '\0'; cls_refcount_get(op, ref_tag, true);...}.
And rgw will rollback reference by using cls_refcount_put if the next operation fail, but the ref_tag does not include '\0', see rgw_rados.cc::RGWRados::copy_obj() { ...done_ret:...cls_refcount_put(op, tag, true);...}, so the cls_refcount_put has no effect, the rados object refcount will not decrease, and the rados object will not be removed even if the souce rgw-object be removed.
Related issues
History
#1 Updated by long li almost 6 years ago
I pulled requests in github(https://github.com/ceph/ceph/pull/20790,https://github.com/ceph/ceph/pull/20789), but I am not familiar with github, so I don't know how to deal this issue, I hope someone else can deal this issue, thank you.
#2 Updated by Nathan Cutler almost 6 years ago
- Backport set to luminous
#3 Updated by Nathan Cutler almost 6 years ago
- Status changed from New to Fix Under Review
#4 Updated by Nathan Cutler almost 6 years ago
- Assignee set to long li
#5 Updated by J. Eric Ivancich over 4 years ago
- Pull request ID set to 20790
#6 Updated by J. Eric Ivancich over 4 years ago
- Target version changed from v12.2.5 to v15.0.0
- Backport changed from luminous to nautilus,mimic,luminous
#7 Updated by J. Eric Ivancich over 4 years ago
- Pull request ID changed from 20790 to 30013
The PR was replaced to one where each commit is signed-off and formatting issues are resolved.
#8 Updated by J. Eric Ivancich over 4 years ago
- Status changed from Fix Under Review to Pending Backport
#9 Updated by Nathan Cutler over 4 years ago
- Copied to Backport #41713: luminous: can't remove rados objects after copy rgw-object fail added
#10 Updated by Nathan Cutler over 4 years ago
- Copied to Backport #41714: nautilus: can't remove rados objects after copy rgw-object fail added
#11 Updated by Nathan Cutler over 4 years ago
- Copied to Backport #41715: mimic: can't remove rados objects after copy rgw-object fail added
#12 Updated by Nathan Cutler about 4 years ago
- Status changed from Pending Backport to Resolved
While running with --resolve-parent, the script "backport-create-issue" noticed that all backports of this issue are in status "Resolved" or "Rejected".