I recently had to redeploy my Hybrid Cloud Extension (HCX) setup on my onPrem vCenter Server as a newer version had been released since the last time I had looked at this which was some time last year. I had already deleted my HCX Manager and cleaned up the other HCX VMs but one thing that is not handled for you currently are the extension plugins that HCX uses to register with vCenter Server, which is no different than any other solution that integrates with vCenter Server.

Today, the only easy way to unregister an extension is to use the vSphere MOB, which I have blogged about in the past here. As you can see from the screenshot below, HCX has a number of plugins and because this is done by hand, its entirely possible that you may accidentally unregister the wrong extension which could severely impact your vCenter Server.



To help reduce that risk, an alternative and recommended method is to simply use the vSphere API (which is exactly what the vSphere MOB is talking to) and specifying the specific extensions to unregister. Below is a quick PowerCLI snippet which talks to the vSphere API and unregisters the 8 extensions related to HCX. After this, if you are still logged into the vSphere Client, you simply need to logout and log back in for the UI components to go away. If you are still seeing the UI plugins, you may need to restart the vSphere Client service.

$extensionManager = Get-View $global:DefaultVIServer.ExtensionData.Content.ExtensionManager $hcxExtensions = @( "com.vmware.hybridity" "com.vmware.hybridity.dr" "com.vmware.hybridity.hcsp-dashboard" "com.vmware.hybridity.publisher" "com.vmware.hybridity.troubleshooting" "com.vmware.hybridity.hybrid-interconnect-ui" "com.vmware.hybridity.auditlog-ui" "com.vmware.vca.marketing.ngc.ui" "com.vmware.hybridity.mobility-app" "com.vmware.hcsp.alarm" ) foreach ($hcxExtension in $hcxExtensions) { $extensionManager.UnregisterExtension($hcxExtension) } 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 $extensionManager = Get-View $global : DefaultVIServer . ExtensionData . Content . ExtensionManager $hcxExtensions = @ ( "com.vmware.hybridity" "com.vmware.hybridity.dr" "com.vmware.hybridity.hcsp-dashboard" "com.vmware.hybridity.publisher" "com.vmware.hybridity.troubleshooting" "com.vmware.hybridity.hybrid-interconnect-ui" "com.vmware.hybridity.auditlog-ui" "com.vmware.vca.marketing.ngc.ui" "com.vmware.hybridity.mobility-app" "com.vmware.hcsp.alarm" ) foreach ( $hcxExtension in $hcxExtensions ) { $extensionManager . UnregisterExtension ( $hcxExtension ) }

Once the HCX extensions have been removed, you can now download the new HCX Manager appliance from the VMC portal and redeploy.

If you are still seeing the HCX Plugin in the vSphere UI after unregistering the extension, I have found that you also needed to clear the H5 Plugins on the vCenter Server itself. Here is what I needed to do to fully clean it up. Login to the VCSA and then run the following commands:

cd /etc/vmware/vsphere-ui/vc-packages/vsphere-client-serenity/

rm -rf com.vmware.hybridity*

rm com.vmware.vca.marketing.*

cd /usr/lib/vmware-vsphere-ui/server/pickup/

rm -rf com.vmware.hybridity*

rm com.vmware.vca.marketing.*