nova does not inject IPv6 address

Bug #1824807 reported by Andrii Yaurov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mirantis OpenStack
Invalid
High
Roman Lubianyi

Bug Description

Detailed bug description:
Nova does not inject the IPv6 addresses into the VM,
network_data.json does not provide information about ipv6 addresses.

The bug is observed in MOS 9.0

Steps to reproduce:
1)Create dual stack network with dhcp disabled
2)neutron port created with fixed ip address for ipv4 and ipv6
3)nova boot with above port
4)mount the config drive,check for network_data
Result:only ipv4 addresses are present
Attached execution steps.
(in the attached steps, as vm is not having serial console , so had created ipv4 with dhcp enabled and ipv6
with dhcp disabled.)
Login to vm:
ubuntu@testdummyvm:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
link/ether fa:16:3e:a3:8a:84 brd ff:ff:ff:ff:ff:ff
inet 19.9.0.9/24 brd 19.9.0.255 scope global dynamic ens3
valid_lft 86212sec preferred_lft 86212sec
inet6 fe80::f816:3eff:fea3:8a84/64 scope link
valid_lft forever preferred_lft forever
ubuntu@testdummyvm:~$ sudo su
root@testdummyvm:/home/ubuntu# mount /dev/disk/by-label/config-2 /mnt/
mount: /mnt: WARNING: device write-protected, mounted read-only.
root@testdummyvm:/home/ubuntu# cat /mnt/openstack/latest/network_data.json | python3 -m json.tool
{
"services": [],
"networks": [
{
"network_id": "5eb2e6a3-b031-4c95-ab12-66fc654e89f6",
"link": "tap197667d9-13",
"type": "ipv4_dhcp",
"id": "network0"
}
],
"links": [
{
"ethernet_mac_address": "fa:16:3e:a3:8a:84",
"mtu": 1500,
"type": "vhostuser",
"id": "tap197667d9-13",
"vif_id": "197667d9-1345-41de-b5ee-528cf4f6c95f"
}
]
}

Workaround:
use_ipv6=true must be set in nova.conf. The following patch seems to fix the metadata injection:
https://github.com/openstack/nova/commit/c0aef97c49781f2ce0aa93fd33bfac7e68ea5b97#diff-083754c4012f16fa0f9dd9cd703ee0c1

Changed in mos:
milestone: none → 9.2-mu-12
assignee: nobody → Roman Lubianyi (rlubianyi)
importance: Undecided → High
status: New → Confirmed
Revision history for this message
Roman Lubianyi (rlubianyi) wrote :

I have tested this behavior in my environment, and confirm that network_data.json contains IP address for ipv6 only when use_ipv6=true option enabled. According to the code comments, this feature does what it has to do: ":param use_ipv6: If False, do not return IPv6 template information even if an IPv6 subnet is present in network_info."

Could please you provide additional information about why the customer wants to remove this feature? Did customer spot any issues when option use_ipv6=true enabled?

Requested backport assumes removing the feature of the current release and more like feature request than backport.

Changed in mos:
status: Confirmed → Incomplete
Revision history for this message
Andrii Yaurov (ayaurov) wrote :

In the OpenStack documentation this option is stated to be related to nova-network, which is not being used in the environment. Because of this, the customer wants to bypass its usage. If this backport is unreasonable, is it safe to use this option, and are there any relations/impacts/mismatches for this config option with neutron related services?

Revision history for this message
Roman Lubianyi (rlubianyi) wrote :

As I understand customer use neutron and this feature works in neutron too. From my point of view, this rathe mistake in the documentation or description than a bug in the code. What exactly issues did the customer spotted when using this feature?

Revision history for this message
Andrii Yaurov (ayaurov) wrote :

The customer has been concerned about its usage with neutron and possible side effects. Because of this concerns they requested a feature backport as a way to bypass the usage of the option.

Revision history for this message
Andrey (asmaraev) wrote :

Hello, is there any updates? is that possible to prepare the fix there ?

Revision history for this message
Roman Lubianyi (rlubianyi) wrote :

Please, use use_ipv6=true in nova.conf file.

Changed in mos:
status: Incomplete → Invalid
Changed in mos:
milestone: 9.2-mu-12 → 9.x-updates
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.