Project

General

Profile

Actions

Bug #55669

open

osd: add log for pg peering and activiting complete

Added by jianwei zhang almost 2 years ago. Updated almost 2 years ago.

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

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
rados
Component(RADOS):
OSD
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

    osd: add log for pg peering and activiting complete

    This log is added to PeeringState::Active::react(const AllReplicasActivated &evt)
    to pair with the PeeringState::start_peering_interval() log,
    So that under the default log level of debug_osd(1/5),
    the completion of each pg peering can be traced back through ceph-osd.x.log

    Because under some exceptions, we need to know clearly
    whether pg has completed peering at the time when the exception occurs,
    and whether it can handle client IO.

    Signed-off-by: Jianwei Zhang <jianwei1216@qq.com>

PeeringState::start_peering_interval()   ///This is the log of the original pg peering start
{
  psdout(1) << __func__ << " up " << oldup << " -> " << up
        << ", acting " << oldacting << " -> " << acting
        << ", acting_primary " << old_acting_primary << " -> " 
        << new_acting_primary
        << ", up_primary " << old_up_primary << " -> " << new_up_primary
        << ", role " << oldrole << " -> " << role
        << ", features acting " << acting_features
        << " upacting " << upacting_features
        << dendl;
}

PeeringState::Active::react(const AllReplicasActivated &evt)  ///This is the log of the newly added pg peering->activating->active end
{
  psdout(1) << __func__ << " AllReplicasActivated : Peering->Activating->Active over" 
        << " PG_STATE_ACTIVE=" << ps->state_test(PG_STATE_ACTIVE)
        << " PG_STATE_WAIT=" << ps->state_test(PG_STATE_WAIT)
        << " PG_STATE_PEERED=" << ps->state_test(PG_STATE_PEERED)
        << " last_epoch_started=" << ps->info.last_epoch_started
        <<dendl;
}

The purpose of adding this part of the log: it is convenient to locate the log time from the start to the end of a single pg peering

Actions #2

Updated by Radoslaw Zarzynski almost 2 years ago

  • Pull request ID set to 46279
Actions

Also available in: Atom PDF