Solved

No connection could be made because the target machine actively refused it

Posted on 2007-11-18
5
42,400 Views
Last Modified: 2012-08-14
I have a SQL Server 2005 Express installed on my Intranet server that resides in my DMZ.

I have access from my LAN to my DMZ open.

I have the SQL Server configured to allow remote connections to the server.

When I attempt to access the Database services from my "Microsot SQL Server Management Studio" 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.) (Microsoft SQL Server, Error: 10061)


When I attempt to establisg a connection through ODBC. I get the following error:

Connection failed:
SQLState: '01000'
SQL Server Error: 10061
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]ConnectionOpen (Connect()).
Connection failed:
SQLState: '08001'
SQL Server Error: 17
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]SQL Server does not exist or access denied.

Could an expert please give me some clues at what may be wrong.

Regards

Jim

0
Comment
Question by:jsulliva1957
5 Comments
 
LVL 25

Expert Comment

by:imitchie
ID: 20310639
you need to allow on remote connections on the SS2005Express installation
0
 
LVL 25

Accepted Solution

by:
imitchie earned 500 total points
ID: 20310648
From Start->Programs,Microsoft Sql Server 2005, Configuration Tools, SQL Server Surface Area Configuration
near the bottom, click on Surface Area Configuration for Services and Connections
on the tree at the top left, expand to SQLExpress, Database Engine, Remote Connections.
on the right, click on Local and remote connections, Using both TCP/IP and named pipes.
Apply and click OK.
close all windows opened
0
 
LVL 18

Expert Comment

by:Yveau
ID: 20311341
imitchie is right.
... and don't forget to restart the SQL service !

Hope this helps ...
0
 

Author Closing Comment

by:jsulliva1957
ID: 31409890
Thanks imitchie,

This is EXACTLY the solution.

Regards

Jim
0
 
LVL 6

Expert Comment

by:Jerryuk007
ID: 20563577
imitchie solutions are the most likely cause of the problem...

Also if that doesn't work, please check this:
Is your SQL Server in the same Network Domain as your Client ?
-- If not check the Domain Trust...

Check your user name and password you're using to open your connection.

Also I had a similar problem using OLEDB Connection though a VC++ box to connect to a SQL Server when that application run on Citrix (it worked fine on a normal networked workstation !)... The way arund was to use an ODBC Connection (DSN) but I suspect the problem might have been with an old DLL on the Citrix Server.

Check that the SQL Server accept the type of connection you're trying to use (TCP/IP for both is generally better than Named Pipes especially with "Trusted Auth")...

Hope this helps !

Jerry
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now