This article was created in response to a support issue logged with K2. The content may include typographical errors and may be revised at any time without notice. This article is not considered official documentation for K2 software and is provided "as is" with no warranties.
The K2 Blackpearl service will not start after a K2 server reboot.
The following error is presented on the console:
"Error 0 Only one usage of each socket address (protocol/network address/port) is normally permitted; Error Invoking 'StartHostServer' : SourceCode.HostServerLib : Only one usage of each socket address (protocol/network address/port) is normally permitted; Stopped Hosting Server Runtime Debug 1013 Creating Instance: SourceCode.SocketService.AsyncSocketService Press any key to continue...Debug 1015 Enrolling Instance : SourceCode.SocketService.AsyncSocketServiceInfo 8101 Starting socket service... Error 8103 Failed to start socket service: Only one usage of each socket address (protocol/network address/port) is normally permittedError 2001 Error Starting Host Server: System.Net.Sockets.SocketException (0x80004005): Only one usage of each socket address (protocol/network address/port) is normally permittedat System.Net.Sockets.Socket.DoBind(EndPoint endPointSnapshot, SocketAddress socketAddress)at System.Net.Sockets.Socket.Bind(EndPoint localEP)at SourceCode.SocketService.AsyncSocketService.CheckInitialized()at SourceCode.Hosting.Server.Runtime.HostServerEngine.EnrollHostableTypeInstance(IHostableType HostableTypeInstance)at SourceCode.Hosting.Server.Runtime.HostTypeLoader.InitAndEnrollHostableType(String HostedTypeName, String InterfaceName)at SourceCode.Hosting.Server.Runtime.HostTypeLoader.InitAndEnrollHostableTypes(String InterfaceName)at SourceCode.Hosting.Server.Runtime.HostServerEngine.StartHostServer()"
The error indicates that another service is using one of the ports used by K2.
To resolve this issue, please ensure that the K2 Blackpearl service is stopped in Windows Services and there is only one running instance of the process "K2HostServer.exe" in Task Manager.
Note that a Development licence only allows you to start the K2 Blackpearl service in console mode. You will not be able to start it using Windows Services.