Commit 152e4e0c authored by Thomas Gambier's avatar Thomas Gambier

software/kvm: disabe IPv6 on ens3 if there is IPv6 on ens4

If there is IPv6 on both interface, Linux will put a default route on
ens3 preventing IPv6 to work correctly on ens4.
Even disabling totally IPv6 from inside the host on ens3 may not work.
It is safer to disable it from qemu process directly. Also, it will ease
the configuration of the host.
parent 318a6185
Pipeline #7610 passed with stage
......@@ -19,7 +19,7 @@ md5sum = a236b719aaac61ac342ada0ce569151a
[template-kvm]
filename = instance-kvm.cfg.jinja2
md5sum = 821ac8d663a4b5a9e7a24c84cdaba102
md5sum = 891d98667feb8daaa9f61b5bf09d5de0
[template-kvm-cluster]
filename = instance-kvm-cluster.cfg.jinja2.in
......@@ -55,7 +55,7 @@ md5sum = 2036bf145f472f62ef8dee5e729328fd
[template-kvm-run]
filename = template/template-kvm-run.in
md5sum = 71e0c6c8a0b9a46498f25b67a3ab6894
md5sum = 08af4ed0e2a53e76c844e3d7325aac09
[template-kvm-controller]
filename = template/kvm-controller-run.in
......
......@@ -88,6 +88,7 @@ nbd2-host = ${slap-parameter:nbd2-host}
nbd2-port = ${slap-parameter:nbd2-port}
tap-interface = {{ slap_configuration.get('tap-name', '') }}
tap-ipv6-addr = {{ slap_configuration.get('tap-ipv6-addr', '') }}
disk-size = ${slap-parameter:disk-size}
disk-type = ${slap-parameter:disk-type}
......
......@@ -44,6 +44,7 @@ tap_interface = '{{ parameter_dict.get("tap-interface") }}'
listen_ip = '{{ parameter_dict.get("ipv4") }}'
mac_address = '{{ parameter_dict.get("mac-address") }}'
tap_mac_address = '{{ parameter_dict.get("tap-mac-address") }}'
tap_ipv6_addr = '{{ parameter_dict.get("tap-ipv6-addr") }}'
numa_list = '{{ parameter_dict.get("numa", "") }}'.split()
ram_size = {{ parameter_dict.get("ram-size") }}
ram_max_size = '{{ parameter_dict.get("ram-max-size") }}'
......@@ -278,6 +279,8 @@ if use_nat == 'true':
cluster_doc_host, cluster_doc_port)
if set_nat_restrict == 'true':
rules += ',restrict=on'
if use_tap == 'true' and tap_ipv6_addr != '':
rules += ',ipv6=off'
nat_network_parameter = ['-netdev', rules,
'-device', 'virtio-net-pci,netdev=lan%s,mac=%s' % (number, mac_address)]
if use_tap == 'true':
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment