Hello All,
Just wanted to share an issue I had and get feedback if anyone has experienced this... new bug?
My vCenter 6.5 server was running on a host which experienced a failure... I manually recovered the failed VM's onto another host, once all VM's were back online the vCenter started to crash as soon as I tried to view the properties of a specific VM (via the Webclient) which was also on that original failed host.
The second the properties loaded in the webgui, vCenter would shutdown with the following error:
"An unrecoverable problem has occurred, stopping the VMware VirtualCenter service. Error: Error[VdbODBCError] (-1) “ODBC error: (23505) – ERROR: duplicate key value violates unique constraint “pk_vpx_vm_virtual_device"
I asked DR google and couldn't really find anything specific to “pk_vpx_vm_virtual_device”... has anyone experienced this one before on other versions?
After some investigation I linked this back to the “Host USB Device” and I managed to solve my problem. As I couldn't find anything relevant to this issue I thought I would do a simple write up about it for anyone is interested / experiences the problem.
Cheers
vMan
UPDATE 11/03/2017: This issue has been patched with vCenter 6.5b, just search for "pk_vpx_vm_virtual_device". and you will find the details. If you face this issue in PROD and are not willing to try the fix below just contact VMware Support for help.
They suggest the work around...
Workaround from VMware: Unregister the problematic virtual machine from the host inventory and restart the vCenter Server. You might need to repeat this process if the failure happens again. (vMAN: which is fine if you know which VM is causing the issue but this is not obvious from the logs / errors without going into the DB - IMO)