Symptoms:
yyyy-mm-dd wcp:Patch INFO roles_groups_users Checking if privileges should be updated for role {'id': '1004', 'name': 'WorkloadStorageManagement', 'description': 'This role entitles you to perform operations required for Kubernetes storage integration with vSphere Cloud Provider', 'priv_ids': ['Resource.AssignVMToPool', 'System.Read', 'System.Anonymous', 'System.View', 'VirtualMachine.Config.AddExistingDisk', 'VirtualMachine.Config.AddNewDisk', 'VirtualMachine.Config.AddRemoveDevice', 'VirtualMachine.Config.RemoveDisk', 'VirtualMachine.Config.Settings', 'VirtualMachine.Inventory.Create', 'VirtualMachine.Inventory.Delete', 'Datastore.AllocateSpace', 'Datastore.FileManagement', 'StorageProfile.View', 'EAM.Modify', 'Cns.Searchable', 'Resource.ColdMigrate', 'Host.Config.Storage']}
yyyy-mm-dd wcp:Patch ERROR wcp Failed to apply patch %s! Error: %s.
yyyy-mm-dd wcp:Patch ERROR wcp Not all patches were applied. Latest applied patch is 1
yyyy-mm-dd wcp:Patch ERROR vmware_b2b.patching.executor.hook_executor Patch hook 'wcp:Patch' failed.
Traceback (most recent call last):
........ ----------> TRUNCATED_FOR_READABILITY
raise user_error
patch_errors.UserError: Failed to apply patch roles_groups_users! Error: Role WorkloadStorageManagement not found in VC..
yyyy-mm-dd ERROR __main__ Patch vCSA failed
yyyy-mm-dd wcp:Patch ERROR roles_groups_users Removing privileges {'ContentLibrary.ManageClusterRegistryResource'} from vSphereKubernetesManager role is not supported
yyyy-mm-dd wcp:Patch INFO roles_groups_users Checking if privileges should be updated for role {'id': '1007', 'name': 'SupervisorServiceCluster', 'description': 'This role entitles the SupervisorService Operator to create/delete namespaces against a cluster, and configure the cluster.', 'priv_ids': ['Host.Inventory.EditCluster', 'Namespaces.Configure']}
yyyy-mm-dd wcp:Patch ERROR wcp Failed to apply patch %s! Error: %s.
yyyy-mm-dd wcp:Patch ERROR wcp Not all patches were applied. Latest applied patch is 1
yyyy-mm-dd wcp:Patch ERROR vmware_b2b.patching.executor.hook_executor Patch hook 'wcp:Patch' failed.
Traceback (most recent call last):
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/py/vmware_b2b/patching/executor/hook_executor.py", line 74, in executeHook
executionResult = systemExtension(args)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/libs/sdk/extensions.py", line 106, in __call__
result = self.extension(*args)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/libs/sdk/extensions.py", line 123, in _func
return func(*args)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/payload/components-script/wcp/__init__.py", line 213, in doPatching
doIncrementalPatching(current_version)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/payload/components-script/wcp/__init__.py", line 340, in doIncrementalPatching
raise user_error
patch_errors.UserError: Failed to apply patch roles_groups_users! Error: Role SupervisorServiceCluster not found in VC..
yyyy-mm-dd ERROR vmware_b2b.patching.phases.patcher Patch hook Patch got ComponentWrapperError.
Traceback (most recent call last):
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/py/vmware_b2b/patching/phases/patcher.py", line 203, in patch
_patchComponents(ctx, userData, statusAggregator.reportingQueue)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/py/vmware_b2b/patching/phases/patcher.py", line 85, in _patchComponents
executeComponentHook(Hook.Patch, ctx, c, userData, reportingQueue)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/py/vmware_b2b/patching/executor/execution_facade.py", line 98, in executeComponentHook
reportQueue, identifier, expectedResultType)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/py/vmware_b2b/patching/executor/execution_facade.py", line 53, in executeHook
result = executor.executeHook(scriptFile, hook, args, reportQueue, reportIdentifier)
File "/storage/seat/software-updatezygbqct1/stage/scripts/patches/py/vmware_b2b/patching/executor/hook_executor_process.py", line 119, in executeHook
raise ex
patch_errors.ComponentError
yyyy-mm-dd WARNING root stopping status aggregation...
yyyy-mm-dd ERROR __main__ Patch vCSA failed
PatchRunner.log:
yyyy-mm-dd wcp:Patch INFO root Read privilege granted for user wcp to VECS store vpxd-extension
yyyy-mm-dd wcp:Patch INFO root Read privilege granted for user wcp to VECS store wcp
yyyy-mm-dd wcp:Patch INFO wcp Applied patch roles_groups_users for wcp.
yyyy-mm-dd wcp:Patch INFO wcp Applying patch update_ls_registration.
yyyy-mm-dd wcp:Patch ERROR root Failed to update WCP registration with lookup service; 'WorkloadStorageManagement'
yyyy-mm-dd wcp:Patch ERROR wcp Failed to apply patch %s! Error: %s.
yyyy-mm-dd wcp:Patch ERROR wcp Not all patches were applied. Latest applied patch is 2
yyyy-mm-dd wcp:Patch ERROR vmware_b2b.patching.executor.hook_executor Patch hook 'wcp:Patch' failed.
Traceback (most recent call last):
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/py/vmware_b2b/patching/executor/hook_executor.py", line 74, in executeHook
executionResult = systemExtension(args)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/libs/sdk/extensions.py", line 106, in __call__
result = self.extension(*args)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/libs/sdk/extensions.py", line 123, in _func
return func(*args)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/payload/components-script/wcp/__init__.py", line 225, in doPatching
doIncrementalPatching(current_version)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/payload/components-script/wcp/__init__.py", line 343, in doIncrementalPatching
raise user_error
patch_errors.UserError: Failed to apply patch update_ls_registration! Error: 'WorkloadStorageManagement'.
yyyy-mm-dd ERROR vmware_b2b.patching.phases.patcher Patch hook Patch got ComponentWrapperError.
Traceback (most recent call last):
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/py/vmware_b2b/patching/phases/patcher.py", line 208, in patch
_patchComponents(ctx, userData, statusAggregator.reportingQueue)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/py/vmware_b2b/patching/phases/patcher.py", line 90, in _patchComponents
executeComponentHook(Hook.Patch, ctx, c, userData, reportingQueue)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/py/vmware_b2b/patching/executor/execution_facade.py", line 97, in executeComponentHook
result = executeHook(c.patchScript, hook, args,
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/py/vmware_b2b/patching/executor/execution_facade.py", line 53, in executeHook
result = executor.executeHook(scriptFile, hook, args, reportQueue, reportIdentifier)
File "/storage/updatemgr/software-updates0gcso_n/stage/scripts/patches/py/vmware_b2b/patching/executor/hook_executor_process.py", line 119, in executeHook
raise ex
patch_errors.ComponentError
yyyy-mm-dd WARNING root stopping status aggregation...
yyyy-mm-dd ERROR __main__ Patch vCSA failed
upgrade_hook_PatchHook:
{
"progress": 17,
"progress_message": {
"detail": [
{
"id": "wcp.patch.incrementalPatching.fail",
"translatable": "Failed to apply patch %(0)s! Error: %(1)s.",
"args": [
"update_ls_registration",
"'WorkloadStorageManagement'"
],
"localized": "Failed to apply patch update_ls_registration! Error: 'WorkloadStorageManagement'."
}
],
"componentKey": "wcp:Patch",
"problemId": null,
"resolution": null
},
"status": "error",
"info": [],
"warning": [],
"question": null,
"error": {
"detail": [
{
"id": "wcp.patch.incrementalPatching.fail",
"translatable": "Failed to apply patch %(0)s! Error: %(1)s.",
"args": [
"update_ls_registration",
"'WorkloadStorageManagement'"
],
"localized": "Failed to apply patch update_ls_registration! Error: 'WorkloadStorageManagement'."
}
],
"componentKey": "wcp:Patch",
"problemId": null,
"resolution": null
},
"start_time": "yyyy-mm-dd",
"end_time": "yyyy-mm-dd"
}
WorkloadStorageManagementvSphereKubernetesManagerSupervisorServiceClusterSupervisorServiceRootFolderSupervisorServiceGlobalVMOperatorControllerVMOperatorControllerGlobalVMServicesAdministratorNsxAuditorNsxViAdministratorNsxAdministrator
This failure is caused by either of the following conditions:
ldapsearch -o ldif-wrap=no -LLL -h localhost -b "cn=RoleModel,cn=VmwAuthz,cn=Services,dc=vsphere,dc=local" -s sub -D "cn=Administrator,cn=Users,dc=vsphere,dc=local" -w 'Password' > /var/tmp/role.ldif
From the vmon logs, search for role name and id that the wcp service is failing to start with from the ldif output.
Correct roleid will look like the following
dn: cn=1005,cn=RoleModel,cn=VmwAuthz,cn=services,dc=vsphere,dc=localcn: 1005objectClass: topobjectClass: vmwAuthzRolenTSecurityDescriptor:: AQAEgBQAAAA0AAAAAAAAAEQAAAABBgAAAAAABxUAAAAAAAAAiIgAAAAAAAIAAAAA9AEAAAECAAAAAAAFIAAAACACAAACAGAAAwAAAAAAGAAwAAAAAQIAAAAAAAcgAAAAmgIAAAAAGAAzAAAgAQIAAAAAAAUgAAAAIAIAAAAAKAAzAAAgAQYAAAAAAAcVAAAAAAAAAIiIAAAAAAACAAAAAPQBAAA=vmwAuthzRolePrivilegeId: System.AnonymousvmwAuthzRolePrivilegeId: System.ReadvmwAuthzRolePrivilegeId: System.ViewvmwAuthzRolePrivilegeId: VirtualMachine.Config.AddRemoveDevicevmwAuthzRolePrivilegeId: Cryptographer.ClonevmwAuthzRolePrivilegeId: VirtualMachine.Config.EditDevicevmwAuthzRolePrivilegeId: Cryptographer.MigratevmwAuthzRolePrivilegeId: Cryptographer.EncryptvmwAuthzRolePrivilegeId: VirtualMachine.Interact.DeviceConnectionvmwAuthzRolePrivilegeId: VirtualMachine.Inventory.DeletevmwAuthzRolePrivilegeId: Cryptographer.AddDiskvmwAuthzRolePrivilegeId: VirtualMachine.Inventory.CreatevmwAuthzRolePrivilegeId: VirtualMachine.Config.AddNewDiskvmwAuthzRolePrivilegeId: Cryptographer.RecryptvmwAuthzRolePrivilegeId: VirtualMachine.Interact.PowerOnvmwAuthzRolePrivilegeId: InventoryService.Tagging.ObjectAttachablevmwAuthzRolePrivilegeId: Datastore.AllocateSpacevmwAuthzRolePrivilegeId: Cryptographer.EncryptNewvmwAuthzRolePrivilegeId: VirtualMachine.Interact.PowerOffvmwAuthzRolePrivilegeId: Resource.AssignVMToPoolvmwAuthzRoleVersion: 1vmwAuthzRoleName: vSphereKubernetesManagervmwAuthzRoleDescription: This role entitles the vSphere Kubernetes Manager to perform lifecycle management of vSphere Pods, including vSphere Pod scheduling, creation, deletion and attaching of devices.
dn: cn=-1279459366,cn=RoleModel,cn=VmwAuthz,cn=services,dc=vsphere,dc=localnTSecurityDescriptor:: AQAEgBQAAAA0AAAAAAAAAFQAAAABBgAAAAAABxUAAACGT97Gs1SMHOn5RjUulShT9AEAAAEGAAAAAAAHFQAAAIZP3sazVIwc6flGNS6VKFMgAgAAAgBwAAMAAAAAABgAMAAAAAECAAAAAAAHIAAAAJoCAAAAACgAMwAAIAEGAAAAAAAHFQAAAIZP3sazVIwc6flGNS6VKFMgAgAAAAAoADMAACABBgAAAAAABxUAAACGT97Gs1SMHOn5RjUulShT9AEAAA==objectClass: topobjectClass: vmwAuthzRolecn: -1279459366vmwAuthzRolePrivilegeId: System.AnonymousvmwAuthzRolePrivilegeId: System.ReadvmwAuthzRolePrivilegeId: System.ViewvmwAuthzRolePrivilegeId: VirtualMachine.Config.AddRemoveDevicevmwAuthzRolePrivilegeId: VirtualMachine.Inventory.DeletevmwAuthzRolePrivilegeId: VirtualMachine.Interact.PowerOnvmwAuthzRolePrivilegeId: ContentLibrary.ManageClusterRegistryResourcevmwAuthzRolePrivilegeId: Datastore.AllocateSpacevmwAuthzRolePrivilegeId: VirtualMachine.Interact.PowerOffvmwAuthzRolePrivilegeId: VirtualMachine.Inventory.CreatevmwAuthzRolePrivilegeId: Resource.AssignVMToPoolvmwAuthzRolePrivilegeId: VirtualMachine.Config.AddNewDiskvmwAuthzRoleVersion: 2vmwAuthzRoleName: vSphereKubernetesManagervmwAuthzRoleDescription:: IA==ldapdelete -H ldap://localhost -D "cn=administrator,cn=users,dc=vsphere,dc=local" -w "<password>" "cn=-1279459366,cn=RoleModel,cn=VmwAuthz,cn=services,dc=vsphere,dc=local"
service-control --restart wcp