VSS: SQL Server does not exist or access denied

I recently worked on three customer issues. In all those cases, customers were not able to backup databases using Microsoft Volume Shadow Copy Service (VSS). MSDEWriter does not show up with “vssadmin list writers”. And VSS logs the following error message in event log:


Sqllib error: OLEDB Error encountered calling IDBInitialize::Initialize. hr = 0x80004005. SQLSTATE: 08001, Native Error: 17
Error state: 1, Severity: 16
Source: Microsoft OLE DB Provider for SQL Server
Error message: [DBNETLIB]SQL Server does not exist or access denied.


MSDEWriter uses MDAC SQLOLEDB to make connections to all SQL instances installed on a machine. VSS finds SQL server instances and the instance names by enumrating running SQL server services on the box. It uses the default protocol to connect the servers. In order for MSDEWriter to work correctly, it must be able to connect all SQL server instances of interests. That is, if you have 5 instances and fail to connect to only one of the instances, MSDEWriter will not work. MSDEWriter only works with local instances. We can ignore any possible firewall issue as this is local connection.


In the first case, client shared memory protocol is disabled by the customre unexpectedly. One of the SQL instances installed on the customer machine is WMSDE. As we know, WMSDE can only listen on shared memory protocol. Clients can only connect to a WMSDE instance using shared memory, which is disabled in the customer's box. Enabling the shared memory protocol using SQL Server Client Network Utility fixes this problem.


The second case was due to an outdated alias. The customer had an alias defined previously but forgot to remove it when configuration changes. This alias forces connections to one of the instances to use TCP protocol. However, at some point, the customer disabled TCP protocol for the SQL server instance. This is also an example which tells us that users should use alias with caution, although alias can provide convenience and could be a useful workaround when user faces some specific problems.  


The third case is a surprise to us. We eventually found out that our sqloledb.dll is not loaded. A third party OLEDB provider took over the role of Microsoft SQLOLEDB provider. Like SQLOLEDB provider, the third party provider also calls DBNETLIB APIs. However, this provider does not behave the same way as Microsoft SQLOLEDB and passes different connection string to DBNETLIB. This breaks our product integrity and causes the problem. The problem is fixed by replacing the value of the following keys:


C:Program FilesCommon FilesSystemOle DBsqloledb.dll.


So, if you recently installed any third party database product, you may also want to check this registry when you have similar connectivity issues. We don’t expect any third party product changes our registry value.


Xinwei Hong, SQL Server Protocols
Disclaimer: This posting is provided "AS IS" with no warranties, and confers no rights

Comments (74)
  1. Rafal W. says:

    I found you explenation very interesting although have some further question regarding this particular error message, I ran myself into issue where .net application on IIS 6 is talking to SQL2k by mean of connection string in web.config file user can authenticate, navigate read/write run reports from within application, but one feature does not work, when user request report export which should create report in word doc format in temp folder on iis connection is denied, user get exactly same error "sql does not exist or access denied" it’s not code issue because this work on many sites besides one, it’s not iis secirity issue, do you have any sugestion what to look for?


  2. My blog was talking about local connectivity issue for MDAC/SQL Server.

    The error, "sql does not exist or access denied", is very generic and our whole blog is trying to solve this or related problems.

    You can learn more by reading our blogs, especially this one:


    Generally, if your code works well on machines but one specific machine, it’s protocol/network configuration issue. You may want to check the follows:

    1) is the protocol you use enabled on the sql server?

    2) enable/disable firewall to see the difference if this is a remote connectivity issue.

    3) If sql server 2005 is also installed, you will want to check whether sql browser is running or not, especially for named sql instance.

    We’d like to look it in further if you can provide more info I have mentioned, as well as your connection string.



  3. Mike Marshall says:

    I’m having a similar problem, except it’s sporadic. I’m running a DTS package that does mass inserts from several tables on one server, and sends the data to a different server. Both are running SQL Server 2000. About 5% of the time, it will copy some (most?) of the data, and then get the error.

    Both servers are running in the same domain.

    I get this error:

    ERROR REPORTED: Datamart Upload failed. Step "DTSStep_DTSDataPumpTask_2" Failed

    Error: -2147213206

    Source: Microsoft Data Transformation Services (DTS) Data Pump

    Description: The number of failing rows exceeds the maximum specified. (Microsoft Data Transformation Services (DTS) Data Pump (80020101): Error Code: 0

    Error Source= Microsoft OLE DB Provider for SQL Server

    Error Description: [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.

    Error on Line 6

    ) (Microsoft OLE DB Provider for SQL Server (80004005): [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.)

    In this example, I copied over many, many records (over 10,000), and then it finally indicated the server doesn’t exist. Hmmm. It didn’t have any problems a millisecond ago.

    I have no idea how to solve this when it’s sporadic.

  4. i am having exaltly the same problem for over two months now. does anybody have an answer that works

  5. Matt Neerincx [MSFT] says:

    If you are running into a mid-stream connectivity failure, this is very different than basic connectivity failure.  Think of it this way, when any application opens a socket and starts reading and writing on it, it should not disconnect in the middle of the conversation, this should be very rare in your network environment.

    So if you do see these mid-stream failures "intermittently", this typically points to network infrastructure issues.

    Here is how I typically attack these.  

    1. Start with SQL Profiler traces on the server side and make sure you capture all errors in the profiler trace.  Certain SQL errors can be fatal to the connection, if you see any errors around the time of the failure, you should track these down and figure out how to avoid them.

    2. If SQL Profiler is clean, next step is enable 3689 and 4029 trace flags, these will push more verbose errors to the errorlog when read+write errors occur in the network layer on the server side.

     dbcc traceon(4029,-1)

     dbcc traceon(3689,-1)

    So keep track of when the failures occur and then go look at SQL’s errorlog for logging around the same timeframe from these trace flags.  The trace will dump out the socket error code this can sometimes give you a clue as to the root cause.

    3. Another way to further troubleshoot these is gathering netmon traces on both client and server and then comparing the traces, but this requires some networking expertise.

    In general when you start seeing mid-stream failures you need to get your networking people involved and diagnose the network path from client all the way to server.  Do things like replace the NICs on the SQL box, make sure the NICs are configured properly, etc…  So you need network expertise to drill down into these in other words.


  6. i am trying to connect to the database server

    and getting error SQL State 08001

    SLQ Server not found or access denied

  7. Milani says:

    Congratulations for your documentation. Help too much. Thank you!

  8. Alvin says:

    The sporadic error reported by Mike (when using DTS package) seems to be universal. I too am getting it quite frequently!

    I believe the root cause is the error "The number of failing rows exceeds the maximum specified". Due to this error, the connection is being lost. Now why the above error? Don’t ask me becoz i don’t know!!

  9. Matt Neerincx [MSFT] says:

    If you are using DTS and getting the "The number of failing rows exceeds the maximum specified" error please repost to the microsoft.public.sqlserver.dts newsgroup, this error is a DTS specific error message.  Most likely some fatal import or export error is occuring and this is causing the connection to be dropped, which in turn triggers the other SQL Server driver errors.

    Also look at this KB article that talks about error handling in DTS ->

    Error Handling in DTS:


  10. Phillip says:

    "re: VSS: SQL Server does not exist or access denied"

    You guys don’t make it simple for the novice!! Could you make a step by step explanation.

  11. Sorry, but this blog does not intend to solve all VSS issues. It’s just my experience which may be helpful for you when you troubleshoot your vss connectivity issues. If you want to see introduction for VSS, please check here:



  12. Babz-KTYM says:

    i am getting the error

    [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or acess denied

    when i am running my application after i installed MS sql server 2000 on the administrator machine with admin login..

    Please help..

  13. Matt Neerincx [MSFT] says:

    ConnectionOpen(Connect) means that the client cannot open a socket to the SQL Server.  If this is a default instance of SQL Server running on port 1433, then most likely the root cause is port 1433 is blocked by your firewall.  The easiest way to unblock SQL Server from firewall is to go to the Windows Firewall utility in Control Panel and go to the Exceptions tab and click the "Add Program…" button and add sqlservr.exe.

    If you are connecting to a non-default instance, then it could be that you also need to add the SQL Browser service to the Windows Firewall exception list as well (sqlbrowser.exe).

    To verify if it is firewall issue, determine the port that SQL is listening on and from the remote machine try to telnet to this port:

      telnet mymachine 1433

    If this fails, then it is firewall issue.

  14. I don’t know if this may, or may not help anyone, but i’ve had loads of problems with one MSDE machine, and not on others.

    I did the usual registry edits to allow mixed mode authentication, as well as adding the sa password, applied SP4… etc.

    I found the problem was that the SQL Server (MSDE) was not responding on any network protocols that I wanted to use. Don’t look in client network utility, that’s only any use for enterprise manager! Go to the properties of the MSDE box using Enterprise Manager, and go to the network configuration. I found that named pipes and TCP/IP were not added by default. I added them, and hey-presto! All my problems solved!

    Now all I have to do is to find a reliable way to use replication services with MSDE!



  15. Guys,

    Login remotely on your server and Change sql registration to (local) instead of server name or IP. Now you can do anything DTS

    cheers !!

  16. Naim Bazzi says:

    I faced this kind of connection string problem. but when i disabled the windows xp firewall it connected. but i would like to know what port to enable if i’m using ISA

  17. Great advice! I’ve been facing this issue for a month and couldn’t backup the primary domain controller. After I’ve read your article, I found there is hidden MSDE installed. Enabling shared memory protocol for this instance made VSS to work. Thanks.

  18. sppatel says:

    I have the same problem.I have server with server 2000 OS and SQL Server 2000 and want to access that with remote computer with VB Application. But i have to login server with Id and password. Then I can connect application with SQL otherwise get the same error,Plz Help me if anyone have the solution.

  19. Matt Neerincx (MSFT) says:

    There are many reasons for "SQL Server does not exist or access denied".  First identify which SQL driver you are using, then review the following blogs:







  20. Daniel Rose says:

    thank you so much for publishing this information – the old system administrator had left an old alias – once i’d rectified the situation VSS and NTbackup worked again!


  21. Ketan Patel says:

    We are facing this connection issue with one machine on our network and are unable to resolve it.

    The client machine is a terminal server which has sql client installed. The sql box has a SBS 2003 o/s with sql 2000 with sp3a. It has two instances sqlserver and cdata.

    We have other machines connected to sql box and having no issues in connecting to either of the instances. But the terminal server has an intermittent problem. We are unable to register the instances thru EM and we also have our asp.net applications which are failing to access sql instances.

    Sometimes when the sql box machine is restarted or when the machine is started in the morning the connection from the termial server gets through, but most of the times it denies connection giving us the following error in EM

    SERVERSQLSERVER – SQL server does not exist or access denied ConnectionOpen(Connect())

    SERVERSQLSERVER has named pipes and tcpip protocols enabled (named pipes being on the top)

    Can you please help to sort identity the problem here

  22. Vivek says:


    I’m facing this problem when I configure ODBC in Windows Vista for SQL Server from Windows Sever 2003, where the SQL Server 2000 is installed.

    Please resolve this problem.





  23. Madrox says:

    i have this error in the asp page.

    Microsoft OLE DB Provider for SQL Server (0x80004005)

    [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.

    /smart/includes/Security.inc, line 53


    i have both SQL Server 2000 and 2005 Developer Edition installed on my machine.and i am using connection string

    DBConn.Open Application("ConnStr")


    Application("ConnStr") = "PROVIDER=SQLOLEDB;DATA SOURCE=;UID=username;PWD=username;DATABASE=BatchPrice"

    Server is SQL 2000 server(remote server).

    Earlier this was working fine but from the time SQL Server2005 has been installed it has started giving this error.

  24. Sohail Ahmed says:

    Please any body help..

    I have installed SQL SERVER developer edition on my local PC.Then i try to connect it through VB.. But I get this error.. Below is my connection string..

    STRDSN = "Provider=SQLOLEDB.1;Persist Security Info=True;User ID=sa ;Pwd=abc;Initial Catalog=CRS;Data Source=JPC-D-095-D;Network Library=DBMSSOCN".

    Thanks in advance

  25. By default, TCP protocol is not enabled when you install SQL Server Developer edition. Can you make sure TCP is turned on since your connection string is trying to use TCP.

    Thanks. Xinwei

  26. Madrox,

    Installing SQL Server 2005 should not have affected your old connection to SQL 2000. Can you follow this link to troubleshot it,


    and if you still see problem, please post an question in our forum.


    More people could help there.

    Thanks. Xinwei

  27. Jhanvi says:

    Hi All,

     I have installed SQL Server 2005.But I m unable to start it.I get (Microsoft SQL Server , Error: 10061).

    I am new to SQL Server..please tell the datail solution..

    Expecting immediate Help

  28. Jhanvi says:


     Can you please tell me..How should i check TCP is on? I am novice in Networking.

  29. Jhanvi.

    Please check this link to enable TCP.


    error 10061 means the server is not listening on specific TCP port.



  30. Jhanvi says:

    Dear Xinwei,

     Thank you very very much.. My problem is solved after i enable TCP/IP.

    God Bless you.

    Wonderful Blog!!

  31. Sohail Ahmed says:


     Thanks so much.. Even my problem is solved..

    I appreciate your work.


    Sohail Ahmed

  32. Jhanvi says:

    Hi Xinwei,

      I m trying to import data from Access to SQL Server 2005 , but i get below error.Please solve this

    – Pre-execute (Error)


    • Error 0xc0202009: Data Flow Task: An OLE DB error has occurred. Error code: 0x80040E21.

    An OLE DB record is available.  Source: "Microsoft SQL Native Client"  Hresult: 0x80040E21  Description: "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.".

    (SQL Server Import and Export Wizard)

    • Error 0xc0202025: Data Flow Task: Cannot create an OLE DB accessor. Verify that the column metadata is valid.

    (SQL Server Import and Export Wizard)

    Error 0xc004701a: Data Flow Task: component "Destination – tbl_TIM_Master " (337) failed the pre-execute phase and returned error code 0xC0202025.

    (SQL Server Import and Export Wizard)

  33. Jhanvi,

    The connection attempt succeed now, the remaining question is out of the scope of this blog. Can you post question under one of the forums under:




  34. Dem says:




  35. Devendra Shinde says:

    Hi All

    I had same problem while registering Server in SQL Server Enterprise Manager in my client machine and also adding new ODBC DSN for my SQL Server 2000 but it got resolved by adding "Named pipes" in Client Network Utility and adding port 1433 in the Firewall exceptions.


    Devendra Shinde

  36. Sanitha says:

    select Loacl and remote connection in surface area configuration manager

    Enable tcp/ip

  37. Davidf says:

    I’ve reviewed all the suggestions in thisthread, yet cannot get NTBACKUP to function.  It fails with Event Source: VSS ID: 6013 Computer: SERVER

    This is the error:

    Sqllib error: OLEDB Error encountered calling IDBInitialize::Initialize. hr = 0x80004005. SQLSTATE: 08001, Native Error: 17

    Error state: 1, Severity: 16

    Source: Microsoft OLE DB Provider for SQL Server

    Error message: [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.

    and this is the Data:

    0000: 2d 20 43 6f 64 65 3a 20   – Code:

    0008: 53 51 4c 43 4f 4e 4e 43   SQLCONNC

    0010: 30 30 30 30 30 34 39 31   00000491

    0018: 2d 20 43 61 6c 6c 3a 20   – Call:

    0020: 53 51 4c 43 4f 4e 4e 43   SQLCONNC

    0028: 30 30 30 30 30 33 39 37   00000397

    0030: 2d 20 50 49 44 3a 20 20   – PID:  

    0038: 30 30 30 30 35 33 37 32   00005372

    0040: 2d 20 54 49 44 3a 20 20   – TID:  

    0048: 30 30 30 30 35 34 38 34   00005484

    0050: 2d 20 43 4d 44 3a 20 20   – CMD:  

    0058: 43 3a 5c 57 49 4e 44 4f   C:WINDO

    0060: 57 53 5c 53 79 73 74 65   WSSyste

    0068: 6d 33 32 5c 76 73 73 76   m32vssv

    0070: 63 2e 65 78 65 20 20 20   c.exe  

    0078: 2d 20 55 73 65 72 3a 20   – User:

    0080: 4e 54 20 41 55 54 48 4f   NT AUTHO

    0088: 52 49 54 59 5c 53 59 53   RITYSYS

    0090: 54 45 4d 20 20 20 20 20   TEM    

    0098: 2d 20 53 69 64 3a 20 20   – Sid:  

    00a0: 53 2d 31 2d 35 2d 31 38   S-1-5-18

    Any suggestions?

  38. dunkmylife says:

    Great advice! I’ve been facing this issue for a month and couldn’t backup the primary domain controller. After I’ve read your article, I found there is hidden MSDE installed. Enabling shared memory protocol for this instance made VSS to work. Thanks.

  39. nbalive says:

    Thanks so much.. Even my problem is solved..

  40. Rob CJ sirpaladin266@gmail.com says:

    I have a program written by VB 6.0 and use MS SQL 2000 databasse.I connected the program with SQL by the code:

    Dim Cn As New ADODB.Connection

    Cn.Open "Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;User ID=sa;Initial Catalog=Database_name;Data Source=Server_name".

    In the first run,everything is okay.But then,there’s an error message like:

    "Runtime error: -2147467259(80004005):

    [DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied."

    I try to connect again,check my code,reset SQL server,check access(both SQL authentication and Windows Authentication),etc.But ….

    I do not know what the problem here?Who can help me?


  41. NBA says:

    Great advice! I’ve been facing this issue for a month and couldn’t backup the primary domain controller. After I’ve read your article, I found there is hidden MSDE installed. Enabling shared memory protocol for this instance made VSS to work


  42. I do not know what the problem here?Who can help me?


  43. kemal says:

    very good article.. thank u sharing..

  44. Stefano F. says:

    Same "Rob CJ" problem.

    After first VB6 app run I get the error.

    only in vb6 ide.

    Compiled exe alwais works.

    PLS HLP!

  45. epilasyon says:

    very good.Thanks for information

  46. thats says:

    graweb <a href="http://www.grawebtasarim.com/">Graweb, Grafik ve Web Tasarım</a> Graweb, dijital ve basılı medyada tasarım çözümleri.

  47. mirfey says:

    hi thanxs

  48. Saneem says:


    All the comments and answers helped me a lot ,

    Thanks a lot

    Saneem Hassan

  49. Greg says:

    I had this problem.  I fixed it by using a more recent SQL driver.

  50. Wallace says:

    The mightsoft of Chinese.

  51. Raju says:


    I do get these errors intermittently. I have sql server named instances in a single cluster hosted on active/active nodes. I have ssis packages which retrieves data from one sqlserver to another sql server. Suddenly one night the ETL would start failing stating [dbnetlib].Sql Server Does not exists or access denied. And when I check the error log of the databases I can see a login failure with state 8 which is a password mismtach. Though crendentials or password never changed i keep getting these errors. Simple workaround is rerun the ETL's without changing anything and will run perfectly without any issues.

    Can you shed some light on this. I already logged this in MSDN forums but of no luck.

  52. alijani says:

    Hi,in a office network, i have a virtual machine  win 2003, and install sql server 2005 on it, but i can not access to this sql from other client (ip or name not differ), and i receive message as "sql server dose not exist or access denied"   please help me, thanks.

  53. hamilton says:

    I fixed it by using a more recent SQL driver too. For anyone who needs help…

    on http://www.avideolar.com check it out.

  54. root@barisay.com.tr says:

    thank you so much

  55. yabaki_entelbaki@hotmail.com says:

    merhaba sizce yeterlimidir ? http://www.sincantasarim.com sincan web tasarım sitesi hata yahut web sitesi için tavsiyelerinizi bekliyorum teşekkürler

  56. web tasarımı says:

    <a href="http://www.ureticy.com"&gt; thanks very good , wonderfull </a>

  57. alicin_gfb_@hotmail.com says:

    Thanks for the solution


  58. Gorsel says:

    By default, TCP protocol is not enabled when you install SQL Server Developer edition. Can you make sure TCP is turned on since your connection string is trying to use TCP.

    Thanks. Xinwei

    <a href="http://www.gorsel.org">Gorsel</a&gt; buyrun davet edelim.

  59. Gorselorg says:


    Buyrun buradanda takip edebilirsiniz.

  60. Savaş Dersim çelik says:

    http://www.webinyo.com/ istediğiniz bilgilere sahip olabilirsiniz.

  61. contedddd says:

    i am getting the error


  62. weblozi webmaster blogu says:

    I fixed it by using a more recent SQL driver too. For anyone who needs help…

    Webmaste tool, seo optimization, wordpress tema, inceleme


  63. Kaan says:

    http://propaylas.com/ genel blog paylaşımı yapan bir sitedir.

  64. Barış Altay says:

    http://www.arrowizle.com Arrow Dizisi Resmi Sitesi , Arrow İzle Buyrun

  65. SEO Ankara says:

    Merhaba arkadaşlar sitelerinizi yoruma eklediğinizi görüyorum sitenize biliçli bir şekilde seo çalışması istiyorsanız bize ulaşın http://www.ankaraseohizmeti.com

  66. Düğün Fotoğrafçısı istanbul says:

    very good article..


  67. yüz estetiği ankara says:

    I found good information from your site. Thank you so much. http://www.gestaltestetik.com

  68. Net trend says:

    Güncel bilgilere ve haberlere buradan ulaşabilirsiniz. http://nettrend.net/

  69. blogokur says:

    ı found many usefull information to use on http://www.blogokur.com/

Comments are closed.

Skip to main content