Description of problem: Creating image-volume cache fails with NFS backend. Following are the steps to reproduce the issue. 1. Configure a host to enable image-volume cache using https://docs.openstack.org/cinder/latest/admin/blockstorage-image-volume-cache.html 2. Create a volume on a tenant remotefs driver tries to create a temporary snapshot before creating a volume on internal tenant. This operation throws error. (See attached Cinder volume logs) This error is observed on Stein release. Actual result: - temporary snapshot gets stuck in `creating` state Expected result: - Image volume should have been created on internal tenant Solution: snapshot.id at https://github.com/openstack/cinder/blob/stable/stein/cinder/volume/drivers/remotefs.py#L1442 doesn't have `tmp-snap` in it as id is not passed as a option while creating snapshot object. This should be change to `snapshot.display_name` at same location Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info:
Adding the dependency between this and https://bugzilla.redhat.com/1741730
Verified on: openstack-cinder-12.0.10-19.el7ost.noarch python2-glance-store-0.23.1-0.20190916165252.cc7ecc1.el7ost.noarch On a system with OSP13, Glance uses Cinder as it's backend, this was setup for a previous bz. Cinder uses Netapp NFS as it's backend. Image_volume_cache is enabled on Cinder.conf Simultaneously created 10 volumes from same image: #for i in {1..10}; do cinder create 1 --image cirros ; done Resulting 10 volumes all in available state as expected: (overcloud) [stack@undercloud-0 ~]$ cinder list +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+-------------+ | ID | Status | Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+-------------+ | 11a62820-6745-4876-ab32-71363e42e353 | available | - | 1 | tripleo | true | | | 2a46f3c7-fa9f-4b72-9dee-4bd4dea7a631 | available | - | 1 | tripleo | true | | | 3c5b8cfb-75d5-4c09-98b6-5ecfed4c1972 | available | - | 1 | tripleo | true | | | 4e68f832-bce2-43e9-a547-8d29242e1512 | available | - | 1 | tripleo | true | | | 5eff40e0-5eda-407b-b084-63604d6c521d | available | - | 1 | tripleo | true | | | 6c58d022-0ee6-4f64-9bcd-d744612c6d78 | available | - | 1 | tripleo | true | | | 7eb389b6-ff05-4c83-a6f3-c3f7cebc5274 | available | - | 1 | tripleo | true | | | aebf32e4-0855-494e-9ae9-fd9aa054d6ff | available | - | 1 | tripleo | true | | | c7714e66-5a91-45da-a531-d4097f13081b | available | - | 1 | tripleo | true | | | ccd6fd5c-4738-4363-9364-a680531abadf | available | - | 1 | tripleo | true | | | edfb3cdb-c608-4b0f-a6ac-0a964772b16f | available | image-1e30b583-a24d-45ea-a9b8-a6f7699f605a | 1 | tripleo | false | | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+-------------+ Delete all volumes I had now changed Glance to file store instead of Cinder as it's backend. And retested again, create 10 cinder volumes from a new uploaded image for i in {1..10}; do cinder create 1 --image cirros3 ; done This too worked as expected: (overcloud) [stack@undercloud-0 ~]$ cinder list +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+-------------+ | ID | Status | Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+-------------+ | 03461a57-ccc6-40fa-baa6-29e28657bccb | creating | - | 1 | tripleo | false | | | 03bc59b0-5068-4962-b171-634cde62ab8b | available | - | 1 | tripleo | true | | | 28075c5e-93eb-4de3-bab0-9c79ed1a3c38 | available | - | 1 | tripleo | true | | | 2ee49c4a-0628-48fd-a887-1cdf37981cab | available | - | 1 | tripleo | true | | | 34a879e8-f6b2-428b-b297-8913cb5a01bf | available | - | 1 | tripleo | true | | | 3c809887-8471-48c5-b52d-8f9910f882bd | available | image-f67d6e7a-5a57-4e52-8b8c-d4e38f0201c7 | 1 | tripleo | false | | | 402bfa22-431f-41ce-8fe2-f49344c60cf8 | available | - | 1 | tripleo | true | | | 588c96a5-d9e0-48e4-9a2c-41e83f50d5d7 | available | - | 1 | tripleo | true | | | 9ee70095-4baa-4196-9ef8-2b486e744dfa | available | - | 1 | tripleo | true | | | c3c0a465-56a5-40b8-b4e2-47ecb648373f | available | - | 1 | tripleo | true | | | cd89017e-ca89-437b-b9e1-13e10b113403 | available | - | 1 | tripleo | true | | | cf0eff46-a75a-431a-97dc-b5e71eb4c6a0 | creating | - | 1 | tripleo | false | | | edfb3cdb-c608-4b0f-a6ac-0a964772b16f | available | image-1e30b583-a24d-45ea-a9b8-a6f7699f605a | 1 | tripleo | false | | | ef3acf7e-4144-4d09-9229-943c7f64a6a4 | creating | - | 1 | tripleo | false | | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+-------------+ Confirming that image cache on NFS backend now works.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory (Moderate: openstack-cinder security update), and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2020:4391