Disable vCLS on a Cluster via Retreat Mode
search cancel

Disable vCLS on a Cluster via Retreat Mode

book

Article ID: 316514

calendar_today

Updated On:

Products

VMware vCenter Server VMware vCenter Server 7.0 VMware vCenter Server 8.0

Issue/Introduction

There is no way to disable vCLS on a vSphere cluster and still have vSphere DRS remain functional on that cluster.

However, should it be necessary, disable vCLS on a cluster by following the Retreat Mode steps below. While in Retreat Mode, this will impact some of the cluster services for that cluster.

Impact/Risks:

Note: Retreat Mode should be used with extra caution and should be used only for the purposes mentioned in this document. Below are the details of the impacted cluster services due to the enablement of Retreat Mode on a cluster: 

  1. vSphere DRS will not function on that cluster if DRS is enabled for that cluster. That means workloads running inside that cluster are not load-balanced, hence will not be migrated to different hosts within the cluster when the current host running that VM is running out of resources. When a user wants to take down a host for maintenance, running VMs will not be automatically migrated to other hosts within that cluster. 
  2. vSphere HA will not perform optimal placement during a host failure scenario as HA depends on DRS for placement recommendations. HA will still power-on the VMs but these VMs might be powered on in a less optimal host. 
Using Retreat Mode on a vSAN cluster will show Cluster Service health as "Degraded".

Environment

VMware vCenter Server 7.0.x
VMware vCenter Server 8.0.x

Resolution

Retreat Mode Steps

Note: Starting in vSphere 7.0 U3o and 8.0 U2, entering Retreat Mode is now available as a Cluster setting within the vCenter Server UI.

vSphere 7.0 U3o/8.0 U2 and Later

  1. Log into vCenter's HTML5 client
  2. In Hosts and Clusters inventory, select a cluster.
  3. Click on the Configure tab.
  4. Under vSphere Cluster Services, select General.
  5. In the top right, click on EDIT VCLS MODE.


  6. In the Edit vCLS Mode pop up window, click on the second radio option Retreat Mode.


  7. Click OK.


For Versions Prior to vSphere 7.0 U3o and 8.0 U2, Using the vSphere Client

  1. Log in to the vSphere Client.
  2. Navigate to the cluster on which vCLS should be disabled. Copy the cluster domain id from the URL of the browser. It should be similar to 'domain-c<number>'.
    • Notes:
      • Copy only the domain-c<number> part of the URL.

        For example: When navigating to a cluster in vSphere client, the URL will be similar to:

        https://<fqdn-of-vCenter-server>/ui/app/cluster;nav=h/urn:vmomi:ClusterComputeResource:domain-c1006:ce4a7b9f-768c-2222-3333-############/summary.

        Copy only "domain-c1006" to use in the steps below.
      • Using other values, for example the cluster UUID, or a combination of the cluster ID and the UUID, will result in vpxd failing to start when the service is restarted. Therefore be careful to only use the ID domain-c<number>.
      • If the incorrect value has already been added, causing vpxd to no longer start, remove the VCLS Retreat Mode settings from the vpxd.cfg configuration file.
        1. Take a backup of the vpxd.cfg
        2. Then, run the following command:

          sed '/<vcls>/,/<\/vcls>/d' -i /etc/vmware-vpx/vpxd.cfg

          This will remove all Retreat Mode settings from all of the clusters in this vCenter, but it will allow vpxd to start again.
  3. Navigate to the vCenter Server and then to Configure tab.
  4. Click on Advanced setting section and then on Edit settings button.
  5. Add a new entry with name = config.vcls.clusters.domain-c<number>.enabled and value = False.

    Note: True and False are case insensitive, so any case of these two values should be accepted.
  6. Click Save.
  7. vCLS monitoring service will initiate the clean-up of vCLS VMs and user will start noticing the tasks with the VM deletion. 
  8. If this cluster has DRS enabled, then it will not be functional and additional warning will be displayed in the cluster summary. DRS will be disabled until vCLS is re-enabled on this cluster. 
  9. To remove Retreat Mode from the cluster, change the value to True in step# 5 above. 

    Note
    : True and False are case insensitive, so any case of these two values should be accepted.

  10. Once Retreat Mode is configured on the cluster, the entry for the cluster will stay in the vCenter Advanced Settings. There is no way to delete this entry from vSphere Client and there will be no issue with keeping this entry.

Using APIs/CLIs

  • Use the attached retreatModeConfiguration.py script to configure Retreat Mode on multiple clusters on the VC.
  • Usage:

    python retreatModeConfiguration.py -r disable or python retreatModeConfiguration.py -r enable

Identifying vCLS VMs

  1. In the vSphere Client UI, vCLS VMs are named vCLS (<number>) where the number field is auto-generated. All vCLS VMs with the Datacenter of a vSphere Client are visible in the VMs and Template tab of the client inside a VMs and Templates folder named vCLS.

    Clicking on the summary of these VMs, the following banner will appear: vSphere Cluster Service VM is required to maintain the health of vSphere Cluster Services. Power state and resource of this VM is managed by vSphere Cluster Services - along with a Learn More link.

  2. Using vSphere Managed Object Browser (MOB)

    Identifying all the vCLS VMs for a given datacenter

    Sample MOB Queries:

    Replace IP address and moid to a vCLS VM in these sample queries:

    https://<IP address>/mob/?moid=vm-1004&doPath=config.managedBy
    https://<IP address>/mob/?moid=vm-1004&doPath=config.extraConfig%5b%22HDCS.agent%22%5d



    Sample MOB query:
    Replace IP address and moid to a VM folder named vCLS in the sample query
    https://<IP address>/mob/?moid=group-v16

Attachments

configure_retreat_mode_v2 get_app
retreatModeConfiguration get_app
configure_retreat_mode get_app