Actions
Bug #1891
closedmonclient: try ipv6 if ipv4 fails
Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
% Done:
0%
Source:
Tags:
Backport:
Regression:
Severity:
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
When a hostname is specified, and it has an A and AAAA record, only the ipv4 address is tried.
If this fails, the ipv6 address should be tried instead. Wido provided a test program:
root@stack01:~# ./rados_over_ipv6 server name not found: ?.F? (Success) rados_connect failed: -22root@stack01:~# c^C root@stack01:~# cat rados_over_ipv6.c #include <stdio.h> #include "rados/librados.h" int main(void) { rados_t cluster; int r; r = rados_create(&cluster, "admin"); if (r < 0) { printf("rados_create failed: %d", r); return -1; } //rados_conf_set(cluster, "auth_supported", "cephx"); rados_conf_set(cluster, "mon_host", "monitor.ceph.widodh.nl"); //rados_conf_set(cluster, "keyring", "/etc/ceph/keyring.bin"); r = rados_connect(cluster); if (r < 0) { printf("rados_connect failed: %d", r); return -2; } rados_shutdown(cluster); } root@stack01:~#
Actions