Project

General

Profile

Actions

Bug #52781

closed

shard-threads cannot wakeup bug

Added by jianwei zhang over 2 years ago. Updated 5 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
-
Target version:
-
% Done:

100%

Source:
Tags:
backport_processed
Backport:
octopus, pacific
Regression:
No
Severity:
3 - minor
Reviewed:
09/30/2021
Affected Versions:
ceph-qa-suite:
Component(RADOS):
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

osd: fix shard-threads cannot wakeup bug

Reproduce:
(1) ceph cluster not running any client IO
(2) only ceph osd in osd.14 operation

Reason:
(1) one shard-queue has three shard-threads
(2) one or some PeeringOp's epoch > osdmap's epoch held by current osd,
and these PeeringOp _add_slot_waiter()
(3) shard-queue become empty and three shard-threads cond.wait()
(4) new osdmap consume and it _wake_pg_slot()
Problem in here
1> OSDShard::consume() exec loop all pg's slot wait
and requeue more than one PeeringOp to shard-queue
2> but it only notify one shard-thread to wakeup,
the other two shard-threads continue cond.wait()
3> OSD::ShardedOpWQ::_enqueue() found the shard-queue not empty
and not notify all shard-thread to wakeup

In a period of time, only one shard-thread of 3 shard-threads is running.

Related issues 2 (0 open2 closed)

Copied to RADOS - Backport #52840: octopus: shard-threads cannot wakeup bug RejectedActions
Copied to RADOS - Backport #52841: pacific: shard-threads cannot wakeup bug ResolvedKonstantin ShalyginActions
Actions #2

Updated by Neha Ojha over 2 years ago

  • Project changed from Ceph to RADOS
  • Category deleted (OSD)
Actions #3

Updated by Kefu Chai over 2 years ago

  • Status changed from New to Fix Under Review
  • Pull request ID set to 43360
Actions #4

Updated by Kefu Chai over 2 years ago

  • Status changed from Fix Under Review to Pending Backport
  • Backport set to octopus, pacific
Actions #5

Updated by Backport Bot over 2 years ago

  • Copied to Backport #52840: octopus: shard-threads cannot wakeup bug added
Actions #6

Updated by Backport Bot over 2 years ago

  • Copied to Backport #52841: pacific: shard-threads cannot wakeup bug added
Actions #7

Updated by Loïc Dachary over 2 years ago

  • Target version deleted (v15.2.15)
Actions #8

Updated by Backport Bot over 1 year ago

  • Tags set to backport_processed
Actions #9

Updated by Konstantin Shalygin 5 months ago

  • Status changed from Pending Backport to Resolved
  • Assignee set to jianwei zhang
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF