You can use the nova-manage command for cleaning the stale resource providers and traits for vGPU.
For more information about configuring vGPU, see NVIDIA GRID vGPU.
If you remove an ESXi host from compute node, some stale resource providers and traits can still be present in the placement database. The presence of these stale resource providers and traits can cause instance creation failure. So, use the nova-manage command for cleaning the stale resources and traits.
Note: If you have instances created with the vGPU profile, you cannot delete the associated resource providers and the traits.
Procedure
Results
After applying the nova-manage command, you can see that there are no stale resource providers, and traits present in the placement database.