cancel
Showing results for 
Search instead for 
Did you mean: 

Database error - The caller was not authenticated by the service.

BrindhaThangamu
Level 3
Hi,

I'm trying to call one test process from powershell remotely which return the below error 'Database error - The caller was not authenticated by the service.'
If I login to the Blueprism server and call the process in powershell then it is working fine. I'm not able to remotely call the same process via invoke-method
The below run is direclty calling the process in powershell residing in the same server.
PS D:\Program Files\Blue Prism Limited\Blue Prism Automate> cd "D:\Program Files\Blue Prism Limited\Blue Prism Automate";
.\automateC /sso /run test_process_1;

Started process:test_process_1
Resource:test_computer_name
Actual resource:test_computer_name
Session:6baa1276-c2bb-4bc3-b51a-1d2f0ad7532a

If I called the same  process remotely with the same credential, it returns below error
PS D:\AutomationBOTs\ServerBuild> Invoke-Command -ComputerName test_computer_name -Credential $credential -ScriptBlock {cd "D:\Program Files\Blue Prism Limited\Blue Prism Automate"; .\AutomateC.exe /sso /run test_process_1;}

Database error - The caller was not authenticated by the service.

------------------------------
Brindha Thangamuthu
------------------------------
1 BEST ANSWER

Best Answers

Thanks for helping me on this issue.
I found the solution. When I'm trying to call a process remotely in powershell, it has to take the credential that I'm using in invoke-command for calling the blueprism process.
Below is the command I was using to trigger the process.
  • Invoke-Command -ComputerName  test_computer -Credential $credential -ScriptBlock {cd "D:\Program Files\Blue Prism Limited\Blue Prism Automate";.\Automate.exe /public /resourcepc; .\AutomateC.exe /sso /run test_process_1;}
In the command, it was not taking the $credential to call the process as it is using SSO
In invoke-command I can specify the credssp authentication to use  $credential.
Below is the command for that.
  • Invoke-Command -ComputerName  test_computer -Credential $credential -Authentication Credssp -ScriptBlock {cd "D:\Program Files\Blue Prism Limited\Blue Prism Automate";.\Automate.exe /public /resourcepc; .\AutomateC.exe /sso /run test_process_1; }
Which ran successfully and triggered the process.

------------------------------
Brindha Thangamuthu
------------------------------

View answer in original post

8 REPLIES 8

ewilson
Staff
Staff
Hi @BrindhaThangamu,

I have a few questions regarding your test.
  1. In your remote test, are the two machines on the same domain or different domains?
  2. How did you set the credential value (the value of $credential)? Are you calling Get-Credential somewhere?
  3. On the remote machine, are you logged in using same account that you were logged into the remote machine with?
Cheers,
 


------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------

@ewilson,

1.
  1. In your remote test, are the two machines on the same domain or different domains? - yes , it is in the same domain.
  2. How did you set the credential value (the value of $credential)? Are you calling Get-Credential somewhere? -> yes like this I'm creating $credential by passing username and password 
          $username="domain_name\username"
          [ ValidateNotNullOrEmpty()]$password="password"
         $password = ConvertTo-SecureString $password -AsPlainText -Force
         [PSCredential]$credential = new-object -typename System.Management.Automation.PSCredential -argumentlist $username,$password

   3. On the remote machine, are you logged in using same account that you were logged into the remote machine with? - yes , same account
   4. The credential I'm using is in the AD also


------------------------------
Brindha Thangamuthu
------------------------------

Hi @BrindhaThangamu,

Based on the error it seems Powershell is not the issue as that appears to be a Blue Prism error message. How are you starting the runtime resource (i.e. the remote machine)? Are you using Login Agent or something else? What account is being used to log into that machine? Is it the same domain account that you're passing in  $credential?

I came across this article on the support site that may be of interest.​

Cheers,

------------------------------
Eric Wilson
Director, Integrations and Enablement
Blue Prism Digital Exchange
------------------------------

AchyutamMehta
Level 3
Hey Brinda,

I think you need to integrate the PowerShell script into the batch file to execute the process and since you are using the same domain machines you can run a batch file from the controller machine and the script would run a process on the runner machine. Just make sure that you are using a login agent which would help you to login into any machine to run the process.

Below is the batch file syntax.

@ECHO OFF
PowerShell.exe -Command "& 'C:\Test_Folder\execute_test_process.ps1'"
PAUSE

------------------------------
Achyutam Mehta
------------------------------

@ewilson 
By running this command, I'm starting the runtime resource, .\Automate.exe /public /resourcepc. If I run this command from in the blueprism server , it will create a runtime resource. But if I run the command remotely, its neither not opening the runtime resource nor throwing any error. The blueprism server and remote server are in the same domain. 
 With cred1 I'm able to login to blueprism server and run the powershell commands successfully. With the same cred1, if I'm calling it via remotely, it throws the mentioned error.
Blueprism was set up for single authentication(only sso).


------------------------------
Brindha Thangamuthu
------------------------------

@AchyutamMehta, Thanks for your reply. I'll surely try this.​​

------------------------------
Brindha Thangamuthu
------------------------------

Thanks for helping me on this issue.
I found the solution. When I'm trying to call a process remotely in powershell, it has to take the credential that I'm using in invoke-command for calling the blueprism process.
Below is the command I was using to trigger the process.
  • Invoke-Command -ComputerName  test_computer -Credential $credential -ScriptBlock {cd "D:\Program Files\Blue Prism Limited\Blue Prism Automate";.\Automate.exe /public /resourcepc; .\AutomateC.exe /sso /run test_process_1;}
In the command, it was not taking the $credential to call the process as it is using SSO
In invoke-command I can specify the credssp authentication to use  $credential.
Below is the command for that.
  • Invoke-Command -ComputerName  test_computer -Credential $credential -Authentication Credssp -ScriptBlock {cd "D:\Program Files\Blue Prism Limited\Blue Prism Automate";.\Automate.exe /public /resourcepc; .\AutomateC.exe /sso /run test_process_1; }
Which ran successfully and triggered the process.

------------------------------
Brindha Thangamuthu
------------------------------

@ewilson, Thanks Eric, I read the article ​

------------------------------
Brindha Thangamuthu
------------------------------