Link to home
Start Free TrialLog in
Avatar of nerian
nerian

asked on

Unable to connect to SQL Server 05 Express

This is a brand new installation. I re-formatted everything and started over and now i can't connect to my SQL Server 05 express edition.

I have checked Named Pipes/ TCP/IP , both are enabled in Server config manager. I have added an alias for port 1433 for TCP/IP like i used to.

I checked and confirmed i have Mixed Mode login, userpass works when i try SQL Authentication login from the server itself , remote login is enabled and uses TCP/IP and Named Pipes.

SQLServer and Browser in services.msc has been started and are on "Automatic".

Any help? The error message is:

"[DBNETLIB][Connection Open (Connect()).]SQL Server does not exist or access denied."
Avatar of Raja Jegan R
Raja Jegan R
Flag of India image

Kindly check whether you have enabled Remote connections in your Express instance as mentioned below:

http://support.microsoft.com/kb/914277

Also check whether your Express instance is up and running.
If you have more than one instance in your machine, make sure you reference it correctly by providing servername\instancename or serverip\instancename
Avatar of nerian
nerian

ASKER

Already did that before i posted here.
Check if the server is listening on that port using the following command:
netstat -ano | find "1433"

Then check to see if the SQL Server process ID is the one who is "holding" that port (in the task manager you need to add a column in order to see process ID's)

If you don't see the port / it's not the SQL Server which is holding that port then you know where your problem is. I would then verify that the TCP/IP is activated on the correct interface.

If the SQL Server is listening on the correct interface on that port, then this is probably some kind of permission error, you try to connect with a user with no permissions, you try to connect with SA with empty password, etc.



Avatar of nerian

ASKER

When i do netstat -ano | find "1433" , nothing comes up. So i did a netstat -an and i could only see 1434.

I googled and copied a batch file from Microsoft's site on opening port 1433 for SQL Servers on win 2008 server.

This is the code:

@echo =========  SQL Server Ports  ===================
@echo Enabling SQLServer default instance port 1433
netsh firewall set portopening TCP 1433 "SQLServer"
@echo Enabling Dedicated Admin Connection port 1434
netsh firewall set portopening TCP 1434 "SQL Admin Connection"
@echo Enabling conventional SQL Server Service Broker port 4022  
netsh firewall set portopening TCP 4022 "SQL Service Broker"
@echo Enabling Transact-SQL Debugger/RPC port 135
netsh firewall set portopening TCP 135 "SQL Debugger/RPC"
@echo =========  Analysis Services Ports  ==============
@echo Enabling SSAS Default Instance port 2383
netsh firewall set portopening TCP 2383 "Analysis Services"
@echo Enabling SQL Server Browser Service port 2382
netsh firewall set portopening TCP 2382 "SQL Browser"
@echo =========  Misc Applications  ==============
@echo Enabling HTTP port 80
netsh firewall set portopening TCP 80 "HTTP"
@echo Enabling SSL port 443
netsh firewall set portopening TCP 443 "SSL"
@echo Enabling port for SQL Server Browser Service's 'Browse' Button
netsh firewall set portopening UDP 1434 "SQL Browser"
@echo Allowing multicast broadcast response on UDP (Browser Service Enumerations OK)
netsh firewall set multicastbroadcastresponse ENABLE

It's a batch file , i ran it and still no luck.
Avatar of nerian

ASKER

"netsh firewall show state" lists port 1433 as open on all network interfaces as well.
ASKER CERTIFIED SOLUTION
Avatar of oferam
oferam
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Can you try disabling your Windows Firewall once and check to confirm whether this is an issue with Firewall or not..
Avatar of nerian

ASKER

I'll ask my colleague when he gets back from his holiday, he solved it for me remotely from his home yesterday.