Project

General

Profile

Actions

Bug #38383

closed

compare-and-write skips compare after copyup without object map

Added by Ilya Dryomov about 5 years ago. Updated almost 5 years ago.

Status:
Resolved
Priority:
Urgent
Assignee:
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
luminous,mimic
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

With object map disabled, a copyup turns compare-and-write into an ordinary write. This is because ObjectOperation::cmpext() claims the passed buffer:

... ObjectCompareAndWriteRequest::add_write_ops(), m_cmp_bl is claimed ...
[stat,set-alloc-hint object_size 4194304 write_size 4194304,cmpext 512~96,write 512~512]
... copyup, is_post_copyup_write_required() -> true ...
... ObjectCompareAndWriteRequest::add_write_ops(), m_cmp_bl is empty ...
[stat,set-alloc-hint object_size 4194304 write_size 4194304,cmpext 512~0,write 512~512]

Since there is no data to compare with, nothing is read and cmpext returns success.

This doesn't happen when object map is enabled because we go straight to the copyup step in that case.


Related issues 2 (0 open2 closed)

Copied to rbd - Backport #38440: luminous: compare-and-write skips compare after copyup without object mapResolvedJason DillamanActions
Copied to rbd - Backport #38441: mimic: compare-and-write skips compare after copyup without object mapResolvedJason DillamanActions
Actions #1

Updated by Jason Dillaman about 5 years ago

  • Backport set to luminous,mimic
Actions #2

Updated by Jason Dillaman about 5 years ago

  • Status changed from In Progress to Pending Backport
Actions #4

Updated by Nathan Cutler about 5 years ago

  • Copied to Backport #38440: luminous: compare-and-write skips compare after copyup without object map added
Actions #5

Updated by Nathan Cutler about 5 years ago

  • Copied to Backport #38441: mimic: compare-and-write skips compare after copyup without object map added
Actions #6

Updated by Nathan Cutler almost 5 years ago

  • Pull request ID set to 26519
Actions #7

Updated by Nathan Cutler almost 5 years ago

  • Status changed from Pending Backport to Resolved
Actions

Also available in: Atom PDF