Register-SPworkflowservice unable to connect to the remote service at Workflow Manager 2016

Unable to connect to the remote service Workflow Manager

In this post, we will solve “Register-SPworkflowservice unable to connect to the remote service at Workflow Manager” in SharePoint 2016 and 2013.

Register-SPworkflowservice unable to connect to the remote service at Workflow Manager

You might also like to learn how to SharePoint 2016: Configure Workflow Manager.


Register-SPworkflowservice unable to connect to the remote service at


I have installed the SharePoint Workflow Manager by following the mentioned steps at Install and Configure Workflow Manager In SharePoint 2013 that had been installed properly,

But when I tried to configure the SharePoint host to use a workflow service by running  Register-SPWorkflowService cmdlet, I got the below error!

Register-SPworkflowservice unable to connect to the remote service at Workflow Manager

Register-SPworkflowservice : unable to connect to the remote service

You might also like to read Failed to query the OAuth S2S metadata endpoint at URI.


Why you got unable to connect to the remote service workflow manager?

The “Register-SPworkflowservice : unable to connect to the remote service” Issue usually occurs because of using an incorrect URL and Port (12990) at”WorkflowHostUri” parameter in Register-SPWorkflowService cmdlet.

  1. This Port must be opened on all Workflow Manager Servers.
  2. This port should be the same port that has been provided during configuring the Workflow Manager port as shown below.
Configure Workflow Manager Ports

Note: By default, The port (12290) is for HTTPs and (12291) for HTTP.

By the way, the mentioned port in Microsoft TechNet example was not correct, as you can see, the documentation used the “12990”, not the default port “12290” as shown below.

Register-SPworkflowservice cmdlet

You might also like to read Workflow Manager: Port is blocked.


How to solve Unable to connect to the remote service workflow manager issue?

To solve the “unable to connect to the remote service workflow manager” issue, you should make sure that you have provided the correct URL and Port at “WorkflowHostUri” parameter in Register-SPWorkflowService. As well as, you should make sure that you are using the same port that you have set during configuring the Workflow Manager and this port should be not blocked by any other program like antivirus or firewall.

Get SharePoint Workflow Manager details using PowerShell

First, you should make sure that the provided port is the correct one that has been used during Configuring the Workflow Manager!

Get SharePoint Workflow Manager Ports

If you didn’t remember which ports you have used during configuring SharePoint Workflow Manager, try to run the below cmdlet

Get-WFFarm | select httpport,httpspor
Register-SPworkflowservice unable to connect to the remote service at Workflow Manager 2016

Based on the above results, you should run “Register-SPworkflowservice” .

Check SharePoint Workflow Manager Ports Status

You should also make sure that the SharePoint Workflow Manager Ports are opened and not blocked by any other program like Antivirus, Firewall ..etc.

  • Open Command prompt as administrator.
Run Command Prompt As Administrator
  • Perform Telnet the port (telnet  ServerIP  Port),
telnet Server IP Port
  • In case, the telnet cmdlet shows “couldn’t open a connection to the host“, that means
    • The provided port is not the same as the port that you have provided during configuring SharePoint workflow manager.
    • Or it’s the correct port but it is not opened, so you should ask your network Admin to open it on all Workflow Manager Servers within the farm.
check port connectivity via telnet command

If Telnet command is not recognized, you should check ‘telnet’ is not recognized as an internal or external command, operable program or batch file to enable it.


Register SharePoint Workflow Service

Now, try to register the SharePoint workflow service by providing the correct Workflow Host Uri.

  • Open SharePoint Management Shell as Administrator.
Run SharePoint Management Shell as Administrator
Register-SPWorkflowService -SPSite https://SiteCollection -WorkflowHostUri https://WorkflowURL:12290 -AllowOAuthHttp
  • The workflow should be registered properly now.
Register SharePoint Workflow Service

SPSite: Specifies a site collection to configure.

It seems that each site collection needs to be registered with workflow service. But actually it’s not 100% correct, once you have registered a workflow service to any SharePoint site collection within the farm, it will be enabled for all SharePoint web applications/site collections. I am pretty sure about this behavior and that what I got on my farm.

WorkflowHostUri: Specifies a string of the full URI for the Workflow Service.

The provided ports must be the same provided ports in the Configure Ports step as above mentioned.

by default, it’s 12291 for HTTP and 12290 for HTTPS.

Reregister SharePoint Workflow Manager Service

If you still can’t register the SharePoint Workflow Manager Service, so it’s strongly recommended to check


Check SharePoint Workflow Manager Connectivity Status

In this section, we will make sure that the SharePoint Workflow Manager Service has been registered and worked properly.

You might also like to read Workflow Manager Health Checklist.

Check SharePoint Workflow Manager Connectivity Status Using IIS
  • Open IIS > From left side expand Sites > Workflow Management Site.
IIS workflow Manager site
  • From right side > Click Browse.
browse workflow Manager URL
  • The below page should be shown and that means the workflow manager is connected and registered properly.
Check SharePoint Workflow Manager Connectivity Status

If the workflow manager API didn’t work , you will need to check 403 forbidden error.

Check SharePoint Workflow Manager Connectivity Status Using SharePoint Designer
  • Open SharePoint Designer > Workflows > Create Site Workflow > In Platform Type the SharePoint 2013 Workflow should be listed.
Workflow Manager is shown in SharePoint designer
Check SharePoint Workflow Manager Connectivity Status Using Central Administration
  • Open Central Administration > Application Management > Application Services > Click on Workflow Service Application Proxy.
Workflow Service application proxy
  • The Workflow would be Connected as shown below:
SharePoint Workflow service status is connected

Conclusion

In conclusion, we have solved “Register-SPworkflowservice unable to connect to the remote service at Workflow Manager” in SharePoint 2016 and 2013.

Applies To
  • SharePoint Workflow Manager 2016.
  • SharePoint Workflow Manager 2013.
  • SharePoint 2016.
  • SharePoint 2013.
You might also like to read
Have a Question?

If you have any related questions, please don’t hesitate to ask it at deBUG.to Community.

4 thoughts on “Register-SPworkflowservice unable to connect to the remote service at Workflow Manager 2016”

  1. Pingback: Workflow Manager: HTTP 403 Forbidden | SP Geeks

  2. Pingback: The Caller doesn't have the necessary permissions required for this operation | SP Geeks

  3. Hi Mohamed,
    Thanks for your article, and I have a question. Is it an error in Microsoft article ?!

    1. Hi dear,

      No, it’s not an error in Microsoft article, but as I have mentioned, you should use the same port that you have provided during configuring The Workflow Manager.
      However, It would prefer if the documentation mentions the default port value in their article!

      Note: In some cases, you may need to use FQDN at -WorkflowHostUri

Leave a Reply

Scroll to Top