[Openstack] Bug launching instance in Essex packages on Precise - for nw, info in nw_info: too many values to unpack (network/manager.py)

Jason Kölker jkoelker at rackspace.com
Tue Feb 14 21:14:18 UTC 2012


On Tue, 2012-02-14 at 20:43 +0000, Kevin Jackson wrote:
> Dear cloud folk,
> I raised https://bugs.launchpad.net/nova/+bug/928819 last week that's
> not getting any love so was wondering if it was user error rather than
> a bug (as its a show stopper for my setup that I previously didn't
> have).

I think this diff might fix it:

diff --git a/nova/network/manager.py b/nova/network/manager.py
index e42e066..502baba 100644
--- a/nova/network/manager.py
+++ b/nova/network/manager.py
@@ -299,10 +299,8 @@ class FloatingIP(object):
             self.db.floating_ip_set_auto_assigned(context,
floating_address)
 
             # get the first fixed address belonging to the instance
-            for nw, info in nw_info:
-                if info.get('ips'):
-                    fixed_address = info['ips'][0]['ip']
-                    break
+            fixed_ips = nw_info.fixed_ips()
+            fixed_address = fixed_ips[0]['address']
 
             # associate the floating ip to fixed_ip
             self.associate_floating_ip(context,

I unfortunately do not have the setup to test it. If it works for you
let me know, and I'll merge prop it to trunk.

Happy Hacking!

7-11





More information about the Openstack mailing list