Bug 1642155
Summary: | cinder always check image_volume_cache_max_size_gb and image_volume_cache_max_count when either of them is specified. | ||
---|---|---|---|
Product: | Red Hat OpenStack | Reporter: | Elise Gafford <egafford> |
Component: | openstack-cinder | Assignee: | Elise Gafford <egafford> |
Status: | CLOSED ERRATA | QA Contact: | Avi Avraham <aavraham> |
Severity: | medium | Docs Contact: | Kim Nylander <knylande> |
Priority: | medium | ||
Version: | 12.0 (Pike) | CC: | aavraham, abishop, amcleod, egafford, knoha, knylande, srevivo, tshefi |
Target Milestone: | --- | Keywords: | Triaged, ZStream |
Target Release: | 12.0 (Pike) | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | openstack-cinder-11.1.0-21.el7ost | Doc Type: | Bug Fix |
Doc Text: |
The Block Storage service (cinder) uses two volume cache limit settings. Previously, when only one cache limit was configured, adding a new entry to the cache caused an existing entry to be ejected from the cache. Only a single entry would be cached, regardless of the configured cache limit.
With this update, the Block Storage service handles volume cache limits correctly.
|
Story Points: | --- |
Clone Of: | 1622453 | Environment: | |
Last Closed: | 2018-12-05 18:49:12 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | 1622453, 1641111 | ||
Bug Blocks: |
Description
Elise Gafford
2018-10-23 19:29:35 UTC
Verified on: openstack-cinder-11.1.0-22.el7ost.noarch Configure cache setting UC PROJECT_ID = openstack project list | grep admin | awk {'print $2'} USER_ID = openstack user list | grep admin | awk {'print $2'} crudini --set /etc/cinder/cinder.conf DEFAULT cinder_internal_tenant_project_id $PROJECT_ID crudini --set /etc/cinder/cinder.conf DEFAULT cinder_internal_tenant_user_id $USER_ID crudini --set /etc/cinder/cinder.conf netapp image_volume_cache_enabled True crudini --set /etc/cinder/cinder.conf netapp image_volume_cache_max_count 2 systemctl stop openstack-cinder-volume.service systemctl start openstack-cinder-volume.service Upload three different images: glance image-create --disk-format qcow2 --container-format bare --file cirros-0.3.5-i386-disk.img --name cirros glance image-create --disk-format raw --container-format bare --file cirros-0.3.5-i386-disk.raw --name cirros.raw glance image-create --disk-format iso --container-format bare --file dsl-4.4.10.iso --name dsl Create a volume, see it's associated image-xx cache volume. cinder create 1 --image cirros --name cirros cinder list +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ | ID | Status | Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ | 4c0119e7-bb33-4061-a6f7-4a26afb98aea | available | image-2812df11-1830-4b42-8335-13977f2e75d6 | 1 | - | false | | | fd2aeb6a-91b8-4f55-82fa-bc2aab93407c | available | cirros | 1 | - | true | | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ Create a second volume cinder create 1 --image cirros.raw --name cirros.raw Volume created we also now have two images cached volumes. cinder create 1 --image cirros.raw --name cirros_raw cinder list +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ | ID | Status | Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ | 4c0119e7-bb33-4061-a6f7-4a26afb98aea | available | image-2812df11-1830-4b42-8335-13977f2e75d6 | 1 | - | false | | | b955a352-6fed-48c5-95af-d64a36f89e72 | available | image-724f8f78-9a78-4ba2-b2cb-06bfee0f0d3b | 1 | - | false | | | c7ab48c0-efb1-4cee-816e-c94ea87108cb | available | cirros_raw | 1 | - | true | | | fd2aeb6a-91b8-4f55-82fa-bc2aab93407c | available | cirros | 1 | - | true | | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ Now a third volume cinder create 1 --image dsl --name dsl Notice 3 volumes and only two cached images, notice one of the cached images was replaced. cinder list +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ | ID | Status | Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ | 4f463f8d-d15e-4038-9e68-44feca028f1f | available | dsl | 1 | - | true | | | 584e8b1f-f581-4ccc-acd1-b39cdcfbaf87 | available | image-82443c02-cafe-4d7d-8391-ebae352c19f8 | 1 | - | false | | | b955a352-6fed-48c5-95af-d64a36f89e72 | available | image-724f8f78-9a78-4ba2-b2cb-06bfee0f0d3b | 1 | - | false | | | c7ab48c0-efb1-4cee-816e-c94ea87108cb | available | cirros_raw | 1 | - | true | | | fd2aeb6a-91b8-4f55-82fa-bc2aab93407c | available | cirros | 1 | - | true | | +--------------------------------------+-----------+--------------------------------------------+------+-------------+----------+--------------------------------------+ New image image-82443.. - replaced image-2812df11.. C-vol log evict notice ache [req-f1a95091-c50e-48be-b0d8-dd027a6d453b 21437ff80c704066ad2bc5b09dfe1609 26b9425705624361828aca58c3ccf31a - - -] Evicting image cache entry: {'last_used': datetime.datetime(2018, 12, 3, 13, 34, 7), 'image_updated_at': datetime.datetime(2018, 12, 3, 13, 21, 37), 'image_id': u'2812df11-1830-4b42-8335-13977f2e75d6', 'host': u' Looks great. Tip for reference: DEFAULT cinder_internal_tenant_project_id ... DEFAULT cinder_internal_tenant_user_id .... These two under are set under backend itself tripleo_iscsi image_volume_cache_enabled True tripleo_iscsi image_volume_cache_max_count 2 Restart service/docker Related config bits https://docs.openstack.org/cinder/latest/admin/blockstorage-image-volume-cache.html 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, 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/RHBA-2018:3785 |