When using glance cinder store, if we call the extend API for an attached volume, cinder tries to send an external event to nova.
This is because, the case of glance cinder store isn't considered in the cinder code and the extend in-use operation is assumed to be always called by nova.
Since we don't have a server_id (and even we don't need to send any external event in this case), we see the following error trace in cinder logs.
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova [req-5d1f13b6-77ac-436a-877b-bb489fea8eb7 req-f6cf32b4-69df-4475-b861-5f30184bc4c8 service None] Failed to notify nova on events: [{'name': 'volume-extended', 'server_uuid': None, 'tag': '4bbcc393-f47e-448b-9a15-e896e8a1b0f4'}].: novaclient.exceptions.BadRequest: Invalid input for field/attribute server_uuid. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-0836e8f9-c767-4322-9e8b-7f3561d14e78)
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova Traceback (most recent call last):
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova File "/opt/stack/cinder/cinder/compute/nova.py", line 155, in _send_events
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova response = nova.server_external_events.create(events)
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova File "/usr/local/lib/python3.8/dist-packages/novaclient/v2/server_external_events.py", line 38, in create
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova return self._create('/os-server-external-events', body, 'events',
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova File "/usr/local/lib/python3.8/dist-packages/novaclient/base.py", line 363, in _create
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova resp, body = self.api.client.post(url, body=body)
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova File "/usr/local/lib/python3.8/dist-packages/keystoneauth1/adapter.py", line 401, in post
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova return self.request(url, 'POST', **kwargs)
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova File "/usr/local/lib/python3.8/dist-packages/novaclient/client.py", line 78, in request
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova raise exceptions.from_response(resp, body, url, method)
Dec 29 17:18:48 devstack-VirtualBox cinder-volume[904991]: ERROR cinder.compute.nova novaclient.exceptions.BadRequest: Invalid input for field/attribute server_uuid. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-0836e8f9-c767-4322-9e8b-7f3561d14e78)
Fix proposed to branch: master /review. opendev. org/c/openstack /cinder/ +/869051
Review: https:/