From 8d7ca76182fdc04aaf8b698afbbd2d9b22e07fdc Mon Sep 17 00:00:00 2001 From: "Yan, Zheng" Date: Fri, 7 Sep 2012 13:49:27 +0800 Subject: [PATCH] osd/OSD.cc: Fix typo in OSD::heartbeat_check() The check 'p->second.last_tx > cutoff' should always be false since last_tx is periodically updated by OSD::heartbeat() Signed-off-by: Yan, Zheng Signed-off-by: Sage Weil --- src/osd/OSD.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/osd/OSD.cc b/src/osd/OSD.cc index 79ce18ba73f62..a6e26e7f5364b 100644 --- a/src/osd/OSD.cc +++ b/src/osd/OSD.cc @@ -1841,13 +1841,13 @@ void OSD::heartbeat_check() p != heartbeat_peers.end(); p++) { dout(25) << "heartbeat_check osd." << p->first - << " first_rx " << p->second.first_tx + << " first_tx " << p->second.first_tx << " last_tx " << p->second.last_tx << " last_rx " << p->second.last_rx << dendl; if (p->second.last_rx == utime_t()) { if (p->second.last_tx == utime_t() || - p->second.last_tx > cutoff) + p->second.first_tx > cutoff) continue; // just started sending recently derr << "heartbeat_check: no reply from osd." << p->first << " ever, first ping sent " << p->second.first_tx -- 2.39.5