Unable to resolve address error on Connection.Open method in MOSS server

  • 12 June 2008
  • 1 reply
  • 4 views

Badge +1

I get an error when I try to connec to the K2 host server from the web app created in Visual Studio  2005 (C#).

The error looks like this:
"Unable to resolve address Integrated=False;IsPrimaryLogin=True;Authenticate=True;EncryptedPassword=False;Host=[host server name];Port=5556;Password=[admin password];UserID=[domain admin user] and port 5252
No such host is known."

C# code is very simple.
-------------------------------------------
SCConnectionStringBuilder connString = new SCConnectionStringBuilder();
connString.Host = "[host server name]";
connString.Authenticate = true;
connString.IsPrimaryLogin = true;
connString.EncryptedPassword = false;
connString.Port = 5556;
connString.Password = "[admin password]";
connString.userID = "[domain admin user]";

Connection conn = new Connection();
conn.Open(connString.ConnectionString);
--------------------------------------------

I am working on a small demo project which doesn't allow me to have multiple server environment. I have MOSS server and K2 server running on the same machine (actually my vpc).
The machine has the following components/servers/services installed:

OS: Windows 2003 SP1
Applications:

MS Office SharePoint Server 2007
K2 BlackPearl SP1
SQL Server 2005 SP1
SQL Serer 2005 Reporing Services
VS 2005 Team edition

Components:
.NetFramework 2,0 SP1 & .Net Framework 3.0 SP1
Visual Studio 2005 Extensions for Windows workflow foundations beta 2.2(en)
Visual Studio extensions for .net 3.0
Composite UI Applicaiton Block in C Sharp
VS 2005 Web Projects (& KB915364)
Report Viewer (without SP1)

The web sites configuration in IIS are as follows:
- Default Web Site: Port 81 and K2 Workspace is created here
- SharePoint: Port 2222
- SharePoint central Administration v3: Port 5555
- Office Server Web Servcies: Port 56737
- SharePoint: Port 1111
- SharePoint: Port 80 and Default SharePoint site

SQL Reporting Services runs under the Default Web Sites (Port 81) as well. The site contains the follwoing applicaitons:
- Reports
- ReportServer
- RuntimeServices
- Workspace

I have configured K2 Blackpearl server and Workspace. Because the default 5555 port is used by Sharepoint, I've changed the host server port to be 5556.
Therefore, the host server port = 5556 and workflow server port = 5252.

I have a project which contains only one K2 Process and this project runs fine. I can deploy the project to the server no problem.

I also have another project which contains ASP.NET applicaitons accessing K2 server, to display customised WorkItemList or initiate the process. And when I try to access to the k2 host server using Connection.Open method, I get the error.

I am not sure why I can't access to the host server from the code. But my workflow project works fine.

By the way, I have applied all security issues relating to K2 installation (i.e. permissions, creating DNS, delegating to run services, etc...)

The K2 runs with the domain account. To be simple, this domain account is also Sharepoint Administrator and belongs to Sharepoint Farm Group as well.
K2 servcie and SQL Reporting Servcies are configured to run under this account as well.

The web applicaiton is using the Integrated Security and applicaiton pool is set to user this admin account.

I am very much at a loss and not sure where to go from here.... Help would be very much appreciated.


1 reply

Badge +1

While fiddling arount the problem, I got rid of all connection string values above.

Instead, I have to connect to the K2 server using:
    Connection conn =  new Connection();
    conn.Open("localhost");

Reply