yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #87722
[Bug 1950180] Re: After disabling dhcp on a network, metadata is still reporting that is enabled
This is working fine in Victoria and further releases and problem is
observed in ussuri.
The problem seems to be in nova - enable_dhcp flag is not considered
while updating dhcp_server in network_info [1]
[1]
https://opendev.org/openstack/nova/src/commit/8f250f50446ca2d7aa84609d5144088aa4cded78/nova/network/neutron.py#L3421-L3429
** Also affects: nova
Importance: Undecided
Status: New
** Changed in: nova
Assignee: (unassigned) => Hemanth Nakkina (hemanth-n)
** Changed in: networking-ovn
Status: New => Invalid
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1950180
Title:
After disabling dhcp on a network, metadata is still reporting that is
enabled
Status in networking-ovn:
Invalid
Status in OpenStack Compute (nova):
New
Bug description:
After disabling dhcp on a network, metadata still reports that the
network is of type: ipv4_dhcp
Version:
ovn: 20.03.2-0ubuntu0.20.04.2
neutron: 2:16.4.0-0ubuntu3~cloud0
Steps to reproduce:
1. I have a network with dhcp enabled:
Network: 732e626d-2aa7-49bf-bf17-0849c9196b84
Subnet: 04064e53-2b95-477b-ad87-844cf9f8ba2e
Dhcp is enabled.
Port list:
os port list --long --network 732e626d-2aa7-49bf-bf17-0849c9196b84
+--------------------------------------+------+-------------------+------------------------------------------------------------------------------+--------+--------------------------------------+--------------+------+
| ID | Name | MAC Address | Fixed IP Addresses | Status | Security Groups | Device Owner | Tags |
+--------------------------------------+------+-------------------+------------------------------------------------------------------------------+--------+--------------------------------------+--------------+------+
| d3092f18-632b-4e2d-bf03-6044daea82d7 | | fa:16:3e:e8:e2:44 | ip_address='10.17.10.201', subnet_id='04064e53-2b95-477b-ad87-844cf9f8ba2e' | DOWN | | network:dhcp | |
| e0d0246f-035e-4623-bb04-80323763d4e4 | | fa:16:3e:23:d0:44 | ip_address='10.17.10.210', subnet_id='04064e53-2b95-477b-ad87-844cf9f8ba2e' | ACTIVE | f7db7448-2de2-4849-8257-d3d2a9ac32e9 | compute:az1 | |
+--------------------------------------+------+-------------------+------------------------------------------------------------------------------+--------+--------------------------------------+--------------+------+
I create a VM on that network, and from the Vm I curl the metadata and I get the info re my network:
$ curl http://169.254.169.254/openstack/latest/network_data.json
...
{"id": "network1", "type": "ipv4_dhcp", "link": "tape0d0246f-03", "network_id": "732e626d-2aa7-49bf-bf17-0849c9196b84"}
...
2. I disable dhcp on the subnet:
os subnet set --no-dhcp 04064e53-2b95-477b-ad87-844cf9f8ba2e
Port list is not updated:
$ os port list --long --network 732e626d-2aa7-49bf-bf17-0849c9196b84
+--------------------------------------+------+-------------------+------------------------------------------------------------------------------+--------+--------------------------------------+--------------+------+
| ID | Name | MAC Address | Fixed IP Addresses | Status | Security Groups | Device Owner | Tags |
+--------------------------------------+------+-------------------+------------------------------------------------------------------------------+--------+--------------------------------------+--------------+------+
| d3092f18-632b-4e2d-bf03-6044daea82d7 | | fa:16:3e:e8:e2:44 | ip_address='10.17.10.201', subnet_id='04064e53-2b95-477b-ad87-844cf9f8ba2e' | DOWN | | network:dhcp | |
| e0d0246f-035e-4623-bb04-80323763d4e4 | | fa:16:3e:23:d0:44 | ip_address='10.17.10.210', subnet_id='04064e53-2b95-477b-ad87-844cf9f8ba2e' | ACTIVE | f7db7448-2de2-4849-8257-d3d2a9ac32e9 | compute:az1 | |
+--------------------------------------+------+-------------------+------------------------------------------------------------------------------+--------+--------------------------------------+--------------+------+
3. Hard reboot the VM and curl network data and metadata still reports dhcp is enabled:
$ os server reboot --hard 64658fed-2b76-4f73-a89c-e9d82fab0ac1
$ curl http://169.254.169.254/openstack/latest/network_data.json
...
{"id": "network1", "type": "ipv4_dhcp", "link": "tape0d0246f-03", "network_id": "732e626d-2aa7-49bf-bf17-0849c9196b84"}
...
4. I removed the fixed-ip from the dhcp port and hard reboot the vm again and this time metadata retrieve the correct value for the network:
$ os port set --no-fixed-ip d3092f18-632b-4e2d-bf03-6044daea82d7
$ os server reboot --hard 64658fed-2b76-4f73-a89c-e9d82fab0ac1
$ curl http://169.254.169.254/openstack/latest/network_data.json
...
{"id": "network1", "type": "ipv4", "link": "tape0d0246f-03", "ip_address": "10.17.10.210", "netmask": "255.255.255.0", "routes": [], "network_id": "732e626d-2aa7-49bf-bf17-0849c9196b84", "services": [{"type": "dns", "address": "10.0.0.233"}, {"type": "dns", "address": "10.0.20.233"}]}
...
5. If dhcp is toggled again we hit the issue again.
To manage notifications about this bug go to:
https://bugs.launchpad.net/networking-ovn/+bug/1950180/+subscriptions