Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Build of instance aborted: Block Device Mapping is Invalid.

This is the liberty version of an RDO allinone install of Openstack.

I added a cinder volume and compute node on a second server and add it in using the the add a node instructions on RDO website. I can make volumes on the new iscsi LVM storage but cant connect it to instances.

Message
    Build of instance 7fb7ebc8-3f0c-46f7-b958-ecc51023386a aborted: Block Device Mapping is Invalid.
Code
    500
Details

File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1905, in _do_build_and_run_instance filter_properties) File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2025, in _build_and_run_instance 'create.error', fault=e) File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 195, in __exit__ six.reraise(self.type_, self.value, self.tb) File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1996, in _build_and_run_instance block_device_mapping) as resources: File "/usr/lib64/python2.7/contextlib.py", line 17, in __enter__ return self.gen.next() File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2143, in _build_resources reason=e.format_message())


in the cinder/volume.logs in see:


2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher [req-b4927e11-9a2a-4e7c-b3da-bdb237e57cdd 840095061f9943be8f154eacbc3a784d f4446d45c1bf41c2b5869873f711809c - - -] Exception during message handling: Unexpected error while running command.
Command: None
Exit code: -
Stdout: u"Unexpected error while running command.\nCommand: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target\nExit code: 96\nStdout: u''\nStderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\\n'"
Stderr: None
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Traceback (most recent call last):
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     executor_callback))
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     executor_callback)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 129, in _do_dispatch
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     result = func(ctxt, **new_args)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     return f(*args, **kwargs)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/manager.py", line 1318, in initialize_connection
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     volume, connector)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     return f(*args, **kwargs)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/lvm.py", line 725, in create_export
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     volume_path)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/targets/iscsi.py", line 214, in create_export
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     **portals_config)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/targets/tgt.py", line 169, in create_iscsi_target
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     run_as_root=True)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/utils.py", line 155, in execute
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     return processutils.execute(*cmd, **kwargs)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_concurrency/processutils.py", line 275, in execute
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     cmd=sanitized_cmd)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher ProcessExecutionError: Unexpected error while running command.
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Command: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Exit code: 96
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Stdout: u''
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Stderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\n'
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher
2016-04-18 14:37:21.798 6535 ERROR oslo_messaging._drivers.common [req-b4927e11-9a2a-4e7c-b3da-bdb237e57cdd 840095061f9943be8f154eacbc3a784d f4446d45c1bf41c2b5869873f711809c - - -] Returning exception Unexpected error while running command.
Command: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target
Exit code: 96
Stdout: u''
Stderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\n' to caller

2016-04-18 14:37:21.799 6535 ERROR oslo_messaging._drivers.common [req-b4927e11-9a2a-4e7c-b3da-bdb237e57cdd 840095061f9943be8f154eacbc3a784d f4446d45c1bf41c2b5869873f711809c - - -] ['Traceback (most recent call last):\n', ' File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply\n executor_callback))\n', ' File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch\n executor_callback)\n', ' File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 129, in _do_dispatch\n result = func(ctxt, *new_args)\n', ' File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper\n return f(args, *kwargs)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/manager.py", line 1318, in initialize_connection\n volume, connector)\n', ' File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper\n return f(args, *kwargs)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/lvm.py", line 725, in create_export\n volume_path)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/targets/iscsi.py", line 214, in create_export\n *portals_config)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/targets/tgt.py", line 169, in create_iscsi_target\n run_as_root=True)\n', ' File "/usr/lib/python2.7/site-packages/cinder/utils.py", line 155, in execute\n return processutils.execute(cmd, *kwargs)\n', ' File "/usr/lib/python2.7/site-packages/oslo_concurrency/processutils.py", line 275, in execute\n cmd=sanitized_cmd)\n', "ProcessExecutionError: Unexpected error while running command.\nCommand: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target\nExit code: 96\nStdout: u''\nStderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\n'\n"]


my cinder.conf is already changed to look like the one i found on this site:

http://www.marksei.com/openstack-cant-attach-cinder-volume/

which looks closely to this:

[my_hard_disk_backend]
volume_group=hard_disk_backend
volume_driver=cinder.volume.drivers.lvm.LVMVolumeDriver
volume_backend_name=lvm_hard_disk
iscsi_helper=lioadm

Build of instance aborted: Block Device Mapping is Invalid.

This is the liberty version of an RDO allinone install of Openstack.

I added a cinder volume and compute node on a second server and add it in using the the add a node instructions on RDO website. I can make volumes on the new iscsi LVM storage but cant connect it to instances.

Message
    Build of instance 7fb7ebc8-3f0c-46f7-b958-ecc51023386a aborted: Block Device Mapping is Invalid.
Code
    500
Details

File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1905, in _do_build_and_run_instance filter_properties) File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2025, in _build_and_run_instance 'create.error', fault=e) File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 195, in __exit__ six.reraise(self.type_, self.value, self.tb) File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 1996, in _build_and_run_instance block_device_mapping) as resources: File "/usr/lib64/python2.7/contextlib.py", line 17, in __enter__ return self.gen.next() File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2143, in _build_resources reason=e.format_message())


reason=e.format_message())

in the cinder/volume.logs in see:


2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher [req-b4927e11-9a2a-4e7c-b3da-bdb237e57cdd 840095061f9943be8f154eacbc3a784d f4446d45c1bf41c2b5869873f711809c - - -] Exception during message handling: Unexpected error while running command.
Command: None
Exit code: -
Stdout: u"Unexpected error while running command.\nCommand: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target\nExit code: 96\nStdout: u''\nStderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\\n'"
Stderr: None
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Traceback (most recent call last):
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     executor_callback))
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     executor_callback)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 129, in _do_dispatch
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     result = func(ctxt, **new_args)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     return f(*args, **kwargs)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/manager.py", line 1318, in initialize_connection
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     volume, connector)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     return f(*args, **kwargs)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/lvm.py", line 725, in create_export
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     volume_path)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/targets/iscsi.py", line 214, in create_export
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     **portals_config)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/targets/tgt.py", line 169, in create_iscsi_target
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     run_as_root=True)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/utils.py", line 155, in execute
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     return processutils.execute(*cmd, **kwargs)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/oslo_concurrency/processutils.py", line 275, in execute
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher     cmd=sanitized_cmd)
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher ProcessExecutionError: Unexpected error while running command.
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Command: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Exit code: 96
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Stdout: u''
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher Stderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\n'
2016-04-18 14:37:21.790 6535 ERROR oslo_messaging.rpc.dispatcher
2016-04-18 14:37:21.798 6535 ERROR oslo_messaging._drivers.common [req-b4927e11-9a2a-4e7c-b3da-bdb237e57cdd 840095061f9943be8f154eacbc3a784d f4446d45c1bf41c2b5869873f711809c - - -] Returning exception Unexpected error while running command.
Command: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target
Exit code: 96
Stdout: u''
Stderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\n' to caller

2016-04-18 14:37:21.799 6535 ERROR oslo_messaging._drivers.common [req-b4927e11-9a2a-4e7c-b3da-bdb237e57cdd 840095061f9943be8f154eacbc3a784d f4446d45c1bf41c2b5869873f711809c - - -] ['Traceback (most recent call last):\n', ' File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 142, in _dispatch_and_reply\n executor_callback))\n', ' File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 186, in _dispatch\n executor_callback)\n', ' File "/usr/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 129, in _do_dispatch\n result = func(ctxt, *new_args)\n', **new_args)\n', ' File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper\n return f(args, *kwargs)\n', f(*args, **kwargs)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/manager.py", line 1318, in initialize_connection\n volume, connector)\n', ' File "/usr/lib/python2.7/site-packages/osprofiler/profiler.py", line 105, in wrapper\n return f(args, *kwargs)\n', f(*args, **kwargs)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/drivers/lvm.py", line 725, in create_export\n volume_path)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/targets/iscsi.py", line 214, in create_export\n *portals_config)\n', **portals_config)\n', ' File "/usr/lib/python2.7/site-packages/cinder/volume/targets/tgt.py", line 169, in create_iscsi_target\n run_as_root=True)\n', ' File "/usr/lib/python2.7/site-packages/cinder/utils.py", line 155, in execute\n return processutils.execute(cmd, *kwargs)\n', processutils.execute(*cmd, **kwargs)\n', ' File "/usr/lib/python2.7/site-packages/oslo_concurrency/processutils.py", line 275, in execute\n cmd=sanitized_cmd)\n', "ProcessExecutionError: Unexpected error while running command.\nCommand: sudo cinder-rootwrap /etc/cinder/rootwrap.conf tgtadm --lld iscsi --op show --mode target\nExit code: 96\nStdout: u''\nStderr: u'/usr/bin/cinder-rootwrap: Executable not found: tgtadm (filter match = tgtadm)\n'\n"]


tgtadm)\\n'\n"]

my cinder.conf is already changed to look like the one i found on this site:

http://www.marksei.com/openstack-cant-attach-cinder-volume/

which looks closely to this:

[my_hard_disk_backend]
volume_group=hard_disk_backend
volume_driver=cinder.volume.drivers.lvm.LVMVolumeDriver
volume_backend_name=lvm_hard_disk
iscsi_helper=lioadm