diff --git a/PendingReleaseNotes b/PendingReleaseNotes index 15b212da2fe90..65347cc2b263e 100644 --- a/PendingReleaseNotes +++ b/PendingReleaseNotes @@ -1,7 +1,16 @@ 12.0.0 ------ - * Some varients of the omap_get_keys and omap_get_vals librados + * When assigning a network to the public network and not to + the cluster network the network specification of the public + network will be used for the cluster network as well. + In older versions this would lead to cluster services + being bound to 0.0.0.0:, thus making the + cluster service even more publicly available than the + public services. When only specifying a cluster network it + will still result in the public services binding to 0.0.0.0. + +* Some variants of the omap_get_keys and omap_get_vals librados functions have been deprecated in favor of omap_get_vals2 and omap_get_keys2. The new methods include an output argument indicating whether there are additional keys left to fetch. diff --git a/src/common/pick_address.cc b/src/common/pick_address.cc index a47a1d946a4cc..ebce2d553d718 100644 --- a/src/common/pick_address.cc +++ b/src/common/pick_address.cc @@ -112,6 +112,7 @@ void pick_addresses(CephContext *cct, int needs) exit(1); } + if ((needs & CEPH_PICK_ADDRESS_PUBLIC) && cct->_conf->public_addr.is_blank_ip() && !cct->_conf->public_network.empty()) { @@ -119,9 +120,16 @@ void pick_addresses(CephContext *cct, int needs) } if ((needs & CEPH_PICK_ADDRESS_CLUSTER) - && cct->_conf->cluster_addr.is_blank_ip() - && !cct->_conf->cluster_network.empty()) { - fill_in_one_address(cct, ifa, cct->_conf->cluster_network, "cluster_addr"); + && cct->_conf->cluster_addr.is_blank_ip()) { + if (!cct->_conf->cluster_network.empty()) { + fill_in_one_address(cct, ifa, cct->_conf->cluster_network, "cluster_addr"); + } else { + if (!cct->_conf->public_network.empty()) { + lderr(cct) << "Public network was set, but cluster network was not set " << dendl; + lderr(cct) << " Using public network also for cluster network" << dendl; + fill_in_one_address(cct, ifa, cct->_conf->public_network, "cluster_addr"); + } + } } freeifaddrs(ifa);