Ask Your Question
1

nova volume-attach with device option not honoring given device name

asked 2015-09-14 04:08:12 -0500

Bharath gravatar image

updated 2015-09-14 04:09:40 -0500

I am trying to attach a cinder volume to a VM using device option as shown below.

nova volume-attach vm-id device-name

Eg: nova volume-attach vm-id /dev/vdd

Currently there is no device named /dev/vdc listed in VM. But I want the volume to be attached as device name vdd which falls out of alphabetical order.

volume-attach command shows me that the volume is mounted as vdd, but when I do lsblk after logging in to VM and check the device name it is listed as vdc.

nova volume-attach <vm-id> <vol-id> /dev/vdd 10
+----------+--------------------------------------+
| Property | Value                                |
+----------+--------------------------------------+
| device   |  /dev/vdd                          |

lsblk
NAME   MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sr0     11:0    1  410K  0 rom
vda    253:0    0   10G  0 disk
└─vda1 253:1    0   10G  0 part /
vdb    253:16   0   20G  0 disk /mnt
vdc    253:32   0   10G  0 disk

It is following the alphabetical order and as devices /dev/vda and /dev/vdb are present, /dev/vdc is being created in VM.

If this is the case what is the use of <device> option in nova volume-attach command? Is this a bug in nova or expected behavior, please throw some light on this.

Thank you.

edit retag flag offensive close merge delete

3 answers

Sort by » oldest newest most voted
0

answered 2016-03-28 10:14:39 -0500

sneti gravatar image

There is bug related to this on launchpad. https://bugs.launchpad.net/nova/+bug/1018253 (https://bugs.launchpad.net/nova/+bug/...). Answer is, there is no correlation between the device specified and the device used in KVM and QEMU. Devices are used in the alphabetical order irrespective of the device specified.

edit flag offensive delete link more
0

answered 2016-03-24 09:52:51 -0500

Elangovan Anganann gravatar image

updated 2016-03-28 03:04:16 -0500

For solution, refer https://www.chriscowley.me.uk/blog/2015/05/05/identify-and-mounting-cinder-volumes-in-openstack-heat/ (https://www.chriscowley.me.uk/blog/20...)

edit flag offensive delete link more
0

answered 2016-03-23 06:37:30 -0500

Have you solved this issue? I met the same one.Thanks.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2015-09-14 04:08:12 -0500

Seen: 1,935 times

Last updated: Mar 28 '16