/Move vSphere Cluster Services (vCLS) VMs datastore

Move vSphere Cluster Services (vCLS) VMs datastore

In this quick tip on Move vSphere Cluster Services (vCLS) VMs datastore, I will explain how to move your vCLS VMs to a different datastore and create the Anti-Affinity for vCLS VMs rule.

vCLS is a new feature launched with vSphere 7 update 1. In this new feature, vCLS ensures cluster services such as vSphere DRS and vSphere HA are all available to maintain the resources and health of the workloads running in the clusters independent of the vCenter Server instance availability.

Since it is a relatively new feature, it is still being improved in the latest versions, and more options were added to handle these VMs. There were some issues handling these VMs or moving them to other Hosts/Datastores in the initial version. In each vSphere update, VMware is fixing that and giving more flexibility to customers to handle these vCLS VMs.

For example, you can now set the datastores where vCLS can run and should run. This option was added in vSphere 7 update 3, together with the option to create also Anti-Affinity for vCLS VMs not running with specific VMs.

Move vCLS Datastore

This task can be done at the Cluster level(every Cluster with DRS and HA will have 1 o 3 vCLS VMs depending on the size of your Cluster).

Go to the Cluster and Configure tab, then you see a section vSphere Cluster Services and Datastores.

Here you have two options, Datastores where vCLS are allowed to run and Datastores where vCLS are not allowed to run. In this case, we will only move the vCLS VMs to run in a particular datastore (for security, you should add a second datastore if the first one is not available).

Select your Datastore(s) and click Add.

Move vSphere Cluster Services (vCLS) VMs datastore

You have it configured after you add your Datastore(s), and there is no need to do anything else.

Move vSphere Cluster Services (vCLS) VMs datastore

The vCLS VMs will automatically move to the Datastore(s)  you added.

Move vSphere Cluster Services (vCLS) VMs datastore

The Datastore move of vCLS is done.

Create Anti-Affinity for vCLS VMs rule

This option is also straightforward to implement.

Important note, the rule is only to set vCLS VMs, not to run with specific VMs using TAGs. There is no other option to set this. I don’t know why VMware only added this option and not the same option we use for DRS Anti-Affinity for Hosts/VMs rules.

So to use this option, you need to have TAGs implemented in your Center. A couple of years ago, I wrote a blog post on implementing and creating TAGs. Check it if you want to implement this in your environment.

On the vCenter main menu, go to Policies and Profiles, and in the Compute Policies, create the Anti-Affinity vCLS rule,

There is only one option in the Policy Type, the Anti-Affinity for vCLS. Next, you need to select the VM TAG Category.

In my case, I select the rule where vCLS VMs never run in the same ESXi host where VM Guest OS is classified as Other OS (like Oracle, DBs, etc.). This is an example where a VM (like Oracle, SAP, or other DBs, needs to run isolated in an ESXi host, and no other VMs can run on the ESXi host).

Move vSphere Cluster Services (vCLS) VMs datastore

After that, we have our Anti-Affinity rule created for vCLS VMs. You can delete this rule when you want, with no impact on the vCLS performance or configuration.

And this latest option, Anti-Affinity for vCLS VMs, this tip blog post Move vSphere Cluster Services (vCLS) VMs datastore is finished.

Share this article if you think it is worth sharing. If you have any questions or comments, comment here, or contact me on Twitter.

©2022 ProVirtualzone. All Rights Reserved
By | 2022-01-24T14:26:56+01:00 January 15th, 2022|VMware Posts, vSphere|7 Comments

About the Author:

I have over 20 years of experience in the IT industry. I have been working with Virtualization for more than 15 years (mainly VMware). I recently obtained certifications, including VCP DCV 2022, VCAP DCV Design 2023, and VCP Cloud 2023. Additionally, I have VCP6.5-DCV, VMware vSAN Specialist, vExpert vSAN, vExpert NSX, vExpert Cloud Provider for the last two years, and vExpert for the last 7 years and a old MCP. My specialties are Virtualization, Storage, and Virtual Backup. I am a Solutions Architect in the area VMware, Cloud and Backup / Storage. I am employed by ITQ, a VMware partner as a Senior Consultant. I am also a blogger and owner of the blog ProVirtualzone.com

7 Comments

  1. Robert Newton 15/02/2022 at 07:45

    Thanks very much, not much info about this yet- was trying to remov an ‘old’ datastore after migrations and this was the answer. Perfect!

  2. Jawad Ehsani 23/05/2022 at 09:33

    Hi
    Thanks for your info,
    how can I do it (Move vCLS Datastore) with Powercli?

    Thanks, and regards
    Jawad

    • Luciano Patrao 23/05/2022 at 17:37

      Hi Jawad,

      Thank you for your message.

      I have never tried to create a PowerClI script for this, but I am pretty sure it is possible. Since is possible to do almost anything in VMware using PowerClI.

      At the moment very busy to try to test this.

  3. ballhawk45 17/06/2022 at 04:32

    Luciano – One small bit of knowledge that I would like contribute to this post that resulted from a number of calls to VMware support… vCLS vms are deployed without reserved memory, so they require a swap file. IF you do not store vm swap files in the “Virtual machine directory” (default setting) but have instead set the option to store swap files on “Datastore specified by host” and then you manually specify only a subset (one or more) of your datastores as allowed for vCLS, you MUST also include in the vCLS-allowed datstores list the same datastore(s) that your cluster hosts specify for vm swap files. If you do not, the eam process wll create the vCLS vms for the cluster, then the vpxd process will see that the defined swap file location for those vms is not available to them and deletes the vms – then eam will determine there are not enough vCLS vms in your cluster and redeploy new ones, them vpxd destroys them…and so on in an infinite loop. I have experienced this in multiple environments and resolved it by adding the unique swap file datastore for each cluster to the list of allowed vCLS datastores for that cluster. This should be fixed in a future release per Support.

    • Luciano Patrao 17/06/2022 at 11:09

      Hi Patrick,

      This is new for me. Did VMware provide you with any KB for this specific issue?

      I never use a specific Datastore for swap files, so maybe that is why I never encounter this issue. But when I have the time, I will try to test this and update my blog post accordantly.

      And thank you very much for bringing this to my attention.

Leave A Comment