Skip to content

Commit

Permalink
Merge pull request #12623 from LiumxNL/fix-boot-epoch
Browse files Browse the repository at this point in the history
osd: correct epoch setting of osd boot msg

Reviewed-by: Kefu Chai <kchai@redhat.com>
  • Loading branch information
yuriw committed Feb 21, 2017
2 parents d0c5df3 + f5aa393 commit 9d295f7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/messages/MOSDBoot.h
Expand Up @@ -37,12 +37,12 @@ class MOSDBoot : public PaxosServiceMessage {
: PaxosServiceMessage(MSG_OSD_BOOT, 0, HEAD_VERSION, COMPAT_VERSION),
boot_epoch(0), osd_features(0)
{ }
MOSDBoot(OSDSuperblock& s, epoch_t be,
MOSDBoot(OSDSuperblock& s, epoch_t e, epoch_t be,
const entity_addr_t& hb_back_addr_ref,
const entity_addr_t& hb_front_addr_ref,
const entity_addr_t& cluster_addr_ref,
uint64_t feat)
: PaxosServiceMessage(MSG_OSD_BOOT, s.current_epoch, HEAD_VERSION, COMPAT_VERSION),
: PaxosServiceMessage(MSG_OSD_BOOT, e, HEAD_VERSION, COMPAT_VERSION),
sb(s),
hb_back_addr(hb_back_addr_ref),
hb_front_addr(hb_front_addr_ref),
Expand Down
2 changes: 1 addition & 1 deletion src/osd/OSD.cc
Expand Up @@ -5152,7 +5152,7 @@ void OSD::_send_boot()
hb_front_server_messenger->ms_deliver_handle_fast_connect(local_connection);
}

MOSDBoot *mboot = new MOSDBoot(superblock, service.get_boot_epoch(),
MOSDBoot *mboot = new MOSDBoot(superblock, get_osdmap_epoch(), service.get_boot_epoch(),
hb_back_addr, hb_front_addr, cluster_addr,
CEPH_FEATURES_ALL);
dout(10) << " client_addr " << client_messenger->get_myaddr()
Expand Down

0 comments on commit 9d295f7

Please sign in to comment.