In nova.db.sqlalchemy.model.ComputeNode, column hypervisor_hostname should be unique values

Bug #1329299 reported by Kanagaraj Manickam
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Expired
Undecided
Unassigned

Bug Description

In the nova model nova.db.sqlalchemy.model.ComputeNode, the column represents the hypervisor name and is not set to unique and not null values. This leads to have same hyerpvisor host name for more than one hypervisors and will end up in error scenarios.

In order to avoid the this scenario, column should be set to following values
nullable=False
unique=True

This bug is filed to address the same.

Tags: db
Changed in nova:
assignee: nobody → Kanagaraj Manickam (kanagaraj-manickam)
Tracy Jones (tjones-i)
tags: added: db
Sean Dague (sdague)
tags: added: low-hanging-fruit
Changed in nova:
status: New → Confirmed
importance: Undecided → Low
assignee: Kanagaraj Manickam (kanagaraj-manickam) → nobody
Revision history for this message
Kanagaraj Manickam (kanagaraj-manickam) wrote :

Hi Sean Dague,

This defect will affect almost all hypervisors and it will mandates lots of unit testing to be done across all the hypervisor supported drivers. so I am waiting for kilo to open up for the putting the code changes.

Also i am investigating whether we need to make this as blue print, kindly suggest. Thanks.

Changed in nova:
assignee: nobody → Kanagaraj Manickam (kanagaraj-manickam)
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/187844

Changed in nova:
assignee: Kanagaraj Manickam (kanagaraj-manickam) → Auktavian Garrett (augarret)
status: Confirmed → In Progress
Revision history for this message
Auktavian Garrett (augarret) wrote :

This code review fixes failing test cases made by changing hypervisor_hostname db column to nullable=False and unique=True. These test cases do not necessarily test that functionality.
Should separate test cases be created to test this functionality? Nullable hypervisor_hostname columns created within the db was causing failures before

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on nova (master)

Change abandoned by Michael Still (<email address hidden>) on branch: master
Review: https://review.openstack.org/187844
Reason: This patch has been stalled for quite a while, so I am going to abandon it to keep the code review queue sane. Please restore the change when it is ready for review.

fayaz (fayaz-912)
Changed in nova:
assignee: Auktavian Garrett (augarret) → fayaz (fayaz-912)
Changed in nova:
assignee: fayaz (fayaz-912) → nobody
status: In Progress → Confirmed
fayaz (fayaz-912)
Changed in nova:
assignee: nobody → fayaz (fayaz-912)
Revision history for this message
Sean Dague (sdague) wrote :

Please do not assign yourself to a bug unless you have pushed up a real patch on this.

Changed in nova:
assignee: fayaz (fayaz-912) → nobody
Revision history for this message
Markus Zoeller (markus_z) (mzoeller) wrote :

The age and number of assignee changes suggest that this isn't really
a low-hanging-fruit. I'm removing the tag to not confuse new folks who
are searching for that tag.

tags: removed: low-hanging-fruit
Revision history for this message
Markus Zoeller (markus_z) (mzoeller) wrote : Cleanup EOL bug report

This is an automated cleanup. This bug report has been closed because it
is older than 18 months and there is no open code change to fix this.
After this time it is unlikely that the circumstances which lead to
the observed issue can be reproduced.

If you can reproduce the bug, please:
* reopen the bug report (set to status "New")
* AND add the detailed steps to reproduce the issue (if applicable)
* AND leave a comment "CONFIRMED FOR: <RELEASE_NAME>"
  Only still supported release names are valid (LIBERTY, MITAKA, OCATA, NEWTON).
  Valid example: CONFIRMED FOR: LIBERTY

Changed in nova:
importance: Low → Undecided
status: Confirmed → Expired
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.