This article explains the steps to replace an expired intermediate certificate with updated certificates.
Pre-requisites:
# /usr/lib/vmware-vmafd/bin/vecs-cli entry list --store MACHINE_SSL_CERT --text | less
# /usr/lib/vmware-vmafd/bin/vecs-cli entry list --store TRUSTED_ROOTS --text | less
7.x
8.x
The vCenter Server is failing to start certain services because the intermediate certificate has expired. When the intermediate certificate is no longer valid, the certificate chain breaks, leading to service startup failures until the expired certificate is replaced or renewed.
Here are the steps to update the expired intermediate certificate:
Important Note: Before proceeding with step #4, make sure to obtain the "Intermediate Certificate" from the CA and then continue with the steps below.
# /usr/lib/vmware-vmafd/bin/vecs-cli entry getcert --store MACHINE_SSL_CERT --alias __MACHINE_CERT --output /var/core/ssl_backup.cer
# /usr/lib/vmware-vmafd/bin/vecs-cli entry getkey --store MACHINE_SSL_CERT --alias __MACHINE_CERT --output /var/core/ssl_key.key
# /usr/lib/vmware-vmafd/bin/vecs-cli entry delete --store MACHINE_SSL_CERT --alias __MACHINE_CERT -y
# /usr/lib/vmware-vmafd/bin/dir-cli trustedcert publish --cert /var/core/intermediate.cer --login administrator
# /usr/lib/vmware-vmafd/bin/vecs-cli force-refresh
cat machine_certificate.cer intermediate_certificate.cer root_certificate.cer > /var/core/ssl.cer
# /usr/lib/vmware-vmafd/bin/vecs-cli entry create --store MACHINE_SSL_CERT --alias __MACHINE_CERT --cert /var/core/ssl.cer --key /var/core/ssl_key.key
# /usr/lib/vmware-vmafd/bin/vecs-cli force-refresh
# service-control --stop --all && service-control --start --all