Project

General

Profile

Actions

Bug #82194

open
KB KB

osd: an op is answered twice when a read in a CALL fails with EIO and goes to rep_repair_primary_object()

Bug #82194: osd: an op is answered twice when a read in a CALL fails with EIO and goes to rep_repair_primary_object()

Added by Kyle Bader about 1 month ago. Updated 28 days ago.

Status:
Fix Under Review
Priority:
Normal
Assignee:
Category:
Correctness/Safety
Target version:
-
Due date:
% Done:

0%

Source:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(RADOS):
Pull request ID:
Tags (freeform):
Merge Commit:
Fixed In:
Released In:
Upkeep Timestamp:

Description

When a read fails with EIO, PrimaryLogPG::rep_repair_primary_object()
handles it:

A read in the class method of a CALL (cls_cxx_read) does not always
pass the -EAGAIN back to do_osd_ops(). The method can go on, and the op
then ends with another result. On a replica or a shard, execute_ctx()
then sends a second reply for the op. On the primary, the op both waits
for the repair and goes on with its run, which can reply and write.

This was found in a code review.

Fix

  • rep_repair_primary_object() marks the reply as sent, and execute_ctx()
    does not answer an op that has its reply.
  • On the primary, an op that waits for a repair drops the result of its
    run, and a second failed read does not put it in a second wait list.

Affected versions: main

KB Updated by Kyle Bader about 1 month ago Actions #1

  • Pull request ID set to 73177

KC Updated by Kefu Chai about 1 month ago Actions #2

  • Status changed from New to Fix Under Review
  • Assignee set to Kyle Bader

KS Updated by Kamoltat (Junior) Sirivadhna 28 days ago Actions #3

PR under review

Actions

Also available in: PDF Atom