]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr: update metadata if an osd just joins 33834/head
authorKefu Chai <kchai@redhat.com>
Thu, 5 Mar 2020 15:42:13 +0000 (23:42 +0800)
committerKefu Chai <kchai@redhat.com>
Tue, 10 Mar 2020 05:03:11 +0000 (13:03 +0800)
commit861930c64ca060a74d5db541a451decf838ba93b
tree130cdfb94cf3c19bab56a5beb16b73da8f3de2ed
parenta0400ae703c738a04906e7fd35f040eacb787249
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>
(cherry picked from commit 73078cf73c3a51f33ecb97eebbb97dbcd4089171)

Conflicts:
src/mgr/Mgr.cc: trivial resolution
src/mgr/Mgr.cc