mirror of
https://github.com/ceph/ceph
synced 2024-12-21 02:42:48 +00:00
Merge pull request #19550 from dillaman/wip-22461
rbd-mirror: cluster watcher should ensure it has latest OSD map Reviewed-by: Mykola Golub <to.my.trociny@gmail.com>
This commit is contained in:
commit
43b88419d4
@ -57,8 +57,14 @@ void ClusterWatcher::refresh_pools()
|
||||
void ClusterWatcher::read_pool_peers(PoolPeers *pool_peers,
|
||||
PoolNames *pool_names)
|
||||
{
|
||||
int r = m_cluster->wait_for_latest_osdmap();
|
||||
if (r < 0) {
|
||||
derr << "error waiting for OSD map: " << cpp_strerror(r) << dendl;
|
||||
return;
|
||||
}
|
||||
|
||||
list<pair<int64_t, string> > pools;
|
||||
int r = m_cluster->pool_list2(pools);
|
||||
r = m_cluster->pool_list2(pools);
|
||||
if (r < 0) {
|
||||
derr << "error listing pools: " << cpp_strerror(r) << dendl;
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user