Comment 4 for bug 2003991

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

Reviewed: https://review.opendev.org/c/openstack/nova/+/872471
Committed: https://opendev.org/openstack/nova/commit/6f79d6321e7c3edaab2eb911198b7b7f851371b3
Submitter: "Zuul (22348)"
Branch: master

commit 6f79d6321e7c3edaab2eb911198b7b7f851371b3
Author: melanie witt <email address hidden>
Date: Fri Jan 27 03:08:09 2023 +0000

    Enforce quota usage from placement when unshelving

    When [quota]count_usage_from_placement = true or
    [quota]driver = nova.quota.UnifiedLimitsDriver, cores and ram quota
    usage are counted from placement. When an instance is SHELVED_OFFLOADED,
    it will not have allocations in placement, so its cores and ram should
    not count against quota during that time.

    This means however that when an instance is unshelved, there is a
    possibility of going over quota if the cores and ram it needs were
    allocated by some other instance(s) while it was SHELVED_OFFLOADED.

    This fixes a bug where quota was not being properly enforced during
    unshelve of a SHELVED_OFFLOADED instance when quota usage is counted
    from placement. Test coverage is also added for the "recheck" quota
    cases.

    Closes-Bug: #2003991

    Change-Id: I4ab97626c10052c7af9934a80ff8db9ddab82738