SQL Server administration and T-SQL development, Web Programming with ASP.NET, HTML5 and Javascript, Windows Phone 8 app development, SAP Smartforms and ABAP Programming, Windows 7, Visual Studio and MS Office software
Development resources, articles, tutorials, code samples, tools and downloads for ASP.Net, SQL Server, Reporting Services, T-SQL, Windows, AWS, SAP HANA and ABAP


An error occurred while attempting to register the endpoint 'sql_endpoint'


If SQL Server administrators or sql developers try to run the SQL Server Create EndPoint sample scripts on Books OnLine (BOL) on a SQL Server 2005 database, they may get the following SQL Server endpoint error :

Msg 7890, Level 16, State 1, Line 1
An error occurred while attempting to register the endpoint 'sql_endpoint'.
One or more of the ports specified in the CREATE ENDPOINT statement may be bound to another process.
Attempt the statement again with a different port or use netstat to find the application currently using the port and resolve the conflict.





You can execute the below sql Create EndPoint command and see whether you will get the same SQL Server EndPoint error "An error occurred while attempting to register the endpoint 'sql_endpoint'."

CREATE ENDPOINT sql_endpoint
 STATE = STARTED
AS HTTP(
 PATH = '/sql',
 AUTHENTICATION = (INTEGRATED ),
 PORTS = ( CLEAR ),
 SITE = 'KODYAZ'
)
FOR SOAP (
 WEBMETHOD 'GetSqlInfo' (name='master.dbo.xp_msver', SCHEMA=STANDARD ),
 WEBMETHOD 'DayAsNumber' (name='master.sys.fn_MSdayasnumber'),
 WSDL = DEFAULT,
 SCHEMA = STANDARD,
 DATABASE = 'master',
 NAMESPACE = 'http://tempUri.org/'
);

GO
Code

By the way, within the above sql Create Endpoint script "KODYAZ" is the SQL Server 2005 database instance name.

The error description is more detailed in SQL Server 2005. It is indicating that one or more of the ports may be bound to another process. If you check the SQL Server Books OnLine it is written that "Applications that are running under the local system account can bind to any namespace as long as it is free.".

An error occurred while attempting to register the endpoint 'sql_endpoint'.
One or more of the ports specified in the CREATE ENDPOINT statement may be bound to another process.
Attempt the statement again with a different port or use netstat to find the application currently using the port and resolve the conflict.

So port 80 is being used by another process which is more likely by IIS. If you stop the IIS Admin Service, you will see that you can run SQL Server CREATE ENDPOINT statement successfully.

If you browse the url http://kodyaz/sql?wsdl you will see the web service definition document. Although the IIS Admin service is not running.

Create EndPoint wsdl in SQL Server 2005

Of course, stopping an IIS web site just because of SQL Server CREATE ENDPOINT listens to the same port is not an suitable way of implementing sql EndPoint applications in SQL Server environments.
If you use PORTS = (CLEAR) option in the CREATE ENDPOINT t-sql statement, you can also define or specify the port number you want to be used with the SQL Server EndPoint. The default port number is 80.
You can use CLEAR_PORT = clearPort to identify or specify the port number for the sql server end-point you are creating.

CREATE ENDPOINT sql_FSBAppliances
 STATE = STARTED
AS HTTP
(
 SITE = 'localhost',
 PATH = '/Appliances',
 AUTHENTICATION = (INTEGRATED ),
 PORTS = ( CLEAR ),
 CLEAR_PORT = 8088
)
FOR SOAP (
 WEBMETHOD 'efsb'.'ListAppliances'
  (name='efsb.dbo.ListAppliances', schema=STANDARD ),
 WSDL = DEFAULT,
 BATCHES = DISABLED,
 DATABASE = 'eFSB',
 NAMESPACE = 'http://tempUri.org/'
);
GO
Code


SQL Server

SQL Server 2019 Installation
download SQL Server 2019
download SQL Server 2017
download SQL Server 2016
download SQL Server 2014
download SQL Server 2012
MacOS ve SQL Server 2019


Copyright © 2004 - 2021 Eralper YILMAZ. All rights reserved.