Executable not found for mkdir

Bug #1405068 reported by li,chen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
High
li,chen

Bug Description

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila (master)

Fix proposed to branch: master
Review: https://review.openstack.org/143606

Changed in manila:
assignee: nobody → li,chen (chen-li)
status: New → In Progress
Changed in manila:
importance: Undecided → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

Reviewed: https://review.openstack.org/143606
Committed: https://git.openstack.org/cgit/openstack/manila/commit/?id=24522522560ac9baf32552055c4218cbea2aa17c
Submitter: Jenkins
Branch: master

commit 24522522560ac9baf32552055c4218cbea2aa17c
Author: chen-li <email address hidden>
Date: Tue Dec 23 14:41:31 2014 +0800

    Strip exec_dirs prefix from rootwrap filters

    Rootwrap supports for a configurable set of trusted
    directories to search executables in (exec_dirs),
    which defaults to system PATH.

    Make the rootwrap filters more portable by removing
    the explicit exec_dirs prefix from them. This allows
    a binary to be installed in any of the exec_dirs and
    still be used by rootwrap, which improves cross-distro
    portability.

    Change-Id: I9a346c0fcddc7ac8af50f72df6d401b5079e4d58
    Closes-Bug: #1405068

Changed in manila:
status: In Progress → Fix Committed
Changed in manila:
milestone: none → kilo-2
Thierry Carrez (ttx)
Changed in manila:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in manila:
milestone: kilo-2 → 2015.1.0
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.