Don't bind to ipv4 if prefer-ipv6 is true
Following https://tracker.ceph.com/issues/52867 we need to tell the OSD which address family to use via the ms_bind_ipv4/6 config flags. I added them to the ceph.conf template and updated the config hook. Closes-bug: #2019251 Change-Id: Ifbd59c204a82109e2b71991078f59537f6db42d3
This commit is contained in:
parent
ae6ee7f590
commit
2c8c84fa9d
|
@ -488,6 +488,8 @@ def get_ceph_context(upgrading=False):
|
|||
cephcontext['bdev_discard'] = False
|
||||
|
||||
if config('prefer-ipv6'):
|
||||
cephcontext['ms_bind_ipv4'] = False
|
||||
cephcontext['ms_bind_ipv6'] = True
|
||||
dynamic_ipv6_address = get_ipv6_addr()[0]
|
||||
if not public_network:
|
||||
cephcontext['public_addr'] = dynamic_ipv6_address
|
||||
|
|
|
@ -15,6 +15,12 @@ err to syslog = {{ use_syslog }}
|
|||
clog to syslog = {{ use_syslog }}
|
||||
debug osd = {{ loglevel }}/5
|
||||
|
||||
{% if ms_bind_ipv6 %}
|
||||
ms_bind_ipv6 = true
|
||||
{%- endif %}
|
||||
{%- if ms_bind_ipv4 == false %}
|
||||
ms_bind_ipv4 = false
|
||||
{% endif %}
|
||||
{% if ceph_public_network is string %}
|
||||
public network = {{ ceph_public_network }}
|
||||
{%- endif %}
|
||||
|
|
Loading…
Reference in New Issue