Instance shutdown with libvirt hammers the DB
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Low
|
Josh Kearney |
Bug Description
Here's the code that gets executed while an instance is being shut down (blamar has a fix pending for the instance state logic being flawed). I believe this loop hammers the DB (and libvirt / kvm) and there really should be (1) a sleep in there to avoid hammering libvirt and (2) something that doesn't hit the DB on every iteration (maybe don't update unless the state has changed?)
while True:
try:
if state == power_state.
except Exception:
Related branches
- Rick Harris (community): Approve
- Vish Ishaya (community): Approve
- Devin Carlen (community): Approve
-
Diff: 13 lines (+3/-0)1 file modifiednova/virt/libvirt_conn.py (+3/-0)
Changed in nova: | |
importance: | Undecided → Low |
status: | New → Confirmed |
Changed in nova: | |
status: | Confirmed → In Progress |
assignee: | nobody → Josh Kearney (jk0) |
Changed in nova: | |
milestone: | none → cactus-rc |
Changed in nova: | |
status: | In Progress → Fix Committed |
Changed in nova: | |
milestone: | cactus-rc → 2011.2 |
status: | Fix Committed → Fix Released |
Much agreed. At the very least, a sleep should be inserted in the loop...