Expand a Stretched Cluster in VMware
Cloud Foundation
VMware
Cloud Foundation
You can expand a stretched cluster by
adding hosts. It is recommended that you add the same number of hosts to both availability
zones for symmetry and cluster balance.
- Commission the additional hosts toVMware Cloud Foundation.See Commission Hosts.
- Get the UIDs of the hosts you commissioned.
- In the navigation pane, click.
- Under APIs for managing hosts, clickGET /v1/hosts.
- ClickExecute.
- ClickDownloadto download the JSON file.
- Open the JSON file and copy the the UIDs of the hosts.
- Get the ID of the cluster you are expanding.
- In the API Explorer, navigate to APIs for managing clusters and clickGET /v1/clusters.
- ClickExecute.
- ClickDownloadto download the JSON file.
- Open the JSON file and copy the the cluster ID for the cluster you are expanding.
- Get the primary and secondary availability zone names from vCenter Server.
- In a web browser, log in to the vCenter Server athttps://vcenter_server_fqdn/ui.
- Select.
- In the inventory panel, expand.
- SelectClusterand then click theConfiguretab.
- UndervSAN, selectFault Domains.
- Note the primary and secondary availability zone names.
- Prepare the JSON request body.
- ClickPatch /v1/clusters/id.
- UnderClusterUpdateSpecfield, clickCluster Update Data ClusterUpdateSpec{ ... }.
- ClickDownloadto download the JSON file.
- Edit the downloaded JSON file so that it contains only the expand section similar to the example below. In theazNamefield, type the primary and secondary names you had retrieved in step 4.The ESXi hosts that you are adding must use the same vmnic to vSphere Distributed Switch mapping as the existing hosts in the stretched cluster. For example: If existing hosts map vmnic0 and vmnic1 to vSphere Dstributed Switch 1 and vmnic2 and vmnic3 to vSphere Distributed Switch 2, then the hosts you are adding must map the same vmincs to the same vSphere Distributed Switches.{ "clusterExpansionSpec": { "hostSpecs": [ { "id": "ESXi host 1 ID", "licenseKey": "XXXXX-XXXXX-XXXXX-XXXXX-XXXXX", "azName":"primary/secondary", "hostNetworkSpec": { "vmNics": [{ "id": "vmnic0", "vdsName": "<vSphere Distributed Switch 1>" }, { "id": "vmnic1", "vdsName": "<vSphere Distributed Switch 2>" } ] } }, { "id": "ESXi host 2 ID", "licenseKey": "XXXXX-XXXXX-XXXXX-XXXXX-XXXXX", "azName":"primary/secondary", "hostNetworkSpec": { "vmNics": [{ "id": "vmnic0", "vdsName": "<vSphere Distributed Switch 1>" }, { "id": "vmnic1", "vdsName": "<vSphere Distributed Switch 2>" } ] } }, { "id": "ESXi host 3 ID", "licenseKey": "XXXXX-XXXXX-XXXXX-XXXXX-XXXXX", "azName":"primary/secondary". "hostNetworkSpec": { "vmNics": [{ "id": "vmnic0", "vdsName": "<vSphere Distributed Switch 1>" }, { "id": "vmnic1", "vdsName": "<vSphere Distributed Switch 2>" } ] } }, { "id": "ESXi host 4 ID", "licenseKey": "XXXXX-XXXXX-XXXXX-XXXXX-XXXXX", "azName":"primary/secondary", "hostNetworkSpec": { "vmNics": [{ "id": "vmnic0", "vdsName": "<vSphere Distributed Switch 1>" }, { "id": "vmnic1", "vdsName": "<vSphere Distributed Switch 2>" } ] } } ] } }
- Run the expand cluster API.
- For theClusterUpdateSpecfield, update the cluster ID (you retrieved this in step 3) and JSON file with the payload you prepared in step 5.
- ClickExecute.
- Monitor the task until it is completed.
- If required, SSH in to each newly added host and add a static route to the vSAN network of the witness host. Also add static routes in the witness if it could not reach the vSAN network of the newly added hosts.
- Update the value ofHost failure cluster toleratesto the number of hosts in AZ1 after cluster expansion.
- Log in to the management vCenter Server.
- SelectClusterand click theConfiguretab.
- UnderServices, clickvSphere Availabilityand then clickEdit.
- On theAdmission Controlpage of theEdit Cluster Settingsdialog box, set host failures cluster tolerates to the number of hosts in availability zone 1 and clickOK.