]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: fix reconnect behavior from booting state
authorSage Weil <sage@redhat.com>
Mon, 23 Nov 2015 13:38:44 +0000 (08:38 -0500)
committerSage Weil <sage@redhat.com>
Mon, 23 Nov 2015 13:38:44 +0000 (08:38 -0500)
We don't need to restart the boot process unless we are in preboot;
if we are in booting state we just need to resend the boot
message.

Signed-off-by: Sage Weil <sage@redhat.com>
src/osd/OSD.cc

index cc1755a81b28123658b5af7db4bae9894e42b2d4..f891b5eb9e706fdffda7afcdddc1800b9ea597f0 100644 (file)
@@ -4020,7 +4020,6 @@ void OSD::tick()
   if (is_waiting_for_healthy()) {
     if (_is_healthy()) {
       dout(1) << "healthy again, booting" << dendl;
-      set_state(STATE_BOOTING);
       start_boot();
     }
   }
@@ -4409,8 +4408,10 @@ void OSD::ms_handle_connect(Connection *con)
       return;
     dout(10) << "ms_handle_connect on mon" << dendl;
 
-    if (is_preboot() || is_booting()) {
+    if (is_preboot()) {
       start_boot();
+    } else if (is_booting()) {
+      _send_boot();       // resend boot message
     } else {
       utime_t now = ceph_clock_now(NULL);
       last_mon_report = now;