Creating a Cinder volume from an image ID fails to copy the image to the volume
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Released
|
High
|
John Griffith | ||
Grizzly |
Fix Released
|
High
|
Adam Gandelman |
Bug Description
Description
~~~~~~~~~~
Set up a Fresh devstack install on Fedora-19, and an attempt to create a cinder volume fails saying: Logical Volume already exist. This behavior is reproducible. Also tried removing the LV manually - more info on this below)
Some details
~~~~~~~~~~~
From /opt/stack/nova
$ git log | head -1
commit 7303b93e2361ec9
From ~/src/devstack/
$ git log | head -1
683ef75510389d1
Setup
~~~~~
(0) Configure devstack, source the keystone credentials.
===
$./stack.sh
$ . openrc
===
(1) List existing images
===
$ glance image-list
+------
| ID | Name | Disk Format | Container Format | Size | Status |
+------
| dfe3df69-
| 7cd04f66-
| 2ba1b137-
| 52ff39a7-
| 2f9e7f1f-
+------
===
(2) Create a volume
===
$ cinder create --display-name image_vol-test --image_id 52ff39a7-
+------
| Property | Value |
+------
| attachments | [] |
| availability_zone | nova |
| bootable | false |
| created_at | 2013-05-
| display_description | None |
| display_name | image_vol-test |
| id | 0894c5fb-
| image_id | 52ff39a7-
| metadata | {} |
| size | 1 |
| snapshot_id | None |
| source_volid | None |
| status | creating |
| volume_type | None |
+------
===
(3) List the just created Volume
===
$ cinder list
+------
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+------
| 0894c5fb-
+------
===
(4) From the screen logs:
===
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
===
Further Investigation:
~~~~~~~~~~~~~~~~~~
Try to remove the Logical Volume manually, and re try to create the volume
=====
$ ls /dev/stack-volumes/
volume-
=====
$ ls -al /dev/stack-
lrwxrwxrwx. 1 root root 7 May 23 04:55 /dev/stack-
=====
$ sudo -i
=====
$ rm /dev/dm-2
rm: remove block special file ‘/dev/dm-2’? y
=====
Create the volume again:
=====
$ cinder delete b1f03e26-
=====
$ cinder create --display-name image_vol-test3 --image_id 52ff39a7-
=====
$ cinder list
+------
| ID | Status | Display Name | Size | Volume Type | Bootable | Attached to |
+------
| c25c7c90-
+------
===
Changed in cinder: | |
assignee: | nobody → John Griffith (john-griffith) |
importance: | Undecided → High |
milestone: | none → havana-1 |
tags: | added: grizzly-backport-potential |
Changed in cinder: | |
assignee: | John Griffith (john-griffith) → Mike Perez (thingee) |
Changed in cinder: | |
status: | In Progress → Won't Fix |
status: | Won't Fix → Fix Committed |
Changed in cinder: | |
status: | Fix Committed → Fix Released |
tags: | removed: grizzly-backport-potential |
Changed in cinder: | |
milestone: | havana-1 → 2013.2 |
Changed in cinder: | |
assignee: | Mike Perez (thingee) → John Griffith (john-griffith) |
More contextual information from the SCREEN log: ~~~~~~~ ~~~~~~~ ~~~~~~~ ~~~~~~~ ~~~~~~~
~~~~~~~
[...] volume. driver Traceback (most recent call last): volume. driver File "/opt/stack/ cinder/ cinder/ volume/ driver. py", line 88, in _try_execute volume. driver self._execute( *command, **kwargs) volume. driver File "/opt/stack/ cinder/ cinder/ utils.py" , line 193, in execute volume. driver cmd=' '.join(cmd)) volume. driver ProcessExecutio nError: Unexpected error while running command. volume. driver Command: sudo cinder-rootwrap /etc/cinder/ rootwrap. conf lvcreate -L 1G -n volume- b1f03e26- 2a80-4a9d- 9c2b-428d62e3fe 29 stack-volumes volume. driver Exit code: 5 volume. driver Stdout: '' volume. driver Stderr: ' Logical volume "volume- b1f03e26- 2a80-4a9d- 9c2b-428d62e3fe 29" already exists in volume group "stack-volumes"\n' volume. driver 60d7-43de- b011-442de86000 ae f55e931102fa473 083b5ac048b805a 97 988c13aa9fb64d4 5a8999ccd4425be 1f] Running cmd (subprocess): sudo cinder-rootwrap /etc/cinder/ rootwrap. conf lvcreate -L 1G -n volume- b1f03e26- 2a80-4a9d- 9c2b-428d62e3fe 29 stack-volumes from (pid=12748) execute /opt/stack/ cinder/ cinder/ utils.py: 169 60d7-43de- b011-442de86000 ae f55e931102fa473 083b5ac048b805a 97 988c13aa9fb64d4 5a8999ccd4425be 1f] Result was 5 from (pid=12748) execute /opt/stack/ cinder/ cinder/ utils.py: 186 volume. driver [req-6367045a- 60d7-43de- b011-442de86000 ae f55e931102fa473 083b5ac048b805a 97 988c13aa9fb64d4 5a8999ccd4425be 1f] Recovering from a failed execute. Try number 2 volume. driver Traceback (most recent call last): volume. driver File "/opt/stack/ cinder/ cinder/ volume/ driver. py", line 88, in _try_execute volume. driver self._execute( *command, **kwargs) volume. driver File "/opt/stack/ cinder/ cinder/ utils.py" , line 193, in execute volume. driver cmd=' '.join(cmd)) volume. driver ProcessExecutio nError: Unexpected error while running command. volume. driver Command: sudo cinder-rootwrap /etc/cinder/ rootwrap. conf lvcreate -L 1G -n volume- b1f03e26- 2a80-4a9d- 9c2b-428d62e3fe 29 stack-volumes volume. driver Exit code: 5 volume. driver Stdout: '' volume. driver Stderr: ' Logical volume "volume- b1f03e26- 2a80-4a9d- 9c2b-428d62e3fe 29" already exists in volume group "stack-volumes"\n' volume. driver
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:39.218 TRACE cinder.
2013-05-23 04:55:40.220 DEBUG cinder.utils [req-6367045a-
2013-05-23 04:55:40.410 DEBUG cinder.utils [req-6367045a-
2013-05-23 04:55:40.411 ERROR cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
2013-05-23 04:55:40.411 TRACE cinder.
[...]