← Back to team overview

openstack team mailing list archive

using cinder to create volumes error

 

When I create volumes by cinder, error occurs in cinder-volume.log

2012-10-22 10:58:25 DEBUG cinder.volume.manager
[req-f51ade4d-5bed-4f24-b492-528b9baca625 cd7e95086cfc4693945f37e59c1b7206
67456c69ae074be4b4ba0af7048b5ceb] volume
volume-e224dfdb-913c-4135-811d-eb075a551de8: creating export create_volume
/usr/lib/python2.7/dist-packages/cinder/volume/manager.py:155
2012-10-22 10:58:25 28674 ERROR cinder.openstack.common.rpc.amqp [-]
Exception during message handling
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp Traceback
(most recent call last):
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/openstack/common/rpc/amqp.py",
line 276, in _process_data
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp     rval =
self.proxy.dispatch(ctxt, version, method, **args)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/openstack/common/rpc/dispatcher.py",
line 145, in dispatch
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp     return
getattr(proxyobj, method)(ctxt, **kwargs)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 163, in
create_volume
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
volume_ref['id'], {'status': 'error'})
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/contextlib.py", line 24, in __exit__
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
self.gen.next()
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 156, in
create_volume
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
model_update = self.driver.create_export(context, volume_ref)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/driver.py", line 380, in
create_export
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
volume_path)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/iscsi.py", line 112, in
create_iscsi_target
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
utils.ensure_tree(FLAGS.volumes_dir)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/utils.py", line 1049, in
ensure_tree
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
os.makedirs(path)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/os.py", line 157, in makedirs
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp
mkdir(name, mode)
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp OSError:
[Errno 13] Permission denied: '/usr/lib/python2.7/dist-packages/volumes'
2012-10-22 10:58:25 28674 TRACE cinder.openstack.common.rpc.amqp

Then I manually create directory "volumes" in
/usr/lib/python2.7/dist-packages" and give 777 to it
but error again:

2012-10-22 11:21:43 ERROR cinder.volume.iscsi
[req-d965ffd6-aff8-4c2d-b3c0-c6aaca4cebf0 cd7e95086cfc4693945f37e59c1b7206
67456c69ae074be4b4ba0af7048b5ceb] Failed to create iscsi target for volume
id:volume-a430f00e-53fa-44e9-9470-f604d63b88b8. Please ensure your tgtd
config file contains 'include /usr/lib/python2.7/dist-packages/volumes/*'
2012-10-22 11:21:43 28674 ERROR cinder.openstack.common.rpc.amqp [-]
Exception during message handling
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp Traceback
(most recent call last):
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/openstack/common/rpc/amqp.py",
line 276, in _process_data
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp     rval =
self.proxy.dispatch(ctxt, version, method, **args)
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/openstack/common/rpc/dispatcher.py",
line 145, in dispatch
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp     return
getattr(proxyobj, method)(ctxt, **kwargs)
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 163, in
create_volume
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp
volume_ref['id'], {'status': 'error'})
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/contextlib.py", line 24, in __exit__
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp
self.gen.next()
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/manager.py", line 156, in
create_volume
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp
model_update = self.driver.create_export(context, volume_ref)
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/driver.py", line 380, in
create_export
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp
volume_path)
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp   File
"/usr/lib/python2.7/dist-packages/cinder/volume/iscsi.py", line 148, in
create_iscsi_target
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp     raise
exception.NotFound()
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp NotFound:
Resource could not be found.
2012-10-22 11:21:43 28674 TRACE cinder.openstack.common.rpc.amqp

Do I need to cofiguration something in tgtd conf?


-- 
非淡薄无以明志,非宁静无以致远

Follow ups