How to reproduce:
1. enable Glusterfs as manila-share backend
2. create a share
Result:
Share creation failed with error message :
2014-12-23 13:55:41.914 DEBUG oslo_concurrency.processutils [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] Running cmd (subprocess): sudo manila-rootwrap /etc/manila/rootwrap.
conf mkdir /opt/stack/data/manila/mnt/chen-volume0/share-f1ade0fe-b7b3-449b-b0de-3e576ef00cef from (pid=13971) execute /usr/local/lib/python2.7/dist-packages/oslo_concurrency/processutils.py:191
2014-12-23 13:55:41.974 DEBUG oslo_concurrency.processutils [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] CMD "sudo manila-rootwrap /etc/manila/rootwrap.conf mkdir /opt/stack
/data/manila/mnt/chen-volume0/share-f1ade0fe-b7b3-449b-b0de-3e576ef00cef" returned: 96 in 0.0601711273193s from (pid=13971) execute /usr/local/lib/python2.7/dist-packages/oslo_concurrency/processutils.py:216
2014-12-23 13:55:41.976 DEBUG oslo_concurrency.processutils [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] u'sudo manila-rootwrap /etc/manila/rootwrap.conf mkdir /opt/stack/data/manila/mnt/chen-volume0/share-f1ade0fe-b7b3-449b-b0de-3e576ef00cef' failed. Not Retrying. from (pid=13971) execute /usr/local/lib/python2.7/dist-packages/oslo_concurrency/processutils.py:249
2014-12-23 13:55:41.980 ERROR manila.share.drivers.glusterfs [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] Unable to create share share-f1ade0fe-b7b3-449b-b0de-3e576ef00cef
2014-12-23 13:55:41.981 ERROR manila.share.manager [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] Share f1ade0fe-b7b3-449b-b0de-3e576ef00cef failed on creation.
2014-12-23 13:55:41.982 WARNING manila.share.manager [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] Share information in exception can not be written to db because it contains {} and it is not a dictionary.
2014-12-23 13:55:42.51 ERROR oslo.messaging.rpc.dispatcher [req-bc9925b2-145d-499e-bafa-7b0f67638e84 4b779d3b969e45e193031cc55871db58 e6e25896426740e6a6625d0b5d073e59] Exception during message handling: Unexpected error while running command.
Command: sudo manila-rootwrap /etc/manila/rootwrap.conf mkdir /opt/stack/data/manila/mnt/chen-volume0/share-f1ade0fe-b7b3-449b-b0de-3e576ef00cef
Exit code: 96
Stdout: u''
Stderr: u'/usr/local/bin/manila-rootwrap: Executable not found: /usr/bin/mkdir (filter match = mkdir)\n'
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher Traceback (most recent call last):
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo/messaging/rpc/dispatcher.py", line 137, in _dispatch_and_reply
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher incoming.message))
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo/messaging/rpc/dispatcher.py", line 180, in _dispatch
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher return self._do_dispatch(endpoint, method, ctxt, args)
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo/messaging/rpc/dispatcher.py", line 126, in _do_dispatch
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher result = getattr(endpoint, method)(ctxt, **new_args)
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/opt/stack/manila/manila/share/manager.py", line 291, in create_share
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher self.db.share_update(context, share_id, {'status': 'error'})
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/usr/local/lib/python2.7/dist-packages/oslo/utils/excutils.py", line 82, in __exit__
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher six.reraise(self.type_, self.value, self.tb)
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/opt/stack/manila/manila/share/manager.py", line 274, in create_share
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher context, share_ref, share_server=share_server)
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher File "/opt/stack/manila/manila/share/drivers/glusterfs.py", line 312, in create_share
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher raise exception.GlusterfsException(exc)
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher GlusterfsException: Unexpected error while running command.
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher Command: sudo manila-rootwrap /etc/manila/rootwrap.conf mkdir /opt/stack/data/manila/mnt/chen-volume0/share-f1ade0fe-b7b3-449b-b0de-3e576ef00cef
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher Exit code: 96
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher Stdout: u''
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher Stderr: u'/usr/local/bin/manila-rootwrap: Executable not found: /usr/bin/mkdir (filter match = mkdir)\n'
2014-12-23 13:55:42.51 TRACE oslo.messaging.rpc.dispatcher
Fix proposed to branch: master /review. openstack. org/143606
Review: https:/