Monday, February 20, 2012

remote connection problem

Hi

I'm having a problem connecting to a remote sql server 2000, A, database using asp.net 2.
Im able to connect to another remote database, B, fine but when i connect A i get the following error:

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: TCP Provider, error: 0 - No connection could be made because the target machine actively refused it.)

I figure it might be a server problem. I tried using all sorts of connection strings.

Thanks

Hi,

Did you manage to solve this problem? I have the same problem and I am also finding it hard to find anyone to help me.

Thanks

|||

I'm also having this issue, Server is 2003 IIS 6.0. .NET 2.0 I am writing an application hosted on this server that connects to another 2003 server running sqlserver 2005 standard. There is no Firewall enabled on the db server. Remote connections are enabled on the dbserver and allowed through 1433. I've added local service to the security permissions too as well as the username and password that i'm using in the connection string.

I've gone through various posts regarding this error but to no avail. here's the full error as seen in my browser and the connection string i'm using in web.config

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: TCP Provider, error: 0 - No connection could be made because the target machine actively refused it.)

Description:An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details:System.Data.SqlClient.SqlException: An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: TCP Provider, error: 0 - No connection could be made because the target machine actively refused it.)

web.config

<connectionStrings>
<add name="ConnectionString" connectionString="data source=dbserver;Network=DBMSSOCN;initial catalog=ius_hr;Trusted_Connection=yes;user id=username;password=password;packet size=4096"/>
</connectionStrings>

No comments:

Post a Comment