seastar: dns fails due to ECONNREFUSED with c-ares 1.33 and up
in c-ares 1.33, it introduced DNS cookie support, which tracks the local ip in server_connection::self_ip when a socket is created. but in seastar, what we return to c-ares is an index into dns_resolver::impl::_sockets, and the underlying socket is hidden underneath of posix_connected_socket_impl. see https://github.com/c-ares/c-ares/blob/759343ae00bd0dd562f4469ef030a71264ed543e/src/lib/ares_conn.c#L144-L154
so when c-ares tries to retrieve the socket’s local address in ares_conn_set_self_ip() , getsockname() fails with ENOTSOCK, and ares_conn_set_self_ip() returns ARES_ECONNREFUSED in this case.
please note, fedora 41 comes with c-ares 1.33.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 16 (13 by maintainers)
Commits related to this issue
- build: do not support c-ares >= 1.33 we don't support c-ares yet. so error out when c-ares >= 1.33 is detected. Refs #2472 Signed-off-by: Kefu Chai <kefu.chai@scylladb.com> — committed to tchaikov/seastar by tchaikov 2 years ago
- build: do not support c-ares >= 1.33 we don't support c-ares >= 1.33 yet. so error out when c-ares >= 1.33 is detected. Refs #2472 Signed-off-by: Kefu Chai <kefu.chai@scylladb.com> — committed to tchaikov/seastar by tchaikov 2 years ago
- build: do not support c-ares >= 1.33 we don't support c-ares >= 1.33 yet. so error out when c-ares >= 1.33 is detected. Refs #2472 Signed-off-by: Kefu Chai <kefu.chai@scylladb.com> — committed to scylladb/seastar by tchaikov 2 years ago
- build: support c-ares >= 1.34.1 in c-ares 1.34.0, it addressed a regression with custom socket callbacks due to DNS cookie support. because 1.34.0's release tarball failed to include some header file... — committed to tchaikov/seastar by tchaikov 2 years ago
- build: support c-ares >= 1.34.1 in c-ares 1.34.0, it addressed a regression with custom socket callbacks due to DNS cookie support. because 1.34.0's release tarball failed to include some header file... — committed to tchaikov/seastar by tchaikov 2 years ago
- build: support c-ares >= 1.34.1 in c-ares 1.34.0, it addressed a regression with custom socket callbacks due to DNS cookie support. because 1.34.0's release tarball failed to include some header file... — committed to tchaikov/seastar by tchaikov 2 years ago
- build: support c-ares >= 1.34.1 in c-ares 1.34.0, it addressed a regression with custom socket callbacks due to DNS cookie support. because 1.34.0's release tarball failed to include some header file... — committed to scylladb/seastar by tchaikov 2 years ago
manpage updated here: https://c-ares.org/docs/ares_set_socket_functions_ex.html