OpenStack Block Storage (Cinder)
Go to file
zhangsong 53073d1921 Fix the bug of OSError when convert image
When I try to convert a image use image_utils.convert_image() method,
an error occurred like this :
'''
OSError: [Errno 2] No such file or directory:
'sheepdog:10.133.17.61:7000:volume-a0a70f9b-a50e-4369-885f-c41a894c9fe5'
'''
The reason is that in some cluster storage systems, like
ceph/sheepdog, QEMU can access an image directly via their private
protocol, and there’s no need to map an image as a block device on
the host. In this case, the qemu-img convert command may like:

    #qemu-img convert -O raw sheepdog:Ip:port:image_name temp_file
    #qemu-img convert -O raw rbd:pool_name/image_name temp_file

The source path may be 'sheepdog:Ip:port:image_name' or
'rbd:pool_name/image_name', it doesn't exist in OS. So, when it runs
the os.stat(source) in image_utils.convert_image(source,dest,out_format)
method, an OSError would be raised.

We can use qemu_img_info method instead to resolve this problem, because
the 'qemu-img info' command can always get the image size info which has
support qemu-img tool. Here we capture a ValueError just in case, but it
only need to give a warning message, because the image has been successfully
converted.

Change-Id: I5fd1e51840972a67053b85a76f8e001fa8148ad7
Closes-Bug: #1514442
2015-11-23 22:44:39 +08:00
cinder Fix the bug of OSError when convert image 2015-11-23 22:44:39 +08:00
doc Merge "Update the devref for volume migration" 2015-11-09 06:24:06 +00:00
etc/cinder Merge "Return volume_type extra specs based on policy" 2015-11-03 22:51:13 +00:00
rally-jobs Add more Rally scenarios to run 2015-08-04 21:26:35 +00:00
releasenotes Add reno for release notes management 2015-11-05 14:58:17 +01:00
tools CGSnapshot Object 2015-10-19 14:37:39 +02:00
.coveragerc Change ignore-errors to ignore_errors 2015-09-21 14:25:22 +00:00
.gitignore Add reno for release notes management 2015-11-05 14:58:17 +01:00
.gitreview Initial fork out of Nova. 2012-05-03 10:48:26 -07:00
.mailmap Fix wrong command for _rescan_multipath 2015-03-31 09:17:45 +00:00
.testr.conf Fix up the test framework 2013-06-14 14:02:17 +00:00
CONTRIBUTING.md Workflow documentation is now in infra-manual 2014-12-05 04:39:45 +00:00
HACKING.rst Hacking check for opt name registration 2015-10-06 08:35:48 -05:00
LICENSE Initial fork out of Nova. 2012-05-03 10:48:26 -07:00
MANIFEST.in Use setuptools-git. 2012-08-10 11:56:00 -04:00
README.rst Update README.rst to current state 2015-01-12 14:02:24 +01:00
babel.cfg Initial fork out of Nova. 2012-05-03 10:48:26 -07:00
openstack-common.conf Remove unused gettextutils from oslo-incubator 2015-10-16 15:22:49 -05:00
pylintrc Use six to fix imports on Python 3 2015-06-11 17:19:19 +02:00
requirements.txt Revert "Handle correct exception raised by python-novaclient" 2015-10-28 17:01:59 -07:00
run_tests.sh Detect addition of executable files 2015-08-31 12:19:51 -04:00
setup.cfg Use pbr wsgi_scripts to install Cinder WSGI entry point 2015-09-28 17:05:45 +03:00
setup.py Updated from global requirements 2015-09-18 16:37:17 +00:00
test-requirements.txt Add reno for release notes management 2015-11-05 14:58:17 +01:00
tests-py3.txt Merge "Port cinder.utils.monkey_patch() to Python 3" 2015-11-09 04:19:42 +00:00
tox.ini Add reno for release notes management 2015-11-05 14:58:17 +01:00

README.rst

CINDER

You have come across a storage service for an open cloud computing service. It has identified itself as Cinder. It was abstracted from the Nova project.

Getting Started

If you'd like to run from the master branch, you can clone the git repo:

git clone https://github.com/openstack/cinder.git

For developer information please see HACKING.rst

You can raise bugs here http://bugs.launchpad.net/cinder

Python client

https://github.com/openstack/python-cinderclient.git