Actions
Bug #6489
closedceph-deploy: get_nonlocal_ip() should filter ipv6 addrs
Status:
Can't reproduce
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
% Done:
0%
Source:
other
Tags:
Backport:
Regression:
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
get_nonlocal_ip isn't prepared to see ipv6 addresses back from getaddrinfo(); although
I haven't reproduced it personally, a user reports that they appear like this:
(10, 1, 6, '', (10, b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00')), (10, 2, 17, '', (10, b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00')), (10, 3, 0, '', (10, b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'))
(note the first number in the tuple is family, and 10 is AF_INET6). The code assumes it
will be seeing IPv4 addrs, which look like
(2, 1, 6, '', ('127.0.0.1', 0))
and so it blindly looks for '127.' at the start of element40. This fails for v6 addrs.
Until we fully implement v6 support, it's probably best to just ignore list entries
with a family of AF_INET6.
Actions