commit 732b0571cc27a8a1aba30f44c18317f13325aad3
Author: Maciej Józefczyk <email address hidden>
Date: Thu Nov 16 14:49:42 2017 +0100
Update resources once in update_available_resource
This change ensures that resources are updated only once per
update_available_resource() call.
Compute resources were previously updated during host
object initialization and at the end of
update_available_resource(). It could cause inconsistencies
in resource tracking between compute host and DB for couple
of second when final _update() at the end of
update_available_resource() is being called.
For example: nova-api shows that host uses 10GB of RAM, but
in fact its 12GB because DB doesn't have resources that belongs
to shutdown instance.
Because of that fact nova-scheduler (CachingScheduler) could
choose (based on imcomplete information) host which is already full.
For more informations please see realted bug: #1729621
Change-Id: I120a98cc4c11772f24099081ef3ac44a50daf71d
Closes-Bug: #1729621
(cherry picked from commit c9b74bcfa09d11c2046ce1bfb6dd8463b3a2f3b0)
Reviewed: https:/ /review. openstack. org/612293 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=732b0571cc2 7a8a1aba30f44c1 8317f13325aad3
Committed: https:/
Submitter: Zuul
Branch: stable/rocky
commit 732b0571cc27a8a 1aba30f44c18317 f13325aad3
Author: Maciej Józefczyk <email address hidden>
Date: Thu Nov 16 14:49:42 2017 +0100
Update resources once in update_ available_ resource
This change ensures that resources are updated only once per available_ resource( ) call.
update_
Compute resources were previously updated during host available_ resource( ). It could cause inconsistencies available_ resource( ) is being called.
object initialization and at the end of
update_
in resource tracking between compute host and DB for couple
of second when final _update() at the end of
update_
For example: nova-api shows that host uses 10GB of RAM, but
in fact its 12GB because DB doesn't have resources that belongs
to shutdown instance.
Because of that fact nova-scheduler (CachingScheduler) could
choose (based on imcomplete information) host which is already full.
For more informations please see realted bug: #1729621
Change-Id: I120a98cc4c1177 2f24099081ef3ac 44a50daf71d 2046ce1bfb6dd84 63b3a2f3b0)
Closes-Bug: #1729621
(cherry picked from commit c9b74bcfa09d11c