]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
monc: set "hunting" to true when we reopen the mon session
authorGreg Farnum <greg@inktank.com>
Wed, 12 Feb 2014 21:37:50 +0000 (13:37 -0800)
committerGreg Farnum <greg@inktank.com>
Thu, 13 Feb 2014 21:20:52 +0000 (13:20 -0800)
If we don't have a connecton to a monitor, we want to retry to another
monitor regardless of whether it's the first time or not.

Signed-off-by: Greg Farnum <greg@inktank.com>
src/mon/MonClient.cc

index c1403d58db16e413ed50f7d91a4640fb6197ceea..3149290ede1b71b4004fdebb15864b6b46a6e3bf 100644 (file)
@@ -615,6 +615,7 @@ void MonClient::_reopen_session(int rank, string name)
 
   // restart authentication handshake
   state = MC_STATE_NEGOTIATING;
+  hunting = true;
 
   MAuth *m = new MAuth;
   m->protocol = 0;
@@ -645,7 +646,6 @@ bool MonClient::ms_handle_reset(Connection *con)
        return true;
       
       ldout(cct, 0) << "hunting for new mon" << dendl;
-      hunting = true;
       _reopen_session();
     }
   }