'nova-manage fixed list' causes AttributeError: 'FixedIp' object has no attribute 'instance'

Bug #920159 reported by Dan Prince
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Dan Prince

Bug Description

Using the latest version of nova Essex:

root@nova1:~# nova-manage fixed list
network IP address MAC address hostname host
Command failed, please check log for more info
2012-01-22 20:49:56,460 CRITICAL nova [req-50d5a6c7-6572-471d-8318-f2a84ea7931d None None] 'FixedIp' object has no attribute 'instance'
(nova): TRACE: Traceback (most recent call last):
(nova): TRACE: File "/usr/bin/nova-manage", line 2386, in <module>
(nova): TRACE: main()
(nova): TRACE: File "/usr/bin/nova-manage", line 2374, in main
(nova): TRACE: fn(*fn_args, **fn_kwargs)
(nova): TRACE: File "/usr/bin/nova-manage", line 649, in list
(nova): TRACE: if fixed_ip['instance']:
(nova): TRACE: File "/usr/lib/python2.7/dist-packages/nova/db/sqlalchemy/models.py", line 75, in __getitem__
(nova): TRACE: return getattr(self, key)
(nova): TRACE: AttributeError: 'FixedIp' object has no attribute 'instance'
(nova): TRACE:

Dan Prince (dan-prince)
Changed in nova:
assignee: nobody → Dan Prince (dan-prince)
importance: Undecided → Medium
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

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

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

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

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

Reviewed: https://review.openstack.org/3314
Committed: http://github.com/openstack/nova/commit/151632ed3a8dfd8da1812e738aca16187dec1175
Submitter: Jenkins
Branch: master

commit 151632ed3a8dfd8da1812e738aca16187dec1175
Author: Dan Prince <email address hidden>
Date: Mon Jan 23 14:51:24 2012 -0500

    Fixes nova-manage fixed list.

    Updates the nova-manage to use db.instance_get_all for instance
    information instead of relying on Sqlalchemy model relationships
    (which no longer exist due to network refactorings).

    This commit fixes 'nova-manage fixed list' so that it correctly
    displays hostname, and host. I dropped the MAC address column
    which would have required an extra VIF's table lookup and
    wasn't used as much.

    Fixes LP Bug #920159.

    Change-Id: I3cec690c5e40631e0f10b2a914f46863601a1734

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → essex-3
status: Fix Committed → Fix Released
Revision history for this message
Christopher Stender (cstender) wrote :

I can still reproduce the bug. It looks like the second patch was not merged into master.

Revision history for this message
Brian Haley (brian-haley) wrote :

I see this problem as well, but I verified my nova-manage has the second patch (and it's in essex-3 and master, commit 151632ed3a8dfd8da1812e738aca16187dec1175). I'm running the latest Essex-3 code.

Revision history for this message
Christopher Stender (cstender) wrote :

Sorry, I meant the first patch (sqlalchemy) is not in master.

Revision history for this message
Brian Haley (brian-haley) wrote :

It looked like the first patch was abandoned for some reason, we'll have to wait for Dan to take a look.

Thierry Carrez (ttx)
Changed in nova:
milestone: essex-3 → 2012.1
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.