yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #34966
[Bug 1470834] [NEW] Device name error when creating instance using snapshot of volume-booted instance
Public bug reported:
Problem discription:
After an instance was booted from a bootable volume, an user volume is
attached. Then take a snapshot of this instance. A new snapshot will be
stored in Glance and two volume snapshot will be generated in Cinder
(one for /dev/vda and one for /dev/vdb).
Use the image id of the above mentioned snapshot to boot an new
instance. Nova will use the two volume snapshot build two new volume,
use boot volume to boot the new instance and attach another one.
After the instance successfully booted and volume attached. The device name of /dev/vda is both correct in Nova DB and Cinder DB,
but the device name for user volume is incorrect in Cinder DB (None is stored instead of /dev/vdb).
root@kevin-dev:/opt/stack/nova/nova/compute# glance image-show 3d870b18-4a42-4961-8d75-58ebc534673a
+---------------------------------+----------------------------------------------------------------------------------+
| Property | Value |
+---------------------------------+----------------------------------------------------------------------------------+
| Property 'bdm_v2' | True |
| Property 'block_device_mapping' | [{"guest_format": null, "boot_index": 0, "no_device": null, "snapshot_id": |
| | "abb478f5-0b26-4e55-964c-cba1135a0e56", "delete_on_termination": false, |
| | "disk_bus": "virtio", "image_id": null, "source_type": "snapshot", |
| | "device_type": "disk", "volume_id": null, "destination_type": "volume", |
| | "volume_size": null}, {"guest_format": null, "boot_index": null, "no_device": |
| | null, "snapshot_id": "7528c37c-7fa1-44dc-8a29-e60762959e81", |
| | "delete_on_termination": false, "disk_bus": null, "image_id": null, |
| | "source_type": "snapshot", "device_type": null, "volume_id": null, |
| | "destination_type": "volume", "volume_size": null}] |
| Property 'checksum' | eb9139e4942121f22bbc2afc0400b2a4 |
| Property 'container_format' | ami |
| Property 'disk_format' | ami |
| Property 'image_id' | 5e992b08-d772-44d7-90bf-0b0d9eaa2fcd |
| Property 'image_name' | cirros-0.3.4-x86_64-uec |
| Property 'kernel_id' | d695a227-e074-47eb-8873-38e1ff79ec1e |
| Property 'min_disk' | 0 |
| Property 'min_ram' | 0 |
| Property 'ramdisk_id' | d71b3dde-83c8-4da7-bbf6-46aa3e65e16f |
| Property 'root_device_name' | /dev/vda |
| Property 'size' | 25165824 |
| created_at | 2015-07-02T11:52:12.000000 |
| deleted | False |
| id | 3d870b18-4a42-4961-8d75-58ebc534673a |
| is_public | False |
| min_disk | 0 |
| min_ram | 0 |
| name | snapshot_with_volume |
| owner | 939300520ec34fea975ef197c8fd61b8 |
| protected | False |
| size | 0 |
| status | active |
| updated_at | 2015-07-02T11:52:12.000000 |
+---------------------------------+----------------------------------------------------------------------------------+
nova --debug boot --flavor 1 --nic net-
id=13854918-10d5-466e-b576-1c4c9689f357 --image
3d870b18-4a42-4961-8d75-58ebc534673a test1
root@kevin-dev:/opt/stack/nova/nova/compute# nova show 2bdb308a-9068-4e89-9dcf-fec5173747ff
+--------------------------------------+--------------------------------------------------------------------------------------------------+
| Property | Value |
+--------------------------------------+--------------------------------------------------------------------------------------------------+
| OS-DCF:diskConfig | MANUAL |
| OS-EXT-AZ:availability_zone | nova |
| OS-EXT-SRV-ATTR:host | kevin-dev |
| OS-EXT-SRV-ATTR:hypervisor_hostname | kevin-dev |
| OS-EXT-SRV-ATTR:instance_name | instance-00000018 |
| OS-EXT-STS:power_state | 1 |
| OS-EXT-STS:task_state | - |
| OS-EXT-STS:vm_state | active |
| OS-SRV-USG:launched_at | 2015-07-02T12:07:40.000000 |
| OS-SRV-USG:terminated_at | - |
| accessIPv4 | |
| accessIPv6 | |
| config_drive | True |
| created | 2015-07-02T12:06:12Z |
| flavor | m1.tiny (1) |
| hostId | ce8526988d61f2880b9d0198707c456dac88544d1a8699a74d41bb45 |
| id | 2bdb308a-9068-4e89-9dcf-fec5173747ff |
| image | snapshot_with_volume (3d870b18-4a42-4961-8d75-58ebc534673a) |
| key_name | - |
| metadata | {} |
| name | test1 |
| os-extended-volumes:volumes_attached | [{"id": "e90a6425-d88c-46af-b572-45db4b511c05"}, {"id": "b5aeba3a-2990-4c9f-87ac-c402b4a34402"}] |
| private network | 10.0.0.26, fd89:f61e:48ad:0:f816:3eff:fe08:a36e |
| progress | 0 |
| security_groups | default |
| status | ACTIVE |
| tenant_id | 939300520ec34fea975ef197c8fd61b8 |
| updated | 2015-07-02T12:07:40Z |
| user_id | 44c538801d8f46fa9b9b15d7d7986bef |
+--------------------------------------+--------------------------------------------------------------------------------------------------+
root@kevin-dev:/opt/stack/nova/nova/compute# cinder show e90a6425-d88c-46af-b572-45db4b511c05
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Property | Value |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| attachments | [{u'server_id': u'2bdb308a-9068-4e89-9dcf-fec5173747ff', u'attachment_id': u'eb1046d3-b263-4ec9-a67d-4be0d20f9ebd', u'host_name': None, u'volume_id': u'e90a6425-d88c-46af-b572-45db4b511c05', u'device': u'/dev/vda', u'id': u'e90a6425-d88c-46af-b572-45db4b511c05'}] |
| availability_zone | nova |
| bootable | true |
| consistencygroup_id | None |
| created_at | 2015-07-02T12:06:54.000000 |
| description | None |
| encrypted | False |
| id | e90a6425-d88c-46af-b572-45db4b511c05 |
| metadata | {u'readonly': u'False', u'attached_mode': u'rw'} |
| multiattach | False |
| name | None |
| os-vol-host-attr:host | kevin-dev@lvmdriver-1#lvmdriver-1 |
| os-vol-mig-status-attr:migstat | None |
| os-vol-mig-status-attr:name_id | None |
| os-vol-tenant-attr:tenant_id | 939300520ec34fea975ef197c8fd61b8 |
| os-volume-replication:driver_data | None |
| os-volume-replication:extended_status | None |
| replication_status | disabled |
| size | 1 |
| snapshot_id | abb478f5-0b26-4e55-964c-cba1135a0e56 |
| source_volid | None |
| status | in-use |
| user_id | 44c538801d8f46fa9b9b15d7d7986bef |
| volume_image_metadata | {u'kernel_id': u'd695a227-e074-47eb-8873-38e1ff79ec1e', u'container_format': u'ami', u'min_ram': u'0', u'ramdisk_id': u'd71b3dde-83c8-4da7-bbf6-46aa3e65e16f', u'disk_format': u'ami', u'image_name': u'cirros-0.3.4-x86_64-uec', u'image_id': u'5e992b08-d772-44d7-90bf-0b0d9eaa2fcd', u'checksum': u'eb9139e4942121f22bbc2afc0400b2a4', u'min_disk': u'0', u'size': u'25165824'} |
| volume_type | lvmdriver-1 |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
root@kevin-dev:/opt/stack/nova/nova/compute# cinder show b5aeba3a-2990-4c9f-87ac-c402b4a34402
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Property | Value |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| attachments | [{u'server_id': u'2bdb308a-9068-4e89-9dcf-fec5173747ff', u'attachment_id': u'17087fb3-51a5-4175-ae75-4373e364c301', u'host_name': None, u'volume_id': u'b5aeba3a-2990-4c9f-87ac-c402b4a34402', u'device': None, u'id': u'b5aeba3a-2990-4c9f-87ac-c402b4a34402'}] |
| availability_zone | nova |
| bootable | false |
| consistencygroup_id | None |
| created_at | 2015-07-02T12:07:14.000000 |
| description | None |
| encrypted | False |
| id | b5aeba3a-2990-4c9f-87ac-c402b4a34402 |
| metadata | {u'readonly': u'False', u'attached_mode': u'rw'} |
| multiattach | False |
| name | None |
| os-vol-host-attr:host | kevin-dev@lvmdriver-1#lvmdriver-1 |
| os-vol-mig-status-attr:migstat | None |
| os-vol-mig-status-attr:name_id | None |
| os-vol-tenant-attr:tenant_id | 939300520ec34fea975ef197c8fd61b8 |
| os-volume-replication:driver_data | None |
| os-volume-replication:extended_status | None |
| replication_status | disabled |
| size | 1 |
| snapshot_id | 7528c37c-7fa1-44dc-8a29-e60762959e81 |
| source_volid | None |
| status | in-use |
| user_id | 44c538801d8f46fa9b9b15d7d7986bef |
| volume_type | lvmdriver-1 |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
** Affects: nova
Importance: Undecided
Assignee: Zhenyu Zheng (zhengzhenyu)
Status: New
** Changed in: nova
Assignee: (unassigned) => Zhenyu Zheng (zhengzhenyu)
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1470834
Title:
Device name error when creating instance using snapshot of volume-
booted instance
Status in OpenStack Compute (Nova):
New
Bug description:
Problem discription:
After an instance was booted from a bootable volume, an user volume is
attached. Then take a snapshot of this instance. A new snapshot will
be stored in Glance and two volume snapshot will be generated in
Cinder (one for /dev/vda and one for /dev/vdb).
Use the image id of the above mentioned snapshot to boot an new
instance. Nova will use the two volume snapshot build two new volume,
use boot volume to boot the new instance and attach another one.
After the instance successfully booted and volume attached. The device name of /dev/vda is both correct in Nova DB and Cinder DB,
but the device name for user volume is incorrect in Cinder DB (None is stored instead of /dev/vdb).
root@kevin-dev:/opt/stack/nova/nova/compute# glance image-show 3d870b18-4a42-4961-8d75-58ebc534673a
+---------------------------------+----------------------------------------------------------------------------------+
| Property | Value |
+---------------------------------+----------------------------------------------------------------------------------+
| Property 'bdm_v2' | True |
| Property 'block_device_mapping' | [{"guest_format": null, "boot_index": 0, "no_device": null, "snapshot_id": |
| | "abb478f5-0b26-4e55-964c-cba1135a0e56", "delete_on_termination": false, |
| | "disk_bus": "virtio", "image_id": null, "source_type": "snapshot", |
| | "device_type": "disk", "volume_id": null, "destination_type": "volume", |
| | "volume_size": null}, {"guest_format": null, "boot_index": null, "no_device": |
| | null, "snapshot_id": "7528c37c-7fa1-44dc-8a29-e60762959e81", |
| | "delete_on_termination": false, "disk_bus": null, "image_id": null, |
| | "source_type": "snapshot", "device_type": null, "volume_id": null, |
| | "destination_type": "volume", "volume_size": null}] |
| Property 'checksum' | eb9139e4942121f22bbc2afc0400b2a4 |
| Property 'container_format' | ami |
| Property 'disk_format' | ami |
| Property 'image_id' | 5e992b08-d772-44d7-90bf-0b0d9eaa2fcd |
| Property 'image_name' | cirros-0.3.4-x86_64-uec |
| Property 'kernel_id' | d695a227-e074-47eb-8873-38e1ff79ec1e |
| Property 'min_disk' | 0 |
| Property 'min_ram' | 0 |
| Property 'ramdisk_id' | d71b3dde-83c8-4da7-bbf6-46aa3e65e16f |
| Property 'root_device_name' | /dev/vda |
| Property 'size' | 25165824 |
| created_at | 2015-07-02T11:52:12.000000 |
| deleted | False |
| id | 3d870b18-4a42-4961-8d75-58ebc534673a |
| is_public | False |
| min_disk | 0 |
| min_ram | 0 |
| name | snapshot_with_volume |
| owner | 939300520ec34fea975ef197c8fd61b8 |
| protected | False |
| size | 0 |
| status | active |
| updated_at | 2015-07-02T11:52:12.000000 |
+---------------------------------+----------------------------------------------------------------------------------+
nova --debug boot --flavor 1 --nic net-
id=13854918-10d5-466e-b576-1c4c9689f357 --image
3d870b18-4a42-4961-8d75-58ebc534673a test1
root@kevin-dev:/opt/stack/nova/nova/compute# nova show 2bdb308a-9068-4e89-9dcf-fec5173747ff
+--------------------------------------+--------------------------------------------------------------------------------------------------+
| Property | Value |
+--------------------------------------+--------------------------------------------------------------------------------------------------+
| OS-DCF:diskConfig | MANUAL |
| OS-EXT-AZ:availability_zone | nova |
| OS-EXT-SRV-ATTR:host | kevin-dev |
| OS-EXT-SRV-ATTR:hypervisor_hostname | kevin-dev |
| OS-EXT-SRV-ATTR:instance_name | instance-00000018 |
| OS-EXT-STS:power_state | 1 |
| OS-EXT-STS:task_state | - |
| OS-EXT-STS:vm_state | active |
| OS-SRV-USG:launched_at | 2015-07-02T12:07:40.000000 |
| OS-SRV-USG:terminated_at | - |
| accessIPv4 | |
| accessIPv6 | |
| config_drive | True |
| created | 2015-07-02T12:06:12Z |
| flavor | m1.tiny (1) |
| hostId | ce8526988d61f2880b9d0198707c456dac88544d1a8699a74d41bb45 |
| id | 2bdb308a-9068-4e89-9dcf-fec5173747ff |
| image | snapshot_with_volume (3d870b18-4a42-4961-8d75-58ebc534673a) |
| key_name | - |
| metadata | {} |
| name | test1 |
| os-extended-volumes:volumes_attached | [{"id": "e90a6425-d88c-46af-b572-45db4b511c05"}, {"id": "b5aeba3a-2990-4c9f-87ac-c402b4a34402"}] |
| private network | 10.0.0.26, fd89:f61e:48ad:0:f816:3eff:fe08:a36e |
| progress | 0 |
| security_groups | default |
| status | ACTIVE |
| tenant_id | 939300520ec34fea975ef197c8fd61b8 |
| updated | 2015-07-02T12:07:40Z |
| user_id | 44c538801d8f46fa9b9b15d7d7986bef |
+--------------------------------------+--------------------------------------------------------------------------------------------------+
root@kevin-dev:/opt/stack/nova/nova/compute# cinder show e90a6425-d88c-46af-b572-45db4b511c05
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Property | Value |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| attachments | [{u'server_id': u'2bdb308a-9068-4e89-9dcf-fec5173747ff', u'attachment_id': u'eb1046d3-b263-4ec9-a67d-4be0d20f9ebd', u'host_name': None, u'volume_id': u'e90a6425-d88c-46af-b572-45db4b511c05', u'device': u'/dev/vda', u'id': u'e90a6425-d88c-46af-b572-45db4b511c05'}] |
| availability_zone | nova |
| bootable | true |
| consistencygroup_id | None |
| created_at | 2015-07-02T12:06:54.000000 |
| description | None |
| encrypted | False |
| id | e90a6425-d88c-46af-b572-45db4b511c05 |
| metadata | {u'readonly': u'False', u'attached_mode': u'rw'} |
| multiattach | False |
| name | None |
| os-vol-host-attr:host | kevin-dev@lvmdriver-1#lvmdriver-1 |
| os-vol-mig-status-attr:migstat | None |
| os-vol-mig-status-attr:name_id | None |
| os-vol-tenant-attr:tenant_id | 939300520ec34fea975ef197c8fd61b8 |
| os-volume-replication:driver_data | None |
| os-volume-replication:extended_status | None |
| replication_status | disabled |
| size | 1 |
| snapshot_id | abb478f5-0b26-4e55-964c-cba1135a0e56 |
| source_volid | None |
| status | in-use |
| user_id | 44c538801d8f46fa9b9b15d7d7986bef |
| volume_image_metadata | {u'kernel_id': u'd695a227-e074-47eb-8873-38e1ff79ec1e', u'container_format': u'ami', u'min_ram': u'0', u'ramdisk_id': u'd71b3dde-83c8-4da7-bbf6-46aa3e65e16f', u'disk_format': u'ami', u'image_name': u'cirros-0.3.4-x86_64-uec', u'image_id': u'5e992b08-d772-44d7-90bf-0b0d9eaa2fcd', u'checksum': u'eb9139e4942121f22bbc2afc0400b2a4', u'min_disk': u'0', u'size': u'25165824'} |
| volume_type | lvmdriver-1 |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
root@kevin-dev:/opt/stack/nova/nova/compute# cinder show b5aeba3a-2990-4c9f-87ac-c402b4a34402
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Property | Value |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| attachments | [{u'server_id': u'2bdb308a-9068-4e89-9dcf-fec5173747ff', u'attachment_id': u'17087fb3-51a5-4175-ae75-4373e364c301', u'host_name': None, u'volume_id': u'b5aeba3a-2990-4c9f-87ac-c402b4a34402', u'device': None, u'id': u'b5aeba3a-2990-4c9f-87ac-c402b4a34402'}] |
| availability_zone | nova |
| bootable | false |
| consistencygroup_id | None |
| created_at | 2015-07-02T12:07:14.000000 |
| description | None |
| encrypted | False |
| id | b5aeba3a-2990-4c9f-87ac-c402b4a34402 |
| metadata | {u'readonly': u'False', u'attached_mode': u'rw'} |
| multiattach | False |
| name | None |
| os-vol-host-attr:host | kevin-dev@lvmdriver-1#lvmdriver-1 |
| os-vol-mig-status-attr:migstat | None |
| os-vol-mig-status-attr:name_id | None |
| os-vol-tenant-attr:tenant_id | 939300520ec34fea975ef197c8fd61b8 |
| os-volume-replication:driver_data | None |
| os-volume-replication:extended_status | None |
| replication_status | disabled |
| size | 1 |
| snapshot_id | 7528c37c-7fa1-44dc-8a29-e60762959e81 |
| source_volid | None |
| status | in-use |
| user_id | 44c538801d8f46fa9b9b15d7d7986bef |
| volume_type | lvmdriver-1 |
+---------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1470834/+subscriptions
Follow ups
References