Compare languages | Cloud provider — VMware vSphere: configuration

The module is automatically enabled for all cloud clusters deployed in vSphere.

Модуль автоматически включается для всех облачных кластеров, развернутых в vSphere.

If the cluster control plane is hosted on a virtual machines or bare-metal servers, the cloud provider uses the settings from the cloud-provider-vsphere module in the Deckhouse configuration (see below). Otherwise, if the cluster control plane is hosted in a cloud, the cloud provider uses the VsphereClusterConfiguration structure for configuration.

Если control plane кластера размещен на виртуальных машинах или bare-metal-серверах, cloud-провайдер использует настройки модуля cloud-provider-vsphere в конфигурации Deckhouse (см. ниже). Иначе, если control plane кластера размещен в облаке, cloud-провайдер использует структуру VsphereClusterConfiguration для настройки.

You can configure the number and parameters of ordering machines in the cloud via the NodeGroup custom resource of the node-manager module. Also, in this custom resource, you can specify the instance class’s name for the above group of nodes (the cloudInstances.ClassReference parameter of NodeGroup). In the case of the vSphere cloud provider, the instance class is the VsphereInstanceClass custom resource that stores specific parameters of the machines.

Количество и параметры процесса заказа машин в облаке настраиваются в custom resource NodeGroup модуля node-manager, в котором также указывается название используемого для этой группы узлов инстанс-класса (параметр cloudInstances.classReference NodeGroup). Инстанс-класс для cloud-провайдера vSphere — это custom resource VsphereInstanceClass, в котором указываются конкретные параметры самих машин.

Storage

Storage

The module automatically creates a StorageClass for each Datastore and DatastoreCluster in the zone (or zones).

Модуль автоматически создает StorageClass для каждого Datastore и DatastoreCluster из зон (зоны).

Also, it can set the name of StorageClass that will be used in the cluster by default (the default parameter), and filter out the unnecessary StorageClasses (the exclude parameter).

Также он позволяет настроить имя StorageClass’а, который будет использоваться в кластере по умолчанию (параметр default) и отфильтровать ненужные StorageClass’ы (параметр exclude).

CSI

CSI

By default, the storage subsystem uses CNS volumes with the ability of online-resize. FCD volumes are also supported, but only in the legacy or migration modes. You can set this via the compatibilityFlag parameter.

Подсистема хранения по умолчанию использует CNS-диски с возможностью изменения их размера на лету. Но также поддерживается работа и в legacy-режиме с использованием FCD-дисков. Поведение настраивается параметром compatibilityFlag.

Important information concerning the increase of the PVC size

Важная информация об увеличении размера PVC

Due to the nature f volume-resizer, CSI, and vSphere API, you have to do the following after increasing the PVC size:

Из-за особенностей работы volume-resizer CSI и vSphere API после увеличения размера PVC нужно сделать следующее:

  1. On the node where the Pod is located, run the kubectl cordon <node_name> command.
  2. Delete the Pod.
  3. Make sure that the resize was successful. The PVC object must not have the Resizing condition.

    The FileSystemResizePending state is OK.

  4. On the node where the Pod is located, run the kubectl uncordon <node_name> command.
  1. На узле, где находится под, выполнить команду kubectl cordon <имя_узла>.
  2. Удалить под.
  3. Убедиться, что изменение размера прошло успешно. В объекте PVC не будет condition Resizing.

    Состояние FileSystemResizePending не является проблемой.

  4. На узле, где находится под, выполнить команду kubectl uncordon <имя_узла>.

Environment requirements

Требования к окружению

  • vSphere version required: v7.0U2 (required for the Online volume expansion work).
  • vCenter to which master nodes can connect to from within the cluster.
  • Datacenter with the following components:
    1. VirtualMachine template.
  • VM image should use Virtual machines with hardware version 15 or later (required for online resize to work).
  • The following packages must be installed in the VM image: open-vm-tools, cloud-init and cloud-init-vmware-guestinfo (if the cloud-init version lower than 21.3 is used).
    1. The network must be available on all ESXi where VirtualMachines will be created.
    2. One or more Datastores connected to all ESXi where VirtualMachines will be created.
  • A tag from the tag category in zoneTagCategory (k8s-zone by default) must be added to Datastores. This tag will indicate the zone. All Clusters of a specific zone must have access to all Datastores within the same zone.
    1. The cluster with the required ESXis.
  • A tag from the tag category in zoneTagCategory (k8s-zone by default) must be added to the Cluster. This tag will indicate the zone.
    1. Folder for VirtualMachines to be created.
  • An optional parameter. By default, the root vm folder is used.
    1. Create a role with the appropriate set of privileges.
    2. Create a user and assign the above role to it.
  • A tag from the tag category in regionTagCategory (k8s-region by default) must be added to the Datacenter. This tag will indicate the region.
  • Требования к версии vSphere: v7.0U2 (необходимо для работы механизма Online volume expansion).
  • vCenter, до которого есть доступ изнутри кластера с master-узлов.
  • Создать Datacenter, в котором создать:
    1. VirtualMachine template.
  • Образ виртуальной машины должен использовать Virtual machines with hardware version 15 or later (необходимо для работы online resize).
  • В образе должны быть установлены следующие пакеты: open-vm-tools, cloud-init и cloud-init-vmware-guestinfo (если используется версия cloud-init ниже 21.3).
    1. Network, доступную на всех ESXi, на которых будут создаваться виртуальные машины.
    2. Datastore (или несколько), подключенный ко всем ESXi, на которых будут создаваться виртуальные машины.
  • На Datastore’ы необходимо «повесить» тег из категории тегов, указанных в zoneTagCategory (по умолчанию k8s-zone). Этот тег будет обозначать зону. Все Cluster’ы из конкретной зоны должны иметь доступ ко всем Datastore’ам с идентичной зоной.
    1. Cluster, в который добавить необходимые используемые ESXi.
  • На Cluster необходимо «повесить» тег из категории тегов, указанных в zoneTagCategory (по умолчанию k8s-zone). Этот тег будет обозначать зону.
    1. Folder для создаваемых виртуальных машин.
  • Опциональный. По умолчанию будет использоваться root vm-каталог.
    1. Роль с необходимым набором прав.
    2. Пользователя, привязав к нему роль из п. 6.
  • На созданный Datacenter необходимо «повесить» тег из категории тегов, указанный в regionTagCategory (по умолчанию k8s-region). Этот тег будет обозначать регион.

List of privileges for using the module

Список привилегий для использования модуля

Read the documentation on how to create and assign a role to a user.

О том, как создать и назначить роль пользователю, читайте в документации.

A detailed list of privileges required for Deckhouse Kubernetes Platform to work in vSphere:

Детальный список привилегий, необходимых для работы Deckhouse Kubernetes Platform в vSphere:

none Cns.Searchable Datastore.AllocateSpace Datastore.Browse Datastore.FileManagement Folder.Create Folder.Delete Folder.Move Folder.Rename Global.GlobalTag Global.SystemTag Network.Assign StorageProfile.View InventoryService.Tagging.AttachTag InventoryService.Tagging.CreateCategory InventoryService.Tagging.CreateTag InventoryService.Tagging.DeleteCategory InventoryService.Tagging.DeleteTag InventoryService.Tagging.EditCategory InventoryService.Tagging.EditTag InventoryService.Tagging.ModifyUsedByForCategory InventoryService.Tagging.ModifyUsedByForTag InventoryService.Tagging.ObjectAttachable Resource.ApplyRecommendation Resource.AssignVAppToPool Resource.AssignVMToPool Resource.ColdMigrate Resource.CreatePool Resource.DeletePool Resource.EditPool Resource.HotMigrate Resource.MovePool Resource.QueryVMotion Resource.RenamePool VirtualMachine.Config.AddExistingDisk VirtualMachine.Config.AddNewDisk VirtualMachine.Config.AddRemoveDevice VirtualMachine.Config.AdvancedConfig VirtualMachine.Config.Annotation VirtualMachine.Config.ChangeTracking VirtualMachine.Config.CPUCount VirtualMachine.Config.DiskExtend VirtualMachine.Config.DiskLease VirtualMachine.Config.EditDevice VirtualMachine.Config.HostUSBDevice VirtualMachine.Config.ManagedBy VirtualMachine.Config.Memory VirtualMachine.Config.MksControl VirtualMachine.Config.QueryFTCompatibility VirtualMachine.Config.QueryUnownedFiles VirtualMachine.Config.RawDevice VirtualMachine.Config.ReloadFromPath VirtualMachine.Config.RemoveDisk VirtualMachine.Config.Rename VirtualMachine.Config.ResetGuestInfo VirtualMachine.Config.Resource VirtualMachine.Config.Settings VirtualMachine.Config.SwapPlacement VirtualMachine.Config.ToggleForkParent VirtualMachine.Config.UpgradeVirtualHardware VirtualMachine.GuestOperations.Execute VirtualMachine.GuestOperations.Modify VirtualMachine.GuestOperations.ModifyAliases VirtualMachine.GuestOperations.Query VirtualMachine.GuestOperations.QueryAliases VirtualMachine.Hbr.ConfigureReplication VirtualMachine.Hbr.MonitorReplication VirtualMachine.Hbr.ReplicaManagement VirtualMachine.Interact.AnswerQuestion VirtualMachine.Interact.Backup VirtualMachine.Interact.ConsoleInteract VirtualMachine.Interact.CreateScreenshot VirtualMachine.Interact.CreateSecondary VirtualMachine.Interact.DefragmentAllDisks VirtualMachine.Interact.DeviceConnection VirtualMachine.Interact.DisableSecondary VirtualMachine.Interact.DnD VirtualMachine.Interact.EnableSecondary VirtualMachine.Interact.GuestControl VirtualMachine.Interact.MakePrimary VirtualMachine.Interact.Pause VirtualMachine.Interact.PowerOff VirtualMachine.Interact.PowerOn VirtualMachine.Interact.PutUsbScanCodes VirtualMachine.Interact.Record VirtualMachine.Interact.Replay VirtualMachine.Interact.Reset VirtualMachine.Interact.SESparseMaintenance VirtualMachine.Interact.SetCDMedia VirtualMachine.Interact.SetFloppyMedia VirtualMachine.Interact.Suspend VirtualMachine.Interact.SuspendToMemory VirtualMachine.Interact.TerminateFaultTolerantVM VirtualMachine.Interact.ToolsInstall VirtualMachine.Interact.TurnOffFaultTolerance VirtualMachine.Inventory.Create VirtualMachine.Inventory.CreateFromExisting VirtualMachine.Inventory.Delete VirtualMachine.Inventory.Move VirtualMachine.Inventory.Register VirtualMachine.Inventory.Unregister VirtualMachine.Namespace.Event VirtualMachine.Namespace.EventNotify VirtualMachine.Namespace.Management VirtualMachine.Namespace.ModifyContent VirtualMachine.Namespace.Query VirtualMachine.Namespace.ReadContent VirtualMachine.Provisioning.Clone VirtualMachine.Provisioning.CloneTemplate VirtualMachine.Provisioning.CreateTemplateFromVM VirtualMachine.Provisioning.Customize VirtualMachine.Provisioning.DeployTemplate VirtualMachine.Provisioning.DiskRandomAccess VirtualMachine.Provisioning.DiskRandomRead VirtualMachine.Provisioning.FileRandomAccess VirtualMachine.Provisioning.GetVmFiles VirtualMachine.Provisioning.MarkAsTemplate VirtualMachine.Provisioning.MarkAsVM VirtualMachine.Provisioning.ModifyCustSpecs VirtualMachine.Provisioning.PromoteDisks VirtualMachine.Provisioning.PutVmFiles VirtualMachine.Provisioning.ReadCustSpecs VirtualMachine.State.CreateSnapshot VirtualMachine.State.RemoveSnapshot VirtualMachine.State.RenameSnapshot VirtualMachine.State.RevertToSnapshot

none Cns.Searchable Datastore.AllocateSpace Datastore.Browse Datastore.FileManagement Folder.Create Folder.Delete Folder.Move Folder.Rename Global.GlobalTag Global.SystemTag Network.Assign StorageProfile.View InventoryService.Tagging.AttachTag InventoryService.Tagging.CreateCategory InventoryService.Tagging.CreateTag InventoryService.Tagging.DeleteCategory InventoryService.Tagging.DeleteTag InventoryService.Tagging.EditCategory InventoryService.Tagging.EditTag InventoryService.Tagging.ModifyUsedByForCategory InventoryService.Tagging.ModifyUsedByForTag InventoryService.Tagging.ObjectAttachable Resource.ApplyRecommendation Resource.AssignVAppToPool Resource.AssignVMToPool Resource.ColdMigrate Resource.CreatePool Resource.DeletePool Resource.EditPool Resource.HotMigrate Resource.MovePool Resource.QueryVMotion Resource.RenamePool VirtualMachine.Config.AddExistingDisk VirtualMachine.Config.AddNewDisk VirtualMachine.Config.AddRemoveDevice VirtualMachine.Config.AdvancedConfig VirtualMachine.Config.Annotation VirtualMachine.Config.ChangeTracking VirtualMachine.Config.CPUCount VirtualMachine.Config.DiskExtend VirtualMachine.Config.DiskLease VirtualMachine.Config.EditDevice VirtualMachine.Config.HostUSBDevice VirtualMachine.Config.ManagedBy VirtualMachine.Config.Memory VirtualMachine.Config.MksControl VirtualMachine.Config.QueryFTCompatibility VirtualMachine.Config.QueryUnownedFiles VirtualMachine.Config.RawDevice VirtualMachine.Config.ReloadFromPath VirtualMachine.Config.RemoveDisk VirtualMachine.Config.Rename VirtualMachine.Config.ResetGuestInfo VirtualMachine.Config.Resource VirtualMachine.Config.Settings VirtualMachine.Config.SwapPlacement VirtualMachine.Config.ToggleForkParent VirtualMachine.Config.UpgradeVirtualHardware VirtualMachine.GuestOperations.Execute VirtualMachine.GuestOperations.Modify VirtualMachine.GuestOperations.ModifyAliases VirtualMachine.GuestOperations.Query VirtualMachine.GuestOperations.QueryAliases VirtualMachine.Hbr.ConfigureReplication VirtualMachine.Hbr.MonitorReplication VirtualMachine.Hbr.ReplicaManagement VirtualMachine.Interact.AnswerQuestion VirtualMachine.Interact.Backup VirtualMachine.Interact.ConsoleInteract VirtualMachine.Interact.CreateScreenshot VirtualMachine.Interact.CreateSecondary VirtualMachine.Interact.DefragmentAllDisks VirtualMachine.Interact.DeviceConnection VirtualMachine.Interact.DisableSecondary VirtualMachine.Interact.DnD VirtualMachine.Interact.EnableSecondary VirtualMachine.Interact.GuestControl VirtualMachine.Interact.MakePrimary VirtualMachine.Interact.Pause VirtualMachine.Interact.PowerOff VirtualMachine.Interact.PowerOn VirtualMachine.Interact.PutUsbScanCodes VirtualMachine.Interact.Record VirtualMachine.Interact.Replay VirtualMachine.Interact.Reset VirtualMachine.Interact.SESparseMaintenance VirtualMachine.Interact.SetCDMedia VirtualMachine.Interact.SetFloppyMedia VirtualMachine.Interact.Suspend VirtualMachine.Interact.SuspendToMemory VirtualMachine.Interact.TerminateFaultTolerantVM VirtualMachine.Interact.ToolsInstall VirtualMachine.Interact.TurnOffFaultTolerance VirtualMachine.Inventory.Create VirtualMachine.Inventory.CreateFromExisting VirtualMachine.Inventory.Delete VirtualMachine.Inventory.Move VirtualMachine.Inventory.Register VirtualMachine.Inventory.Unregister VirtualMachine.Namespace.Event VirtualMachine.Namespace.EventNotify VirtualMachine.Namespace.Management VirtualMachine.Namespace.ModifyContent VirtualMachine.Namespace.Query VirtualMachine.Namespace.ReadContent VirtualMachine.Provisioning.Clone VirtualMachine.Provisioning.CloneTemplate VirtualMachine.Provisioning.CreateTemplateFromVM VirtualMachine.Provisioning.Customize VirtualMachine.Provisioning.DeployTemplate VirtualMachine.Provisioning.DiskRandomAccess VirtualMachine.Provisioning.DiskRandomRead VirtualMachine.Provisioning.FileRandomAccess VirtualMachine.Provisioning.GetVmFiles VirtualMachine.Provisioning.MarkAsTemplate VirtualMachine.Provisioning.MarkAsVM VirtualMachine.Provisioning.ModifyCustSpecs VirtualMachine.Provisioning.PromoteDisks VirtualMachine.Provisioning.PutVmFiles VirtualMachine.Provisioning.ReadCustSpecs VirtualMachine.State.CreateSnapshot VirtualMachine.State.RemoveSnapshot VirtualMachine.State.RenameSnapshot VirtualMachine.State.RevertToSnapshot