<div class="gmail_quote"><font face="arial, helvetica, sans-serif">I have os-create-server</font> but nova-client management does not accept the <font face="arial, helvetica, sans-serif">"--nic" option, as you said, Dan.<br>
<br>When I instantiate a vm, it is created but no IP is assigned to it, thus, it does not change status to ACTIVE. Though </font><font face="arial, helvetica, sans-serif">I can't access the vm</font><font face="arial, helvetica, sans-serif">, I can attach the vm vif to a network port (using bin/cli plug_iface).<br>




<br>Quantum should give an IP to the vm</font> just while it is being created or IP must be only assigned to the vif afterward? If afterwad, how to do this?<br><br><font face="arial, helvetica, sans-serif">Best regards,<br>

</font><div class="HOEnZb"><div class="h5"><br>

<div class="gmail_quote">2012/1/17 Dan Wendlandt <span dir="ltr"><<a href="mailto:dan@nicira.com" target="_blank">dan@nicira.com</a>></span><br>




<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br><br><div class="gmail_quote"><div>On Tue, Jan 17, 2012 at 3:03 AM, Alisson Soares Limeira Pontes <span dir="ltr"><<a href="mailto:apontes@cpqd.com.br" target="_blank">apontes@cpqd.com.br</a>></span> wrote:<br>









<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

Yes Dan, you are right.<br>I am using the stackOps distro, and the network 1 was created before quantum instalation, i don't know how neather why. </blockquote><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">











<br>Now I have these two networks<br><br>root@nova-controller:~/quantum-2011.3# nova-manage network list<div><br>
id       IPv4                  IPv6               start address      DNS1               DNS2               VlanID             project            uuid           <br></div>3        <a href="http://192.168.1.160/27" target="_blank">192.168.1.160/27</a>      None               192.168.1.162      8.8.4.4            None               None               None               85b629fc-7fec-4fdd-b842-76a3711e83d9<br>












4        <a href="http://192.168.1.128/27" target="_blank">192.168.1.128/27</a>      None               192.168.1.130      8.8.4.4            None               None               None               a52b0d7b-791a-4e81-8772-8df04b9ccd70<br>












<br>Anyone knows how can i instantiate a vm and associate it to one of these networks?</blockquote><div><br></div></div><div><font face="arial, helvetica, sans-serif">You can use the os-create-server extension to do this.  We recently added support for this extension to the nova client utility using the "--nic" option, though I believe it only went in during Essex-2, so I'm not sure if it would be in a distro like StackOps yet.  <span style="line-height:20px">The following command would create a VM connected to quantum network </span><span style="font-size:13px;line-height:20px">0c02f3d3-204a-4e37-b820-5d15e6d74a9f.</span> : </font></div>











<div><font face="arial, helvetica, sans-serif"><br></font></div><div><span style="font-size:13px;line-height:20px"><font face="arial, helvetica, sans-serif">nova boot --flavor 1 --image 07f3c46c-5062-4837-b43d-ec1a93b894dc --nic net-id=0c02f3d3-204a-4e37-b820-5d15e6d74a9f test1</font></span></div>









<span><font color="#888888">

<div><span style="font-size:13px;line-height:20px"><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span style="font-size:13px;line-height:20px"><font face="arial, helvetica, sans-serif">Dan</font></span><span style="font-family:Verdana,Geneva,sans-serif;font-size:13px;line-height:20px"> </span></div>









</font></span><div><div>

<div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><br><br><div class="gmail_quote">2012/1/12 Dan Wendlandt <span dir="ltr"><<a href="mailto:dan@nicira.com" target="_blank">dan@nicira.com</a>></span><br>












<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span><font face="arial, helvetica, sans-serif">Hi Alisson,</font></span><div><span><font face="arial, helvetica, sans-serif"><br>












</font></span></div>

<div><span><font face="arial, helvetica, sans-serif">I assume you are following the directions as described at: <a href="http://docs.openstack.org/incubation/openstack-network/admin/content/index.html" target="_blank">http://docs.openstack.org/incubation/openstack-network/admin/content/index.html</a>?  </font></span></div>















<div><span><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span><font face="arial, helvetica, sans-serif">If so, then you have QuantumManager enabled in Nova and when you ran "nova-manage create network", this should have reached out to quantum to create a network, then stash that quantum network uuid in the nova db for future use.   </font></span></div>















<div><span><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span><font face="arial, helvetica, sans-serif">Can you try accessing quantum directly to see if that networks exist?  Since you did not specify a "--project" when creating the network with nova-manage, QuantumManager will create the network with a quantum tenant-id set to the --<span style="line-height:16px;font-size:12px;white-space:pre-wrap">quantum_default_tenant_id flag (defaults to "default").</span></font></span></div>















<div><span style="line-height:16px;font-size:12px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span style="line-height:16px;font-size:12px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif">So assuming the default, try running: </font></span></div>















<div><span style="line-height:16px;font-size:12px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span style="line-height:16px;font-size:12px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif">bin/cli list_nets default </font></span></div>















<div><span style="line-height:16px;font-size:12px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span style="line-height:16px;font-size:12px;white-space:pre-wrap"><font face="arial, helvetica, sans-serif">What networks does this show?  </font></span></div>















<div><span><font face="arial, helvetica, sans-serif"><br></font></span></div><div><span><font face="arial, helvetica, sans-serif"><span>My best guess is that it will show only a single network: cbbbf92d-26d3-4a8d-8394-</span><span>bb173fc35cbb, meaning one of your two nova networks show above was not created on Quantum.  Is it possible that you created that network before enabling QuantumManager using the --network_manager flag?  If so, you would need to delete that old network, and recreate it while Nova is using Quantum Manager.  If both were created with QuantumManager enabled, then it is possible one of them failed.  Can you find the network manager logs from the period when you ran the 'nova-manage create network' commands? </span></font></span></div>















<div><span><font face="arial, helvetica, sans-serif"><br></font></span></div><div><font face="arial, helvetica, sans-serif">Thanks,</font></div>

<div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">Dan</font></div>
<div><br><br><div class="gmail_quote"><div><div>On Thu, Jan 12, 2012 at 7:18 AM, Alisson Soares Limeira Pontes <span dir="ltr"><<a href="mailto:apontes@cpqd.com.br" target="_blank">apontes@cpqd.com.br</a>></span> wrote:<br>













</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>Hello everyone,<br><br>I need some help to instantiate an image and associate it to a quantum network.<br>












<br>I installed a dual node OpenStack.diablo setup (controller and compute), which worked fine for instantiate a vm. <br>




Then, I installed OVS and Quantum. It seems that Quantum is working because I can create a network and attach an interface to it using $ python quantum/bin/cli:<br><br>$ python bin/cli plug_iface $TENANT $NETWORK $PORT $VIF_UUID<br>

















Plugged interface "foo" to port:5a1e121b-ccc8-471d-9445-24f15f9f854c on network:e754e7c0-a8eb-40e5-861a-b182d30c3441<br><br>I also can create a network using nova-manage:<br><br>root@nova-controller:~/quantum-2011.3# /var/lib/nova/bin/nova-manage network create --label=public --fixed_range_v4=<a href="http://192.168.1.144/28" target="_blank">192.168.1.144/28</a><br>

















<br>root@nova-controller:~/quantum-2011.3# /var/lib/nova/bin/nova-manage network list<br>id       IPv4                  IPv6               start address      DNS1               DNS2               VlanID         project            uuid           <br>

















1        <a href="http://192.168.1.128/28" target="_blank">192.168.1.128/28</a>      None               192.168.1.130      8.8.8.8            8.8.4.4            None           None               None           <br>3        <a href="http://192.168.1.144/28" target="_blank">192.168.1.144/28</a>      None               192.168.1.146      8.8.4.4            None               None           None               cbbbf92d-26d3-4a8d-8394-bb173fc35cbb<br>

















<br>But when I try to boot a vm it remains in build status forever.<br>The nova-network.log and nova-compute.log are below. <br>It seems that the image cannot run because I did not assign a network to it, isn't it? <br>

















How can I do this, I looked at the Quantum API (PUT, GET, POST...) but i can't use it, is it a user API or an API for communication between nova and quantum? I also did not see how to associate a vm to a network using nova-manage.<br>

















<br>NOVA-NETWORK.LOG<br><a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,424 DEBUG nova.network.quantum.quantum_connection [-] Quantum Client Reply (code = 420) :<br> {"networkNotFound": {"message": "Unable to find a network with the specified identifier.", "code": 420, "detail": "Network None could not be found"}} from (pid=933) do_request /var/lib/nova/nova/network/quantum/client.py:187<br>

















<a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,424 ERROR nova.rpc [-] Exception during message handling<br>(nova.rpc): TRACE: Traceback (most recent call last):<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/rpc/impl_kombu.py", line 620, in _process_data<br>

















(nova.rpc): TRACE:     rval = node_func(context=ctxt, **node_args)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/network/quantum/manager.py", line 175, in allocate_for_instance<br>(nova.rpc): TRACE:     vif_rec['uuid'])<br>

















(nova.rpc): TRACE:   File "/var/lib/nova/nova/network/quantum/quantum_connection.py", line 86, in create_and_attach_port<br>(nova.rpc): TRACE:     resdict = self.client.create_port(net_id, port_data, tenant=tenant_id)<br>

















(nova.rpc): TRACE:   File "/var/lib/nova/nova/network/quantum/client.py", line 81, in with_params<br>(nova.rpc): TRACE:     ret = self.func(instance, *args)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/network/quantum/client.py", line 277, in create_port<br>

















(nova.rpc): TRACE:     return self.do_request("POST", self.ports_path % (network), body=body)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/network/quantum/client.py", line 202, in do_request<br>(nova.rpc): TRACE:     % locals()))<br>

















(nova.rpc): TRACE: QuantumServerException: Server 420 error: {"networkNotFound": {"message": "Unable to find a network with the specified identifier.", "code": 420, "detail": "Network None could not be found"}}<br>

















(nova.rpc): TRACE:<br><a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,425 ERROR nova.rpc [-] Returning exception Server 420 error: {"networkNotFound": {"message": "Unable to find a network with the specified identifier.", "code": 420, "detail": "Network None could not be found"}} to caller<br>

















<a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,425 ERROR nova.rpc [-] ['Traceback (most recent call last):\n', '  File "/var/lib/nova/nova/rpc/impl_kombu.py", line 620, in _process_data\n    rval = node_func(context=ctxt, **node_args)\n', '  File "/var/lib/nova/nova/network/quantum/manager.py", line 175, in allocate_for_instance\n    vif_rec[\'uuid\'])\n', '  File "/var/lib/nova/nova/network/quantum/quantum_connection.py", line 86, in create_and_attach_port\n    resdict = self.client.create_port(net_id, port_data, tenant=tenant_id)\n', '  File "/var/lib/nova/nova/network/quantum/client.py", line 81, in with_params\n    ret = self.func(instance, *args)\n', '  File "/var/lib/nova/nova/network/quantum/client.py", line 277, in create_port\n    return self.do_request("POST", self.ports_path % (network), body=body)\n', '  File "/var/lib/nova/nova/network/quantum/client.py", line 202, in do_request\n    % locals()))\n', 'QuantumServerException: Server 420 error: {"networkNotFound": {"message": "Unable to find a network with the specified identifier.", "code": 420, "detail": "Network None could not be found"}}\n']<br>

















<br><br><br>NOVA-COMPUTE.LOG<br><a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,122 AUDIT nova.compute.manager [962c3edc-00c4-4c6e-8ba6-bc4deb70e3f3 demo 2] instance 6: starting...<br>
















<a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,236 DEBUG nova.rpc [-] Making asynchronous call on network ... from (pid=1125) multicall /var/lib/nova/nova/rpc/impl_kombu.py:721<br>

















<a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,236 DEBUG nova.rpc [-] MSG_ID is 9e30ba1a6d944a21a839e00dde9bc128 from (pid=1125) multicall /var/lib/nova/nova/rpc/impl_kombu.py:724<br>
















<a href="tel:2012-01-12%2012" value="+12012011212" target="_blank">2012-01-12 12</a>:15:51,508 ERROR nova.rpc [-] Exception during message handling<br>
(nova.rpc): TRACE: Traceback (most recent call last):<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/rpc/impl_kombu.py", line 620, in _process_data<br>(nova.rpc): TRACE:     rval = node_func(context=ctxt, **node_args)<br>

















(nova.rpc): TRACE:   File "/var/lib/nova/nova/exception.py", line 98, in wrapped<br>(nova.rpc): TRACE:     return f(*args, **kw)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/compute/manager.py", line 480, in run_instance<br>

















(nova.rpc): TRACE:     self._run_instance(context, instance_id, **kwargs)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/compute/manager.py", line 421, in _run_instance<br>(nova.rpc): TRACE:     network_info = _make_network_info()<br>

















(nova.rpc): TRACE:   File "/var/lib/nova/nova/compute/manager.py", line 377, in _make_network_info<br>(nova.rpc): TRACE:     requested_networks=requested_networks)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/network/api.py", line 162, in allocate_for_instance<br>

















(nova.rpc): TRACE:     'args': args})<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/rpc/__init__.py", line 45, in call<br>(nova.rpc): TRACE:     return get_impl().call(context, topic, msg)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/rpc/impl_kombu.py", line 739, in call<br>

















(nova.rpc): TRACE:     rv = list(rv)<br>(nova.rpc): TRACE:   File "/var/lib/nova/nova/rpc/impl_kombu.py", line 703, in __iter__<br>(nova.rpc): TRACE:     raise result<br>(nova.rpc): TRACE: RemoteError: QuantumServerException Server 420 error: {"networkNotFound": {"message": "Unable to find a network with the specified identifier.", "code": 420, "detail": "Network None could not be found"}}<br>

















(nova.rpc): TRACE: [u'Traceback (most recent call last):\n', u'  File "/var/lib/nova/nova/rpc/impl_kombu.py", line 620, in _process_data\n    rval = node_func(context=ctxt, **node_args)\n', u'  File "/var/lib/nova/nova/network/quantum/manager.py", line 175, in allocate_for_instance\n    vif_rec[\'uuid\'])\n', u'  File "/var/lib/nova/nova/network/quantum/quantum_connection.py", line 86, in create_and_attach_port\n    resdict = self.client.create_port(net_id, port_data, tenant=tenant_id)\n', u'  File "/var/lib/nova/nova/network/quantum/client.py", line 81, in with_params\n    ret = self.func(instance, *args)\n', u'  File "/var/lib/nova/nova/network/quantum/client.py", line 277, in create_port\n    return self.do_request("POST", self.ports_path % (network), body=body)\n', u'  File "/var/lib/nova/nova/network/quantum/client.py", line 202, in do_request\n    % locals()))\n', u'QuantumServerException: Server 420 error: {"networkNotFound": {"message": "Unable to find a network with the specified identifier.", "code": 420, "detail": "Network None could not be found"}}\n']<br>

















<br><br>Thanks in advance.<span><font color="#888888"><br></font></span></div></div></blockquote></div></div></blockquote></div></div></div></blockquote></div></div></div><br></blockquote></div><br></div></div></div>-- <br>
Alisson Pontes<br><br><br>