]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
common/ip_addr: do not support numa preference if WITH_SEASTAR
authorKefu Chai <kchai@redhat.com>
Mon, 14 Jan 2019 10:08:03 +0000 (18:08 +0800)
committerYingxin Cheng <yingxincheng@gmail.com>
Tue, 15 Jan 2019 04:05:47 +0000 (12:05 +0800)
in pick_address.cc, set_val_or_die() is called to set the "public_addr"
and/or "cluster_addr". but since the sharded ConfigProxy cannot
set_val_or_die() synchronously, we cannot do it this way.

we need to fix pick_addresses() so it works with seastar later. either
by making the involved function return future<>, or making the set_val()
call non-blocking or synchronous if we can go with 1:1 mapping
threading model.

but at this moment, let's just disable this feature in crimson-osd.

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

index bceb32578af15a31c7e16a9e5b5347acc31bb195..debf4ba2b2aa672cffe6361784bd161f488ae055 100644 (file)
@@ -31,12 +31,16 @@ void netmask_ipv4(const struct in_addr *addr,
 
 static bool match_numa_node(const string& if_name, int numa_node)
 {
+#ifdef WITH_SEASTAR
+  return true;
+#else
   int if_node = -1;
   int r = get_iface_numa_node(if_name, &if_node);
   if (r < 0) {
     return false;
   }
   return if_node == numa_node;
+#endif
 }
 
 const struct ifaddrs *find_ipv4_in_subnet(const struct ifaddrs *addrs,