Configuring a VMware ESXi Cluster
By: NAKIVO Team
In a VMware ESXi cluster configuration, multiple ESXi hosts provide the compute, memory, and network resources to the cluster environment as a whole as well as protect cluster-housed VMs against physical server failures. This is accomplished by using a VMware vCenter Server, which is a requirement to create a VMware ESXi cluster. Once created, a vSphere cluster enables “cluster only” features such as HA (high availability) and DRS (distributed resource scheduler). Each of these features contributes to the tolerance of the VMware cluster, failure resilience as well as the distribution of resources across the VMware ESXi hosts. Let us take a look at the process of creating a VMware ESXi Cluster.
VMware Cluster Requirements
To create a cluster after VMware vCenter deployment, you need:
- a datacenter in the vCenter inventory
- sufficient vSphere permissions to create a cluster
- vSAN enabled before creating a vSphere cluster if you want to use VMware vSAN
Hardware requirements to use ESXi clustering features:
- Two or more ESXi hosts with the same processors or processors of the same family/generation. If processors belong to different families, using the EVC mode for clusters.
- Shared storage to store VM data for VMs that can run on any of hosts of the vSphere cluster.
- Dedicated high-speed and low-latency networks for cluster management, VM migration (vMotion), accessing storage, sending heartbeats, Fault Tolerance logging traffic (if you plan to use Fault Tolerance in the vSphere cluster).
Creating a Datacenter for VMware ESXi Cluster
Let’s take a look at the steps to create a cluster once we have connected to the Web UI of our vCenter Server in VMware vSphere Client.
- Right-click on your vCenter Server in the Web UI and choose New Datacenter. The datacenter object contains all the different types of objects needed to do work in the virtual infrastructure: hosts, VMs, networks, datastores, etc.
- Next, we assign a datacenter name, for example, Datacenter1. Click OK to save settings.
Adding ESXi Hosts to the Datacenter
You have 2 approaches to configuring the vCenter inventory and creating an ESXi cluster:
- Adding ESXi hosts to the datacenter, creating a cluster, and adding the ESXi hosts that are already in the datacenter to the cluster.
- Creating a new cluster in the datacenter and adding ESXi hosts to the cluster (directly).
In this post, we use the first approach.
Right-click the datacenter in vSphere Client and click Add Host in the context menu.
The Add Host wizard is launched with 7 mandatory steps.
- Name and location. Enter the IP address of an ESXi host you want to add to the selected datacenter. Click Next at each step to continue.
- Connection settings. Enter the administrative credentials of the ESXi host you’re adding.
- Host summary. The Host summary screen shows us any VMs that are present on the host, if any. You can also see other information about the ESXi host.
- Assign license. We have the option to select the license we want to use on the host. You can read more VMware vSphere licensing. You can simply choose the evaluation license to continue with the trial license, which is good for 60 days. Note that there are limitations in Free ESXi, and you cannot use the free version to build an ESXi cluster.
- Lockdown mode. Lockdown mode prevents remote users from logging in to the host directly. This option is available for a more secure posture with the ESXi hosts. This can be enabled later as well. We don’t enable the lockdown mode in our tutorial on configuring ESXi clustering.
- VM location. Select the VM location. As we have one datacenter, this datacenter is selected by default.
- Ready to complete. Finally, we are ready to add the host to the datacenter. We will continue this process for all the hosts we wish to join to the vSphere cluster. Click Finish.
You can see two ESXi hosts added to the datacenter in the VMware vCenter inventory in the screenshot below.
How to Create a New ESXi Cluster
Once the datacenter is created and ESXi hosts are added, you can choose to create a new vSphere cluster.
- Right-click the datacenter and click New Cluster.
- We assign a cluster name, for example, Cluster1. Click OK. Later you can edit the cluster options that you can see on this screen.
- Once the cluster object is added, we can add ESXi hosts to the cluster object. Right-click the cluster name in VMware vSphere Client and click Add Hosts in the menu that opens. Once we add a host to the cluster, the host’s resources become part of the cluster resources. The cluster manages the resources of all hosts.
- The Add Host wizard opens. We should enter the name or IP address of the host to add to the cluster. Provide the credentials to access the host.
- You may receive a certificate alert. Simply click Yes to continue connecting. This is a common warning with self-signed certificates present on the hosts by default. We can safely ignore this warning.
- Review your settings at the Ready to complete step and click Finish to add the ESXi host to your ESXi cluster.
- As you can now see, we have a datacenter and cluster, and our two ESXi hosts joined to the vSphere cluster.
Now you can configure High Availability (HA) and set up Distributed Resource Scheduler (DRS) in your vSphere cluster. After configuring HA, you can configure Fault Tolerance (note that fault tolerance differs from HA).
Conclusion
To unlock the true potential of a VMware ESXi hypervisor environment, utilizing the VMware vSphere cluster functionality is key. Running VMware ESXi in the cluster configuration with VMware vCenter Server allows you to utilize the enterprise datacenter VMware vSphere technologies, including HA (high availability) and DRS (distributed resource scheduler).
Both of these technologies contribute to the tolerance of the VMware vSphere cluster, withstanding failures as well as distributing resources across the VMware ESXi hosts. In the standalone VMware ESXi configuration, this is not possible. Even if you run VMs in a VMware ESXi cluster, remember to back up your VMs to reduce the probability of data loss and downtime.