The eConnect 2010 Integration Service is unable to start because of a conflict with Port 80.

Written by Steve Endow

Last week, I encountered an issue while deploying an eConnect 2010 integration at a client’s site. The initial installation on the SQL Server for testing went smoothly.

We then deployed it on one of their two load-balanced Citrix servers used by Dynamics GP users without any problems. However, during installation and testing on the second Citrix server, we encountered the familiar “there was no endpoint listening at net.pipe” error. Typically, this is an easy fix.

I checked the Services applet and, as expected, the eConnect 2010 service wasn’t running. Attempting to start the service resulted in an error.

Reviewing the Windows Event Log revealed two errors, one of which provided some clues.

Input parameters: Not applicable Exception type: System.ServiceModel.AddressAlreadyInUseException Exception message: HTTP could not register URL http://+:80/Microsoft/Dynamics/GP/eConnect/mex/ because TCP port 80 is being used by another application.

Exception type: System.Net.HttpListenerException Exception message: The process cannot access the file because it is being used by another process

These errors indicated that the eConnect 2010 service was trying to set up a listener on port 80, which was already in use. We initially suspected IIS, but even after stopping its website and services, the netstat command confirmed something else was using port 80.

After consulting the eConnect 2010 documentation without finding any references to HTTP or port 80, we contacted Microsoft support. They promptly suggested two workarounds.

We opted for the simpler solution: changing a parameter in the eConnect service configuration file. This file is usually located at:

C:\\Program Files\\Microsoft Dynamics\\eConnect 11.0\\Service\\ Microsoft.Dynamics.GP.eConnect.Service.exe.config

Open the file with a text or XML editor and change the httpGetEnabled parameter to false.

Essentially, setting httpGetEnabled to false disables the HTTP publishing of the Web Services Description Language (WSDL) metadata. This detail is primarily relevant for developers.

We learned that the eConnect 2010 service, by default, publishes its WSDL using both HTTP and named pipes (net.pipe). The HTTP method can be viewed in Internet Explorer, while net.pipe uses the WCF ‘metadata exchange’ (mex) endpoint, accessible via the WCF metadata tool (svcutil.exe). Visual Studio can utilize either method to access the WSDL.

The workaround of setting httpGetEnabled = false disables HTTP WSDL publishing, eliminating the need for eConnect to use port 80. The net.pipe WSDL remains available if needed. It’s unclear if a compiled and deployed eConnect integration even uses the WSDL or if it’s only required for setting up the service reference in Visual Studio. That requires further investigation.

The httpGetEnabled=false option should suffice for most situations. However, if it’s not viable, the alternative is to change the port used by the eConnect service to publish the HTTP WSDL. This is slightly more complex and wasn’t necessary in our case. If anyone requires instructions for this method (e.g., using a development server already utilizing port 80), feel free to ask, and I can provide them.

Update (2/21/11): Here are the instructions from Microsoft support for changing the port number for the HTTP WSDL:

Step 1: Modify the Microsoft.Dynamics.GP.eConnect.Service.exe.config file, typically found at C:\\Program Files\\Microsoft Dynamics\\eConnect 11.0\\Service.exe.. Change the httpGetUrl to use a different port, for example, port 83:

1
2
3
4
5
6
7
<serviceBehaviors>
  <behavior name="eConnectServiceBehavior">
    <!--Leaves this to true in order to receive Exeption information in eConnect-->
    <!--This settings turns on Metadata Generation. Metadata allows for consumers to add service references in Visual Studio-->
    <serviceMetadata httpGetEnabled="true" httpGetUrl="[http://localhost:83/Microsoft/Dynamics/GP/eConnect/mex](http://localhost:83/Microsoft/Dynamics/GP/eConnect/mex)"/>
  </behavior>
</serviceBehaviors>

Step 2: Use the command netsh http add urlacl url=http://+:port_number/ user=DOMAIN\\UserName in a Command Prompt to assign the HTTP namespace to the user account running the “eConnect 2010 service.” In this example, we’ll configure it for port 83, assuming the “eConnect 2010 service” runs under the ADOMAIN\\GPService account (check this under Administrative Tools - Services):

1
netsh http add urlacl url=http://+:83/ user=ADOMAIN\\gpservice

Steve Endow is a Dynamics GP Certified Trainer and Dynamics GP Certified IT Professional based in Los Angeles. He also owns Precipio Services, providing Dynamics GP integrations, customizations, and automation solutions.

Find him on Google+ and Twitter

http://www.precipioservices.com

Licensed under CC BY-NC-SA 4.0