]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr: update metadata if an osd just joins 33752/head
authorKefu Chai <kchai@redhat.com>
Thu, 5 Mar 2020 15:42:13 +0000 (23:42 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 5 Mar 2020 16:01:45 +0000 (00:01 +0800)
commit73078cf73c3a51f33ecb97eebbb97dbcd4089171
tree98ac0ffa3be4b06f9a9bdd39a3f459a42fd2e285
parente3d3d0501e5095ce557e2e4ccaefc294a7d5c08c
mgr: update metadata if an osd just joins

instead of using "front_address" for checking if we have a new OSD
reusing existing a known identify shows up in the osdmap, it'd be
simpler to compare the up_from epoch with the osdmap's epoch. as
objecter will subscribe **every** osdmap after mgr boots. so mgr
should be able to see the osdmap when the osd joins the cluster
where the up_from epoch is identical to osdmap's epoch.

this way is simpler than existing approach. but it will involve
more overhead if osd reboots frequently without changing their
metadata.

before this change, the metadata is requested/updated only if
the public (front) address is changed.

after this change, the metadata is requested/updated whenever
an osd reboots.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/mgr/Mgr.cc