Comment 7 for bug 1280399

Revision history for this message
Aleksandr Didenko (adidenko) wrote :

Managed to reproduce it. On a large images that require large volumes, spawning of new instance may timeout while waiting for block device mapping to finish. But cinder continues to create volume until it's complete:

root@node-6:~# cinder list
+--------------------------------------+-------------+--------------+------+-------------+----------+-------------+
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+--------------------------------------+-------------+--------------+------+-------------+----------+-------------+
| d9fb1238-91e7-4ae5-99d2-23faa7aab550 | downloading | | 40 | None | false | |
+--------------------------------------+-------------+--------------+------+-------------+----------+-------------+

That's why you can use this volume later to spawn new instance from it.

So we just need to increase timeout value for block device mapping in nova config, using configuration parameters introduced in Juno (https://review.openstack.org/#/c/102891/). Default values are:

block_device_allocate_retries=60
block_device_allocate_retries_interval=3

Which is 3 minutes. After increasing block_device_allocate_retries from 60 to 300 (15 minutes) on my local env, spawning new instances from 1.8G qcow2 image and 40G volume started to work just fine.