Bug 1234461

Summary: RFE: add instance uuid column to nova.quota_usages table
Product: Red Hat OpenStack Reporter: Dan Yocum <dyocum>
Component: openstack-novaAssignee: Eoghan Glynn <eglynn>
Status: CLOSED ERRATA QA Contact: Prasanth Anbalagan <panbalag>
Severity: low Docs Contact:
Priority: low    
Version: 5.0 (RHEL 6)CC: berrange, dasmith, eglynn, jschluet, kchamart, mwitt, panbalag, sbauza, sferdjao, sgordon, srevivo, vromanso
Target Milestone: betaKeywords: FutureFeature, Triaged
Target Release: 10.0 (Newton)   
Hardware: Unspecified   
OS: Unspecified   
URL: https://blueprints.launchpad.net/nova/+spec/refresh-quotas-usage
Whiteboard: upstream_milestone_newton-2 upstream_definition_approved upstream_status_implemented
Fixed In Version: openstack-nova-14.0.0-0.20160726054215.02421fc.el7ost Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-12-14 15:13:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Dan Yocum 2015-06-22 15:05:39 UTC
he nova.quota_usages table frequently gets out-of-sync with the currently active/stopped instances in a tenant/project, specifically, there are times when the instance will be set to terminated/deleted in the instances table and the quota_usages table will retain the data, counting against the tenant's total quota. As far as I can tell there is no way to correlate instances.uuid with the records in nova.quota_usages.

I propose adding an instance uuid column to make future cleanup of this table easier.

I also propose a housecleaning task that does this clean up automatically.

Comment 3 Stephen Gordon 2016-04-11 18:36:24 UTC
Per launchpad bug discussion there is a blueprint addressing the core issue proposed here:

https://blueprints.launchpad.net/nova/+spec/refresh-quotas-usage

Comment 6 Prasanth Anbalagan 2016-10-05 16:04:18 UTC
*********
VERSION
*********

openstack-nova-api.noarch             1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-cert.noarch            1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-common.noarch          1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-compute.noarch         1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-conductor.noarch       1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-console.noarch         1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-novncproxy.noarch      1:14.0.0-0.20160929203854.59653c6.el7ost
openstack-nova-scheduler.noarch       1:14.0.0-0.20160929203854.59653c6.el7ost

**********
LOGS
**********
The feature was verified with automation 

https://review.gerrithub.io/#/q/project:RHOS-QE/RHOS-Tempest-Plugin

Log files have been attached.

Comment 8 errata-xmlrpc 2016-12-14 15:13:04 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHEA-2016-2948.html