Bug 1678871

Summary: Fix issue with concurrent operations on versioned objects
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: Casey Bodley <cbodley>
Component: RGWAssignee: Casey Bodley <cbodley>
Status: CLOSED ERRATA QA Contact: ceph-qe-bugs <ceph-qe-bugs>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 3.2CC: cbodley, ceph-eng-bugs, kbader, mbenjamin, sweil, tchandra, tserlin, vumrao
Target Milestone: z1Keywords: CodeChange
Target Release: 3.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: RHEL: ceph-12.2.8-84.el7cp Ubuntu: ceph_12.2.8-70redhat1xenial Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1690934 (view as bug list) Environment:
Last Closed: 2019-03-07 15:51:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1690934    

Description Casey Bodley 2019-02-19 18:59:07 UTC
Description of problem:

Part of the algorithm for versioned object mutation was not implemented, so there was a missing check that was intended to protect concurrent operations on a single object name from racing.


Version-Release number of selected component (if applicable): RHCS 3.2 and previous


How reproducible: Very very rarely


Steps to Reproduce:

1. Create a bucket 'bucket' and enable versioning

2. Upload an object with name 'obj'

3. Upload two more copies of 'obj' in parallel

4. Read the 'current version' according to the bucket index:
> $ radosgw-admin bi get --bucket bucket --object obj --index-type olh | grep instance
>             "instance": "dVvF5V4IKx4g7y06YC76.63ieQSyyDv"

5. Read the 'current version' according to a HEAD request on obj:
> $ s3cmd info s3://bucket/asd --debug 2> >(grep x-amz-version-id) >/dev/null
>              'x-amz-version-id': 'dVvF5V4IKx4g7y06YC76.63ieQSyyDv'},

Actual results:

The bucket index and head object may disagree about the current version id.


Expected results:

The bucket index and head object should always agree about the current version id.


Additional info:

There are several test cases in s3-tests that test concurrent updates of versioned objects, but they very rarely fail due to this issue.

Comment 6 errata-xmlrpc 2019-03-07 15:51:42 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:0475