Cannot open database "xds" requested by the login. The login failed.Login failed for user

When something went wrong during any Lync Installation, e.g. Topology was published with Errors and you tried to install a Lync Server, e.g. SBS, STD Edt, ...

You might see the following Error:
Cannot open database "xds" requested by the login.
The login failed.Login failed for user DOMAIN\ADMINUSER

If this is happened,

you fully need to uninstall:

1.) All Lync Server Components, beside:
- Administrative Tools, Core Components, Resources Kit (if ist installed)

2.) The entire local SQL Instance, including Client Tools !
- Ensure, also the local Folder: C:\Program Files\Microsoft SQL Server\MSSQL10.RTCLOCAL is entirely deleted!

3.) Restart your Server now.

If you are now going to reinstall Lync Server,

4.) make sure the Registry Key is clean:
Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager

should the Lync Server Replica Replicator Agent should not have been proper uninstalled.
You Need to uninstall all Lync components including the exemptions listed above.
(RegKey: Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Service\REPLICA)
The Replica Replicator Service is part from Lync Core Components!

and delete the following Folder:
C:\Program Files\Microsoft Lync Server
C:\Program Files\Common Files\Microsoft Lync Server 2010

Here you go and the Server can be reinstalled...!


  1. Thanks for explanation, it is pretty much simple.

  2. Thanks, we had to do this today. Lync 2013 FE Enterprise install with SQL 2008 R2 latest SP back end. Hope Microsoft will look into these repeated failures -- lots of people finding the same issue it seems.

  3. I am getting same error on edge server, edge is domain joined. Any help on that?

    1. Hi Ahmad,
      you have several issues.
      1. Edge MUST NOT a domain joined computer.

      So you need fully uninstall EDGE with all Lync components!
      Than reinstall after you disjoined the computer.
      make sure you fully follow the recommendations for Edge server.

  4. Hi,
    I came across the same situation when installing Skype for Business 2015 and I believe I fixed it more easily - I think reinstall is not necessary.

    Have a look at the SQL management studio and the SQL's data directory.You will possibly not see the xds DB in the management stufio, but find a xds.mdf in the SQL's data directory. For some reason it got detached in my case, preventing the Skype4B installer to create a new one (but still presenting me the message above).

    The existing mdf file can be re-attached easily, or possibly also removed together with the ldf file to fix this issue.

    1. Hi Stefan,

      thank you for posting this. Would you mind dropping me a contact request through this blog, so I can contact you. I'm very interested in this case !!
      Just also would like report this to the PG for Skype for Business.

  5. Hi. I have experienced the exact same problem on a freshly installed Skype for Business 2015 edge server. I will try what Stefan recommends and get back to this post with my findings.

  6. I ran into this one today. We have (2) 2013 SE pools that are paired. I went to introduce a new SFB SE pool. Downloaded and updated the topology from the new SFB SE. Went to publish, everything seemed to publish without errors. Ran Steps 1-3 without issue but step 2 never gave me a green complete. when it was time to start services I had some issues. FE service would not start. I rebooted, eventually I got it going. Next I went to open up control panel and boom - Cannot open database "xds", I got the error and found your blog. Well, actually I have been to this site many of times - thank you!

    Anyways, We were in the process of downloading SQL Management studio when we checked a few other things. Replication was healthy (TRUE) on all servers. I was seeing a bunch of LS Storage Errors (32008) on the SFB server in the Lync Server log, basically unexpected exception and failed to read a webservices directory on my skypeshare. Double checked file share perms, they were good.

    The technical architect on my team recommended running Enable-CsComputer and that seemed to make everything happy. Event logs cleared up right away. We opened up the control panel, everything was happy. We even went back to deployment wizard just for kicks, sure enough step 2 was now marked as complete.

    It was odd.

    1. Hi Matt,
      i'm happy you solved it this way. In your case, when the second Step didn't show "green", it was related, that the replication is file based replication, where the S4B Share is involved and since access was blocked the xds database was nto correctly defined during the first step, even if that showed green. so it looked wired. once you enabled the computer object again, it starts working indirectly on the sync from the first step.

      What I liked on your comment is, now this process could be understood much better on who the setup applies.
      Thank you

  7. In my case, it was the security settings in MSSQL. The domain admin was setup with the public user role, I enabled the sysadmin role and everything went smoothly!


Post a Comment

Popular posts from this blog

How to hide users from GAL if they are AD Connect synchronized

Cannot join external Lync Meeting: Lync Edge Server Single IP Address (Lync Edge Server Single IP Web Conferenceing Problem)

MFA with Guest Access and different tenants settings