During the upgrade of VMware vCenter Server to version 9.1.0.0300, the installation process fails. The upgrade script fails, and the following error appears in the upgrade logs.
Log location :/var/log/vmware/vpxd/vcdb_inplace.err
ERROR: insert or update on table "vpx_host_crypto_tag_keys" violates foreign key constraint "fk_vpx_host_crypto_tag_keys" DETAIL: Key (key_id)=(####) is not present in table "vpx_host_crypto_keys".
Orphaned records exist in the vc.vpx_host_crypto_tag_keys table. The upgrade process attempts to enforce a foreign key constraint requiring that every key_id in the tag table must exist in the primary vc.vpx_host_crypto_keys table.
Resolving this issue requires modification of the vCenter Server PostgreSQL database.
To resolve this issue, please contact Broadcom Support and reference this Knowledge Base article.