Skip to content

Commit

Permalink
osd: log 'slow op' debug messages for individual slow ops
Browse files Browse the repository at this point in the history
Otherwise it is very hard to identify which OSD ops are slow when we've
seen a SLOW_OPS health warning in a qa run.

Notably, without this, bugs like http://tracker.ceph.com/issues/23769
are very challenging to track down.

Signed-off-by: Sage Weil <sage@redhat.com>
  • Loading branch information
liewegas committed Apr 27, 2018
1 parent 510762f commit bab689c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/osd/OSD.cc
Expand Up @@ -7010,6 +7010,9 @@ vector<DaemonHealthMetric> OSD::get_health_metrics()
int slow = 0;
auto count_slow_ops = [&](TrackedOp& op) {
if (op.get_initiated() < too_old) {
lgeneric_subdout(cct,osd,20) << "slow op " << op.get_desc()
<< " initiated "
<< op.get_initiated() << dendl;
slow++;
return true;
} else {
Expand Down

0 comments on commit bab689c

Please sign in to comment.