]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
osd/ECBackend: preserve requests for other objects when sending extra reads
authorJosh Durgin <jdurgin@redhat.com>
Fri, 20 Apr 2018 22:42:56 +0000 (18:42 -0400)
committerJosh Durgin <jdurgin@redhat.com>
Fri, 20 Apr 2018 23:42:15 +0000 (19:42 -0400)
commitd4808256d25851f85ce5e86704cc4e867e2fc905
treeb56bed6900e00c3e87dd217910cca6d4aa6e0a14
parentb162a5478d6a907cc0a9ddd5ae8442e81f8d8fb3
osd/ECBackend: preserve requests for other objects when sending extra reads

When multiple objects are in flight for the same ReadOp, swap() on the
map<hobject_t, read_request_t> would remove requests for all objects.

We just want to replace the requests for the single object we're
dealing with in send_all_remaining_reads().

This prevents crashing trying to look up rop.to_read[hoid] when another
object in the same ReadOp gets an EIO and tries to send more requests.

Test this by using osd-recovery-max-single-start to bundle multiple
reads into one ReadOp. Save and restore CEPH_ARGS so custom settings
are reset for each test.

Fixes: http://tracker.ceph.com/issues/23195 (the 2nd crash there)
Signed-off-by: Josh Durgin <jdurgin@redhat.com>
qa/standalone/erasure-code/test-erasure-eio.sh
src/osd/ECBackend.cc