← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 2125743] [NEW] An error occurred while refreshing the network cache

 

Public bug reported:

I got this error in nova-compute.
```

2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [None req-fafaab16-25e1-4d66-b14e-38c5be50a836 - - - - - -] [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] An error occurred while refreshing the network cache.: TypeError: tuple indices must be integers or slices, not str
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] Traceback (most recent call last):
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/compute/manager.py", line 10073, in _heal_instance_info_cache
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     self.network_api.get_instance_nw_info(
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1990, in get_instance_nw_info
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     result = self._get_instance_nw_info(context, instance, **kwargs)
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 2016, in _get_instance_nw_info
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     nw_info = self._build_network_info_model(context, instance, networks,
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 3534, in _build_network_info_model
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     vif = self._build_vif_model(
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 3361, in _build_vif_model
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     self._nw_info_build_network(context, current_neutron_port,
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 3298, in _nw_info_build_network
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     physnet, tunneled = self._get_physnet_tunneled_info(
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 2155, in _get_physnet_tunneled_info
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     if self.has_multi_provider_extension(client=neutron):
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1406, in has_multi_provider_extension
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     return self._has_extension(constants.MULTI_PROVIDER, context, client)
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1397, in _has_extension
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     self._refresh_neutron_extensions_cache(client)
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1381, in _refresh_neutron_extensions_cache
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     extensions_list = client.list_extensions()['extensions']
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] TypeError: tuple indices must be integers or slices, not str
2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] 

```
Not sure why this `neutron_client.list_extensions()` returns slice, not dict.
https://github.com/openstack/nova/blob/stable/2024.2/nova/network/neutron.py#L1381

The openstack version is 2024.2.

Regards.
Oleksandr

** Affects: nova
     Importance: Undecided
         Status: New

-- 
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/2125743

Title:
  An error occurred while refreshing the network cache

Status in OpenStack Compute (nova):
  New

Bug description:
  I got this error in nova-compute.
  ```

  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [None req-fafaab16-25e1-4d66-b14e-38c5be50a836 - - - - - -] [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] An error occurred while refreshing the network cache.: TypeError: tuple indices must be integers or slices, not str
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] Traceback (most recent call last):
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/compute/manager.py", line 10073, in _heal_instance_info_cache
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     self.network_api.get_instance_nw_info(
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1990, in get_instance_nw_info
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     result = self._get_instance_nw_info(context, instance, **kwargs)
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 2016, in _get_instance_nw_info
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     nw_info = self._build_network_info_model(context, instance, networks,
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 3534, in _build_network_info_model
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     vif = self._build_vif_model(
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 3361, in _build_vif_model
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     self._nw_info_build_network(context, current_neutron_port,
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 3298, in _nw_info_build_network
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     physnet, tunneled = self._get_physnet_tunneled_info(
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 2155, in _get_physnet_tunneled_info
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     if self.has_multi_provider_extension(client=neutron):
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1406, in has_multi_provider_extension
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     return self._has_extension(constants.MULTI_PROVIDER, context, client)
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1397, in _has_extension
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     self._refresh_neutron_extensions_cache(client)
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]   File "/var/lib/openstack/lib/python3.10/site-packages/nova/network/neutron.py", line 1381, in _refresh_neutron_extensions_cache
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325]     extensions_list = client.list_extensions()['extensions']
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] TypeError: tuple indices must be integers or slices, not str
  2025-09-26 07:51:36.727 3961553 ERROR nova.compute.manager [instance: 0981a8f5-159d-48a3-9fe3-3ae5086eb325] 

  ```
  Not sure why this `neutron_client.list_extensions()` returns slice, not dict.
  https://github.com/openstack/nova/blob/stable/2024.2/nova/network/neutron.py#L1381

  The openstack version is 2024.2.

  Regards.
  Oleksandr

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/2125743/+subscriptions