How to Delete VM Reference from Bosh Database
search cancel

How to Delete VM Reference from Bosh Database

book

Article ID: 375593

calendar_today

Updated On:

Products

VMware Tanzu Application Service

Issue/Introduction

In scenarios where a VM is deleted by the IAAS, Bosh CCK and Bosh Delete-VM commands may fail to delete the VM.

Bosh CCK runs this function to purge a vm reference from the database

def delete_vm_reference(instance)
  vm_model = instance.active_vm
  instance.active_vm = nil
  vm_model&.destroy
end

In cases where Bosh can no longer communicate with the IAAS, Bosh CCK fails to get to this point. So we can bypass all that and delete the VM reference directly.

Resolution

Please contact Tanzu Support and provide this KB Article ID to assist with the resolution.