On Fri, 2024-09-27 at 19:22 +0530, engineer2024 wrote:
Is there a way to get back the correct used resources allocation data, in case of loosing the db ? Does placement update the allocation details after restarting the compute nodes to get the latest resources usage for that node ?
yes you can use the heal-allocations command ideally you would avoid lossing the db in the first place but its easy to misplace things somethimes :) https://docs.openstack.org/nova/latest/cli/nova-manage.html#placement-heal-a... by defualt "nova-manage placement heal_allocations" will commit the changes so if you want to preview it add --dry-run there are some limiations but that will fix 90% of the issues. the rest could either be fixed manually which is hard or autmoaticlaly vai shleve/unshleve or cold migration i belive. you could try a live migration but im not sure if that will fail or not due to the lack of allcoations. we do not test the loss of a full placement db so you will need to test this befoer trying it in producitons. heal-allocations is safe but i dont knwo what move ops work when there are no allocations any that does work however can be sued to heal the workloads.
Thanks elinux