Project

General

Profile

Bug #1338

osd: scrub should account for clone_range

Added by Greg Farnum over 8 years ago. Updated over 8 years ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Category:
OSD
Target version:
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature:

Description

Right now scrub doesn't account for clone_range. This means that if any of the objects have been cloned, the size summation (created by simply adding up the size of each object) will not match the calculated PG stats (which attempt to account for clone_range, although they're not always right). We should adjust the scrub code to account for this difference and handle it without increasing the error count or warning users.

History

#1 Updated by Sage Weil over 8 years ago

  • translation missing: en.field_position set to 772

#2 Updated by Sage Weil over 8 years ago

  • translation missing: en.field_position deleted (772)
  • translation missing: en.field_position set to 33

#3 Updated by Greg Farnum over 8 years ago

  • Status changed from New to Rejected

Looks like it already does this, actually:

// subtract off any clone overlap
for (map<snapid_t,interval_set<uint64_t> >::iterator q = snapset.clone_overlap.begin();
    q != snapset.clone_overlap.end();
    ++q) {
    for (interval_set<uint64_t>::const_iterator r = q->second.begin();
        r != q->second.end();
        ++r) {
        stat.num_bytes -= r.get_len();
        stat.num_kb -= SHIFT_ROUND_UP(r.get_start()+r.get_len(), 10) - (r.get_start() >> 10);
        }      
    }
}

Also available in: Atom PDF