Ask Your Question
1

Cannot attach volume to instance,"iscsiadm: No portal found"

asked 2013-12-07 02:46:36 -0500

PO gravatar image

I have Havana on Ubuntu12.04 server and 3 hosts (controller,compute and block).I manually install openstack according to the latest install edition(Havana). When I attach a volume to an instance,it reports error.Here is the error log.

nova-compute.log on compute node:

2013-12-07 16:21:20.705 1310 WARNING nova.virt.libvirt.volume [req-434f23c5-c3df-4c22-a972-e650e2734c6e 756f9fb88eff4347ac26c6f6c8bb99ca b3a3f286b9e74effb46a51d90028378f] ISCSI volume not yet found at: vdc. Will rescan & retry. Try number: 0 2013-12-07 16:21:20.750 1310 ERROR nova.compute.manager [req-434f23c5-c3df-4c22-a972-e650e2734c6e 756f9fb88eff4347ac26c6f6c8bb99ca b3a3f286b9e74effb46a51d90028378f] [instance: 2955c383-870a-449e-bfc0-c75e7d0f4bc9] Failed to attach volume 137931db-f379-47b4-b334-13160e7a827e at /dev/vdc ...... ProcessExecutionError: Unexpected error while running command. 2013-12-07 16:21:21.169 1310 TRACE nova.openstack.common.rpc.amqp Command: sudo nova-rootwrap /etc/nova/rootwrap.conf iscsiadm -m node -T iqn.2010-10.org.openstack:volume-137931db-f379-47b4-b334-13160e7a827e *-p 127.0.0.1:3260 --rescan* 2013-12-07 16:21:21.169 1310 TRACE nova.openstack.common.rpc.amqp Exit code: 255 2013-12-07 16:21:21.169 1310 TRACE nova.openstack.common.rpc.amqp Stdout: '' 2013-12-07 16:21:21.169 1310 TRACE nova.openstack.common.rpc.amqp Stderr: 'iscsiadm: No portal found.\n'

Then I check the /var/log/syslog on the compute node,it reports :

Dec 7 16:19:21 compute1 iscsid: connect to 127.0.0.1:3260 failed (Connection refused)

Dec 7 16:19:58 iscsid: last message repeated 9 times

I have a question why the iscsid do not connect to the block node,but connect to the 127.0.0.1. I use tgt and open-iscisi.

edit retag flag offensive close merge delete

2 answers

Sort by » oldest newest most voted
0

answered 2013-12-25 09:15:24 -0500

hunkar gravatar image

best answer: https://ask.openstack.org/en/question/130/why-do-i-get-no-portal-found-error-while-attaching-cinder-volume-to-vm/

edit flag offensive delete link more
0

answered 2013-12-07 05:04:14 -0500

darragh-oreilly gravatar image

You will need to add iscsi_ip_address with an address that is reachable from the compute nodes to the cinder.conf on the node running cinder-volume and restart that service. Then newly created cinder volumes should work. But pre-existing volumes will continue to have 127.0.0.1 in their name.

edit flag offensive delete link more

Comments

Thanks!It works!Does cinder-volume responsible for updating the cinder volumes status in the cinder database on the controller node?

PO gravatar imagePO ( 2013-12-08 19:28:23 -0500 )edit

I'm not sure, I haven't looked into it that much. But cinder-volume does interact directly with the database. I guess it does when long running backend operations complete or fail. But I guess cinder-api also sets the status sometimes.

darragh-oreilly gravatar imagedarragh-oreilly ( 2013-12-09 04:19:54 -0500 )edit

OK,I understand the cinder mechanism more clearly.I check the 'volumes' table in cinder database,this table has an attibute called ‘provider_location’ and it has a value ' 10.0.0.65:3260,5 iqn.2010-10.org.openstack:volume-ed181f7e-2cd8-489f-a5b4-aeac874fdf75 1 '.I think these records is written by cinder-volume.

PO gravatar imagePO ( 2013-12-09 20:04:07 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

2 followers

Stats

Asked: 2013-12-07 02:46:36 -0500

Seen: 2,825 times

Last updated: Dec 25 '13