TFS: Exception that throws "SetRight" with the argument "2": "Failed to get user information."

I have a release definition in TFS with two tasks. One of them runs fine, while the other throws an exception, although both have a very smimlar configuration.

Successful task configuration:

CopyFile Task
Source: $(System.DefaultWorkingDirectory)/XXX Build Definition/drop
Machines $(WebServers)
Admin Login: server\user
Password: Password
Protocol: HTTP
Destination Folder: C:\DestFolder

Variables: WebServers: MyServer

Failed task configuration:

RunPowerShellOnRemoteComputer Task
Machines $(WebServers)
Admin Login: server\user
Password: Password
Protocol: HTTP

PowerShell Script: C:\...\script.ps1

Variables: WebServers: MyServer

When performing the second task, I get this exception:

"SetRight" "2" : " ". CategoryInfo: NotSpecified: (:) [], InvocationException FullyQualifiedErrorId: --- > System.Management.Automation.RemoteException: Exception "SetRight" "2" : " ."     --- ---      Microsoft.VisualStudio.Services.DevTestLabs.Deployment.Deployment.PowershellExecutor.Invoke(String errorContextMessage, Boolean writeResultToLog, Boolean isCancellable)      Microsoft.VisualStudio.Services.DevTestLabs.Deployment.Deployment.RemoteDeploymentHelper.InstallServiceInternal(String serviceSourcePath, String serviceName, String destinationFileName)      Microsoft.VisualStudio.Services.DevTestLabs.Deployment.Deployment.RemoteDeploymentHelper.InstallService(String serviceSourcePath, String serviceName, String destinationFileName)      Microsoft.VisualStudio.Services.DevTestLabs.Deployment.Deployment.DeploymentClient.d__24.MoveNext() --- > ( # 0) System.Management.Automation.RemoteException: "SetRight" "2" : " " <. ---       'bgsovswops.eu.hpecorp.net:5985': 'Failed' ## [error], MethodInvocationException\r\n FullyQualifiedErrorId: Exception\r\n "}};]      ## [] System.Management.Automation.RuntimeException: 'VisualStudioRemoteDeployer3e199746-ae71-4ba0-a2ef-f5ce8f25a631' VisualStudioRemoteDeployer.exe. logs : Exception, "SetRight" "2" : "Could ". CategoryInfo: NotSpecified: (:) [], MethodInvocationException FullyQualifiedErrorId:
--- > System.Management.Automation.RuntimeException: " VisualStudioRemoteDeployer3e199746-ae71-4ba0-a2ef-f5ce8f25a631" VisualStudioRemoteDeployer.exe. logs : Exception, "SetRight" "2" : "Could ". CategoryInfo: NotSpecified: (:) [], MethodInvocationException FullyQualifiedErrorId:

--- End of inner exception stack trace ---
at System.Management.Automation.Runspaces.PipelineBase.Invoke(IEnumerable

)      System.Management.Automation.PowerShell.Worker.ConstructPipelineAndDoWork(Runspace rs, Boolean performSyncInvoke)      System.Management.Automation.PowerShell.Worker.CreateRunspaceIfNeededAndDoWork(Runspace rsToUse, Boolean isSync)      System.Management.Automation.PowerShell.CoreInvokeHelper [TInput, TOutput] ( PSDataCollection 1 input, PSDataCollection 1, PSInvocationSettings)      System.Management.Automation.PowerShell.CoreInvoke [TInput, TOutput] ( PSDataCollection 1 input, PSDataCollection 1, PSInvocationSettings)      Microsoft.TeamFoundation.DistributedTask.Handlers.LegacyVSTSPowerShellHost.VSTSPowerShellHost.Main(String [] )

, "Invoke-Expression" C:...\ script.ps1.

, powerscript .

.

+4
1

, . , .

, UPN DOMAIN\Username MACHINENAME\Username.

+7

Source: https://habr.com/ru/post/1677692/


All Articles