Bug 2356678 - rgw: tail objects are wrongly deleted in copy_object [NEEDINFO]
Summary: rgw: tail objects are wrongly deleted in copy_object
Keywords:
Status: VERIFIED
Alias: None
Product: Red Hat Ceph Storage
Classification: Red Hat Storage
Component: RGW
Version: 8.0
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: ---
: 8.1
Assignee: J. Eric Ivancich
QA Contact: Madhavi Kasturi
Rivka Pollack
URL:
Whiteboard:
: 2363050 (view as bug list)
Depends On:
Blocks: 2351689 2359825 2366626
TreeView+ depends on / blocked
 
Reported: 2025-04-01 16:25 UTC by Matt Benjamin (redhat)
Modified: 2025-05-27 15:31 UTC (History)
6 users (show)

Fixed In Version: ceph-19.2.1-131.el9cp
Doc Type: Bug Fix
Doc Text:
.Tail objects no longer wrongly deleted with `copy-object` Previously, there was a reference count invariant on tail objects that was not maintained when an object was copied to itself. This caused the existing object was changed, rather than copied. As a result, references to tail objects were being decremented. When the refcount on tail objects dropped to 0, they were deleted during the next garbage collection (GC) cycle. With this fix, the refcount on tail objects is no longer decremented when completing a copy-to-self.
Clone Of:
: 2359825 2366626 (view as bug list)
Environment:
Last Closed:
Embargoed:
tpetr: needinfo? (ivancich)


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Ceph Project Bug Tracker 70746 0 None None None 2025-04-01 16:25:20 UTC
Github ceph ceph pull 62604 0 None open rgw: keep the tails when copying object to itself 2025-04-01 16:26:46 UTC
Red Hat Issue Tracker RHCEPH-11027 0 None None None 2025-04-01 16:25:42 UTC

Description Matt Benjamin (redhat) 2025-04-01 16:25:20 UTC
This happens in both squid and main on objects that are larger enough to have tail rados objects (>4MB).
Reproducer:

    start a vstart cluster
    do the following on client side

    $ s3cmd -c s3cfg.vstart --host=http://localhost:8000 mb s3://bar
    $ s3cmd -c s3cfg.vstart --host=http://localhost:8000 put ../test_files/file_10m s3://bar/file_10m
    $ aws s3api --profile vstart --endpoint=http://localhost:8000 copy-object --copy-source bar/file_10m --key file_10m --bucket bar --metadata-directive "REPLACE" --content-type "text/plain" 

    in vstart

    $ bin/radosgw-admin -n client.rgw.8000 gc process --include-all

    on client side

    $ aws s3api --profile vstart --endpoint=http://localhost:8000 head-object --key file_10m --bucket bar
    {
        "AcceptRanges": "bytes",
        "LastModified": "2025-04-01T13:30:03+00:00",
        "ContentLength": 10485760,
        "ETag": "\"1e1d3a01dfedd497cbdd0ca9a39b1e72-2\"",
        "ContentType": "text/plain",
        "Metadata": {},
        "PartsCount": 2
    }

    $ aws s3api --profile vstart --endpoint=http://localhost:8000 get-object --key file_10m --bucket bar file_10m
    argument of type 'NoneType' is not iterable


    get-object fails with "NoSuchKey".

Comment 5 Tomas Petr 2025-04-30 09:45:05 UTC
*** Bug 2363050 has been marked as a duplicate of this bug. ***


Note You need to log in before you can comment on or make changes to this bug.