New info: Navigating to localhost:1434 in Chrome gives me an "ERR_EMPTY_RESPONSE", while other ports give me an "Oops! This link appears to be broken". So it seems to binding ok there?
Can't connect to localhost. Additional Information --> Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. (Microsoft Sql Server)
I could probably just use 127.0.0.1 everywhere, but it scares me that localhost isn't working and I'd like to figure out why.
I'm not much of a networking or sql server guy so I'm stuck. If you want me to try anything to help diagnose just put it in a comment and I'll give it a go.
Setting SDK environment relative to C:\Program Files\Microsoft SDKs\Windows\v6.1 Targeting Windows Server 2008 x86 DEBUG C:\Program Files\Microsoft SDKs\Windows\v6.1>netstat -ano | findstr 1434 UDP 0.0.0.0:1434 *:* 6868 UDP [::]:1434 *:* 6868 C:\Program Files\Microsoft SDKs\Windows\v6.1>netstat -ano | findstr 1433 TCP 0.0.0.0:1433 0.0.0.0:0 LISTENING 2268 TCP 127.0.0.1:1433 127.0.0.1:50758 ESTABLISHED 2268 TCP 127.0.0.1:50758 127.0.0.1:1433 ESTABLISHED 5008 TCP [::]:1433 [::]:0 LISTENING 2268 TCP [::1]:1433 [::1]:51202 ESTABLISHED 2268 TCP [::1]:1433 [::1]:51616 ESTABLISHED 2268 TCP [::1]:51202 [::1]:1433 ESTABLISHED 5008 TCP [::1]:51616 [::1]:1433 ESTABLISHED 5008 C:\Program Files\Microsoft SDKs\Windows\v6.1>
In case it helps
2010-01-30 12:58:59.01 Server Microsoft SQL Server 2008 (SP1) - 10.0.2531.0 (Intel X86) Mar 29 2009 10:27:29 Copyright (c) 1988-2008 Microsoft Corporation Express Edition on Windows NT 6.0 (Build 6002: Service Pack 2) 2010-01-30 12:58:59.01 Server (c) 2005 Microsoft Corporation. 2010-01-30 12:58:59.01 Server All rights reserved. 2010-01-30 12:58:59.01 Server Server process ID is 2268. 2010-01-30 12:58:59.01 Server System Manufacturer: 'Dell Inc.', System Model: 'Inspiron 1545'. 2010-01-30 12:58:59.01 Server Authentication mode is MIXED. 2010-01-30 12:58:59.02 Server Logging SQL Server messages in file 'c:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\Log\ERRORLOG'. 2010-01-30 12:58:59.02 Server This instance of SQL Server last reported using a process ID of 7396 at 1/30/2010 12:57:38 PM (local) 1/30/2010 5:57:38 PM (UTC). This is an informational message only; no user action is required. 2010-01-30 12:58:59.02 Server Registry startup parameters: -d c:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA\master.mdf -e c:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\Log\ERRORLOG -l c:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA\mastlog.ldf 2010-01-30 12:58:59.02 Server SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required. 2010-01-30 12:58:59.02 Server Detected 2 CPUs. This is an informational message; no user action is required. 2010-01-30 12:58:59.08 Server Using dynamic lock allocation. Initial allocation of 2500 Lock blocks and 5000 Lock Owner blocks per node. This is an informational message only. No user action is required. 2010-01-30 12:58:59.17 Server Node configuration: node 0: CPU mask: 0x00000003 Active CPU mask: 0x00000003. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required. 2010-01-30 12:58:59.30 spid7s Starting up database 'master'. 2010-01-30 12:58:59.41 spid7s Recovery is writing a checkpoint in database 'master' (1). This is an informational message only. No user action is required. 2010-01-30 12:58:59.67 spid7s FILESTREAM: effective level = 0, configured level = 0, file system access share name = 'SQLEXPRESS'. 2010-01-30 12:58:59.92 spid7s SQL Trace ID 1 was started by login "sa". 2010-01-30 12:58:59.94 spid7s Starting up database 'mssqlsystemresource'. 2010-01-30 12:58:59.95 spid7s The resource database build version is 10.00.2531. This is an informational message only. No user action is required. 2010-01-30 12:59:00.82 spid7s Server name is 'DELL\SQLEXPRESS'. This is an informational message only. No user action is required. 2010-01-30 12:59:00.83 Server A self-generated certificate was successfully loaded for encryption. 2010-01-30 12:59:00.84 Server Server is listening on [ 'any' 1433]. 2010-01-30 12:59:00.84 Server Server is listening on [ 'any' 1433]. 2010-01-30 12:59:00.84 spid10s Starting up database 'model'. 2010-01-30 12:59:00.85 Server Server local connection provider is ready to accept connection on [ \\.\pipe\SQLLocal\SQLEXPRESS ]. 2010-01-30 12:59:00.86 Server Server local connection provider is ready to accept connection on [ \\.\pipe\MSSQL$SQLEXPRESS\sql\query ]. 2010-01-30 12:59:00.86 Server Dedicated administrator connection support was not started because it is disabled on this edition of SQL Server. If you want to use a dedicated administrator connection, restart SQL Server using the trace flag 7806. This is an informational message only. No user action is required. 2010-01-30 12:59:00.87 Server The SQL Server Network Interface library could not register the Service Principal Name (SPN) for the SQL Server service. Error: 0x54b, state: 3. Failure to register an SPN may cause integrated authentication to fall back to NTLM instead of Kerberos. This is an informational message. Further action is only required if Kerberos authentication is required by authentication policies. 2010-01-30 12:59:00.87 spid7s Informational: No full-text supported languages found. 2010-01-30 12:59:00.87 Server SQL Server is now ready for client connections. This is an informational message; no user action is required. 2010-01-30 12:59:00.91 spid7s Starting up database 'msdb'. 2010-01-30 12:59:01.21 spid10s Clearing tempdb database. 2010-01-30 12:59:02.78 spid10s Starting up database 'tempdb'. 2010-01-30 12:59:03.30 spid13s The Service Broker protocol transport is disabled or not configured. 2010-01-30 12:59:03.30 spid13s The Database Mirroring protocol transport is disabled or not configured. 2010-01-30 12:59:03.31 spid7s Recovery is complete. This is an informational message only. No user action is required. 2010-01-30 12:59:03.31 spid13s Service Broker manager has started.
Edited my answer based on your additional info.
I would follow all of the steps here and let us know.
You should use localhost\SQLEXPRESS to connect to the local instance of SQL Server - assuming the instance is called SQLEXRESS.
I noticed that in your comments you say that you are getting an error when you do this, can you please post it because it might help to solve your problem.
Also, instead of using 127.0.0.1 you can use .\SQLEXPRESS in your connection strings to connect to the local instance of SQL Server Express.
Try enabling remote connections temporarily, it may be that SQL Server sees a hostname and thinks that it's a remote connection.
Some ideas...
Unfortunately, it doesn't look like you can easily do a localhost packet capture (so you're SOL there)...which would have been neat to see.
If you've already resolved this, I'd be curious to know what the answer was.
When you connect to the server in SSMS, what happens if you specify named pipes instead of TCP/IP as the network protocol in the Options, connection Properties?
here is my netstat, if it helps:
C:\Users\fff>netstat -ano | findstr 1433 TCP 0.0.0.0:1433
0.0.0.0:0 LISTENING 3680 TCP [::]:1433 [::]:0 LISTENING 3680C:\Users\fff>netstat -ano | findstr 1434 TCP 127.0.0.1:1434
0.0.0.0:0 LISTENING 3680 TCP [::1]:1434 [::]:0 LISTENING 3680 UDP 0.0.0.0:1434
: 2644 UDP [::]:1434 : 2644
So a few minor issues here. Port 1434 UDP is for the SQL Server Browser service. This is like SQL DNS where it will map your request for a named instance to a port number. SQL assigns port numbers dynamically to the named instances and reserves 1433 TCP for the default installation, which I don't think Express does.
Please try this and report back your findings: 127.0.0.1,1433 localhost,1433 .,1433
This is the same as specifying the name. Open up SQL Profiler, and look for 'failed logins, successful logins' under the 'security audit' tab. This will show you if you're even connecting to the SQL Engine. If you don't see the log on attempt, you're not hitting the engine which means it's being blocked.
Can you try changing the port from 1433 to something else such as 11433 and report back? Did you remove the 0 in 'dynamic port' in SQL Configuration manager per network adapter? That could help too.
Timed out. Never got an answer that worked, but this was way too long ago to find one now. Thanks for everyone who tried to help.
"My hosts file contains the default entries ("127.0.0.1 localhost" and "::1 localhost")"
Can you try to delete "::1 localhost" in HOSTS. For me it looks unnecessary and confusing (to which one localhost is supposed to resolve?). For ex., my HOSTS doesn't have it (only "localhost 127.0.0.1") and resolves localhost though differently
ping -a localhost resolves to ""::1" with network connection enabled and to 127.0.0.1 when network connection is disabled
Also, try to disable IPv6 on NIC TCP/IP properties or NIC connection just to narrow the area.
Waiting to hear your results!
Update1 (continuing to speak with myself, very exciting!):
User contributions licensed under CC BY-SA 3.0