Comment 11 for bug 1753550

Revision history for this message
melanie witt (melwitt) wrote :

Okay, I was able to reproduce the problem locally with devstack by:

  1. Create an instance
  2. virsh shutdown <domain>
  3. Wait for nova-compute to try to "stop" the instance and it fails to do that

I found that the "EndpointNotFound: Could not find requested endpoint for any of the following interfaces: ['internal', 'public']" error originates from a "exceptions.EmptyCatalog('The service catalog is empty.')" raised from keystoneauth1/access/service_catalog.py(362)endpoint_data_for(). That originates from the fact that the RequestContext.service_catalog is an empty list [] when we make the call.

The "sync power states" periodic task is the routine responsible for updating the instance power state and status to reflect the state reported by the virt driver, and our periodic tasks all run using an anonymous RequestContext we get by calling nova.context.get_admin_context(). This type of context is not going to have service_catalog populated, so we will fail if we try to do anything with the service_catalog on such a RequestContext.

Currently, it looks like the first thing we need to do is determine whether we really need to be trying to do anything with image urls or glance or the service catalog when we're sending notifications. gibi said he will start investigating that tomorrow.

For the moment, other than removing the dependency on glance image urls in notifications, it's not clear how we can fix the periodic task.