Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I have an instance of SQL Server on my machine.

Machine: Bert01 SQL Server instance: Bert2008

I connect to it using SSMS putting Bert01\Bert2008 in the Server name box, using sa and the .

When I remote desktop to a server, open SSMS and use the connection details above, ie connecting back to my own dev machine, it works. SSMS connects, and I can see databases, browse them, and run queries.

When I open SSMS on my local machine, I get the following message :-

Connect to Server Cannot connect to Bert01\Bert2008.

Additional information:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 - No connection could be made because the target machine actively refused it.) (Microsoft SQL Server, ErrorL 10061)

At the moment I have only tried connecting remotely, which works.

This has only happened late in the afternoon yesterday while I was debugging an app in VB6 (stop sniggering).

SQL Server @@Version running on my dev machine:-

Microsoft SQL Server 2008 R2 (RTM) - 10.50.1617.0 (Intel X86) Apr 22 2011 11:57:00 Copyright (c) Microsoft Corporation Express Edition with Advanced Services on Windows NT 5.1 (Build 2600: Service Pack 3)

In the SQL Server Configuration Manager the following protocols for this instance are shown :-

  • Shared Memory - Enabled
  • Named Pipes - Disabled (at Matt Roberts suggestion)
  • TCP/IP - Enabled
  • VIA - Disabled (after reading the log file, and also at Matt Robert suggestion)

Here is the log file after I restarted the service.

2012-07-06 10:43:05.09 Server      Microsoft SQL Server 2008 R2 (RTM) - 10.50.1617.0 (Intel X86) 
    Apr 22 2011 11:57:00 
    Copyright (c) Microsoft Corporation
    Express Edition with Advanced Services on Windows NT 5.1 <X86> (Build 2600: Service Pack 3)

2012-07-06 10:43:05.09 Server      Error: 17054, Severity: 16, State: 1.
2012-07-06 10:43:05.09 Server      The current event was not reported to the Windows Events log. Operating system error = 1502(failed to retrieve text for this error. Reason: 1815). You may need to clear the Windows Events log if it is full.
2012-07-06 10:43:05.09 Server      (c) Microsoft Corporation.
2012-07-06 10:43:05.09 Server      All rights reserved.
2012-07-06 10:43:05.09 Server      Server process ID is 5840.
2012-07-06 10:43:05.09 Server      Error: 17054, Severity: 16, State: 1.
2012-07-06 10:43:05.09 Server      The current event was not reported to the Windows Events log. Operating system error = 1502(failed to retrieve text for this error. Reason: 1815). You may need to clear the Windows Events log if it is full.
2012-07-06 10:43:05.09 Server      Authentication mode is MIXED.
2012-07-06 10:43:05.09 Server      Logging SQL Server messages in file 'c:\Program Files\Microsoft SQL Server\MSSQL10_50.BERT2008\MSSQL\Log\ERRORLOG'.
2012-07-06 10:43:05.09 Server      This instance of SQL Server last reported using a process ID of 5536 at 06/07/2012 10:43:03 (local) 06/07/2012 09:43:03 (UTC). This is an informational message only; no user action is required.
2012-07-06 10:43:05.09 Server      Registry startup parameters: 
     -d c:\Program Files\Microsoft SQL Server\MSSQL10_50.BERT2008\MSSQL\DATA\master.mdf
     -e c:\Program Files\Microsoft SQL Server\MSSQL10_50.BERT2008\MSSQL\Log\ERRORLOG
     -l c:\Program Files\Microsoft SQL Server\MSSQL10_50.BERT2008\MSSQL\DATA\mastlog.ldf
2012-07-06 10:43:05.10 Server      SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required.
2012-07-06 10:43:05.10 Server      Detected 2 CPUs. This is an informational message; no user action is required.
2012-07-06 10:43:05.55 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.
2012-07-06 10:43:05.60 Server      Node configuration: node 0: CPU mask: 0x00000003:0 Active CPU mask: 0x00000003:0. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required.
2012-07-06 10:43:05.62 spid5s      Starting up database 'master'.
2012-07-06 10:43:05.68 spid5s      Recovery is writing a checkpoint in database 'master' (1). This is an informational message only. No user action is required.
2012-07-06 10:43:05.73 spid5s      FILESTREAM: effective level = 0, configured level = 0, file system access share name = 'BERT2008'.
2012-07-06 10:43:05.76 spid5s      SQL Trace ID 1 was started by login "sa".
2012-07-06 10:43:05.76 spid5s      Starting up database 'mssqlsystemresource'.
2012-07-06 10:43:05.78 spid5s      The resource database build version is 10.50.1617. This is an informational message only. No user action is required.
2012-07-06 10:43:05.86 spid5s      Server name is 'BERT01\BERT2008'. This is an informational message only. No user action is required.
2012-07-06 10:43:05.86 Server      Warning: Support for the VIA protocol is deprecated and will be removed in a future version of Microsoft SQL Server. If possible, use a different network protocol and disable VIA.
2012-07-06 10:43:05.86 Server      Virtual Interface Architecture protocol is not supported for this particular edition of SQL Server.
2012-07-06 10:43:05.86 spid10s     Starting up database 'model'.
2012-07-06 10:43:05.86 spid5s      Informational: No full-text supported languages found.
2012-07-06 10:43:05.87 spid5s      Starting up database 'msdb'.
2012-07-06 10:43:06.10 spid10s     Clearing tempdb database.
2012-07-06 10:43:06.11 Server      A self-generated certificate was successfully loaded for encryption.
2012-07-06 10:43:06.11 Server      Server is listening on [ 'any' <ipv4> 3377].
2012-07-06 10:43:06.11 Server      Server local connection provider is ready to accept connection on [ \\.\pipe\SQLLocal\BERT2008 ].
2012-07-06 10:43:06.11 Server      Server local connection provider is ready to accept connection on [ \\.\pipe\MSSQL$BERT2008\sql\query ].
2012-07-06 10:43:06.11 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.
2012-07-06 10:43:06.16 Server      The SQL Server Network Interface library successfully registered the Service Principal Name (SPN) [ MSSQLSvc/BERT01.MITEC:BERT2008 ] for the SQL Server service. 
2012-07-06 10:43:06.16 Server      The SQL Server Network Interface library successfully registered the Service Principal Name (SPN) [ MSSQLSvc/BERT01.MITEC:3377 ] for the SQL Server service. 
2012-07-06 10:43:06.16 Server      SQL Server is now ready for client connections. This is an informational message; no user action is required.
2012-07-06 10:43:06.38 spid10s     Starting up database 'tempdb'.
2012-07-06 10:43:06.43 spid13s     The Service Broker protocol transport is disabled or not configured.
2012-07-06 10:43:06.43 spid13s     The Database Mirroring protocol transport is disabled or not configured.
2012-07-06 10:43:06.44 spid13s     Service Broker manager has started.
2012-07-06 10:43:06.44 spid5s      Recovery is complete. This is an informational message only. No user action is required.

Now, interestingly, Mr Badger suggested using .\Bert2008 to connect which still didn't work with the sa and the , HOWEVER, using Windows Authentication worked. Which it never has before.

For the last two months since I started I've always logged in to Bert01\Bert2008 using SQL Server authentication, and the password.

Now when I try it again, in order to write this edit up, I can connect to .\Bert2008 using Windows Auth, or SQL Server auth, but not Bert01\Bert2008 which I've been using for months.

Odd.

share

migration rejected from stackoverflow.com Oct 3 '13 at 21:58

This question came from our site for professional and enthusiast programmers. Votes, comments, and answers are locked due to the question being closed here, but it may be eligible for editing and reopening on the site where it originated.

closed as off-topic by Max Vernon, Paul White, RolandoMySQLDBA, bluefeet, Mark Storey-Smith Oct 3 '13 at 21:58

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Too localized - this could be because your code has a typo, basic error, or is not relevant to most of our audience. Consider revising your question so that it appeals to a broader audience. As it stands, the question is unlikely to help other users (regarding typo questions, see this meta question for background)." – Max Vernon, Paul White, RolandoMySQLDBA, bluefeet, Mark Storey-Smith
If this question can be reworded to fit the rules in the help center, please edit the question.

    
Bit of a guess, but if you're connecting locally, is it trying to use a different protocol than it would use if you connected remotely, and that different protocol is not set up correctly. Have you tried turning off named pipes? –  Matt Roberts Jul 6 '12 at 9:26
1  
Also, does .\Bert2008 make a difference? Plus you can try tcp:.\Bert2008 too –  Matt Roberts Jul 6 '12 at 9:28
    
What @MattRoberts said: what network protocols are enabled for the SQL Server instance? –  PhilPursglove Jul 6 '12 at 9:28
    
Try just enabling tcp and shared mem, does that help? –  Matt Roberts Jul 6 '12 at 9:38