In this blog, we are assuming that the vCenter is not running on the vSAN cluster and we will attempt to power down a vSAN 8 ESA-enabled cluster safely.
vSAN being a software-defined storage, we do have to do this in a particular order to ensure we can safely shut down the vSAN cluster.
By referring to a controlled shutdown, we are assuming the vSAN is currently in a healthy state and we are just to shut down the whole vSAN due to some planned activities such as the datacenter shutdown. In this approach, we don’t need to perform any kind of data evacuation from the hosts participating in the vSAN cluster.
vSAN Data Migration Options
Three vSAN data migration options when we place a vSAN ESXi host into maintenance mode: Full data migration, Ensure accessibility, and No data migration
–> Ensure accessibility – The default option, and it ensures that all the virtual machines on this host can be accessible. This option is recommended if you want to place the ESXi host into maintenance mode for a short period of maintenance activity, such as upgrading the host or installing patches, memory module replacement etc.
–> Full data migration – If the ESXi host will be permanently removed from the vSAN cluster, the Full data migration option is advisable because all the data from the host will be migrated to other ESXi hosts in the vSAN cluster. This evacuation mode results in a large amount of data transfer, as all the components on the local storage of the selected host will be migrated elsewhere in the cluster.
–> No data migration – vSAN will not evacuate any data from the host. The objects that will become non-compliant with the storage policy will be listed.
For a shutdown, we will stick with option 3 – No data migration
How do we shut down the vSAN cluster?
Step 1 – Check vSAN health service to confirm that the cluster is healthy.
Step 2 – Migrate vCenter to another ESXi host or to the first ESXi host.
Step 3 -Go to Monitor > vSAN > Resyncing Components to verify if all resynchronization tasks are complete.
Step 4 – Navigate to vSAN Cluster in the inventory –> Configure –> vSAN –> Services and click Shutdown Cluster
Step 5 – Provide a reason to shut down the vSAN Cluster
Step 6 – The workflow for power-down will automatically do the following tasks
Power off all system VMs on vSAN cluster (ie- the vCLS VMs that are used for the vSphere Cluster Services)
Disable High Availability on the cluster
Disable Cluster member updates
Pause any state changes of vSAN objects
Place all hosts into maintenance mode without any data migration
Finally power off each host
Step 7- Wait for all hosts to be powered off and vSAN Cluster to shutdown
Step 8- Once the vSAN cluster is shut down, we will see this screen and that completes the shutdown process.
All ESXi hosts of the vSAN cluster are shut down cleanly, but if there is a witness appliance which is usually on a 3rd site it will continue running and we can power that down manually if required.
How do we start the vSAN cluster?
Step 9- Power on all hosts in the cluster and they should all come back in maintenance mode
Step 10- Under Configure > vSAN > Services, click the Restart Button
Step 11 – Click the Restart Button
Step 12 – This workflow will take a while, depending on the cluster size, server resources, etc and it does all these tasks for us
Take the hosts out of maintainence mode
Re-enable cluster state changes
Enable Cluster member updates from vCenter
Power on all system VMs on vSAN cluster (ie- the vCLS VMs that are used for the vSphere Cluster Services)
Step 13 – After a few minutes, the vSAN cluster restart is completed and we can continue booting up our guest VMs.