locked
Help! Moving Skype For Business 2015 databases to a different SQL server RRS feed

  • Question

  • Hi!  I have a Skype For Business 2015 environment that I need to move the databases on.  I have done a ton of research on this and found some great articles - but I am stuck fairly early in the process.  

    Here's my environment in a nutshell:

    Skype For Business Server 2015

    1 FE Enterprise Server

    1 Edge Server

    Backend Database Server (Always on AG)

    My Backend Database Server contains the following databases:

    • LcsLog
    Cpsdyn
    Rtcxds
    Rtcshared
    Rtcab
    Rgsconfig
    Rgsdyn
    Lis
    Xds

    I need to move these to a new Backend  Database Server (Always on AG)

    I know from a high level what I need to do.   I need to bring up a temporary standard edition server, move my Central Management Store to the temporary Standard Server, backup & restore my databases on the new SQL Server, and then move the Central Management Store back.

    So here's where I am stuck...

    I have built a server to act as my temporary standard server, but I'm not sure how to get this server integrated in to my current SFB environment.  I could not figure out if I was supposed to add the server as a standard server to my current topology and publish it, or if I was supposed to run "prepare single standard edition server" on the new standard server.

    I ended up running "prepare single standard edition server" - and I have not done anything else at this time.  However, the more I read that may not be the correct step?    It appears maybe I should have NOT run the "prepare single standard edition server" and instead added that server via the topology and published it?

    Can anyone advise the steps I need to follow to get the Standard Edition Server integrated in to my environment so I can move the Central Management Store?  

    If I did run the "prepare a single standard edition server" incorrectly - can I simply roll that new server back to a snapshot I took before I ran the command?  does "prepare a single standard edition server" do anything else besides install MSDE?


    I appreciate the help/tips!  

    Sunday, September 16, 2018 3:07 AM

All replies

  • Hi Dave,

    Can anyone advise the steps I need to follow to get the Standard Edition Server integrated in to my environment so I can move the Central Management Store?  

    You should add a new server as a standard server to your topology then publish it.After that, open the new server,then install the SE server step by step like the following link. When you deploy the SE server, you do not need to deploy sepearte the backend database, just run “prepare single standard edition server”, it will create a database(install SQL server express actually) that will allocate with FE server.

    https://insidemstech.com/2015/06/30/step-by-step-skype-for-business-server-standard-edition-deployment/

    If I did run the "prepare a single standard edition server" incorrectly - can I simply roll that new server back to a snapshot I took before I ran the command? 

    Based on my research, you can do that.

    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link.


    Best Regards,
    Leon Lu


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnsf@microsoft.com.


    Click here to learn more. Visit the dedicated forum to share, explore and talk to experts about Microsoft Teams.

    Monday, September 17, 2018 2:51 AM
  • Hi ,

     

    Do you have any updates? If the reply help to you, please mark the reply as answer.


    Best Regards,
    Leon Lu


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnsf@microsoft.com.


    Click here to learn more. Visit the dedicated forum to share, explore and talk to experts about Microsoft Teams.

    Monday, September 17, 2018 10:26 AM
  • Hi Leon, I appreciate the response!

    I looked at the link you listed above, but it really seems to discuss this process from the standpoint of not having an environment at all stood up.  In my case I already have a fully functioning environment running.

    Am I understanding correctly that I need to add the standard server to my topology first, publish it, and then run the "prepare a single standard edition server" AFTER adding it to my topology?

    Thanks!

    Monday, September 17, 2018 6:33 PM
  • Hi Dave,

    Am I understanding correctly that I need to add the standard server to my topology first, publish it, and then run the "prepare a single standard edition server" AFTER adding it to my topology?

    I know you have a fully functioning environment running.

    You could refer to following steps to install your SE server.

    Create a new windows server in your environment, then join the domain, add the standard server to topology first, publish it in any of FE servers, open the new windows server, install the prerequisite, open the SFB deployment wizard, click “Install Administrative tools” ,click “prepare a single standard edition server” , click “install or update Skype for business server system”(install local configuration store, setup or remove Skype for business server components,install or assign certificates, start services )


    Best Regards,
    Leon Lu


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnsf@microsoft.com.


    Click here to learn more. Visit the dedicated forum to share, explore and talk to experts about Microsoft Teams.


    Tuesday, September 18, 2018 10:13 AM
  • Hi,

     

    Are there any updates for this issue, if the reply is helpful, please try to mark it as an answer,  it will help others who have similar issue.


    Best Regards,
    Leon Lu


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnsf@microsoft.com.


    Click here to learn more. Visit the dedicated forum to share, explore and talk to experts about Microsoft Teams.

    Thursday, September 20, 2018 9:58 AM
  • Hi Leon, sorry for the delayed follow up!  I completed the migration late last week, but I have an issue that has popped up as a result.

    I was moving the Skype databases over to my SQL Server 2016 Always on availability group.  There is a specific step in the process after you have created the databases on your primary node, restored the backed up databases over these and added the databases to the secondary node.  This step involves failing the AG cluster over to the secondary node, updating the topology to point at the secondary node, and then running the following command (presumably to add the users, ect to the secondary node?)

    Install-csdatabase –update –configureddatabases –sqlserverfqdn databasename –verbose

    After running the above command on the secondary node - I did get a few of the following types of errors on the databases.  (I only pasted one of the errors but it's the same error on most/all of the databases)

    Setting database version: Schema Version 2, Sproc Version 2, Update Version 2.
    Failed to setup database rgsdyn due to an unexpected error. Detail: Microsoft.Sq
    lServer.Management.Smo.FailedOperationException: Execute with results failed for
     Database 'rgsdyn'.  ---> Microsoft.SqlServer.Management.Common.ExecutionFailure
    Exception: An exception occurred while executing a Transact-SQL statement or bat
    ch. ---> System.Data.SqlClient.SqlException: Cannot use SAVE TRANSACTION within
    a distributed transaction.
       at Microsoft.SqlServer.Management.Common.ConnectionManager.ExecuteTSql(Execut
    eTSqlAction action, Object execObject, DataSet fillDataSet, Boolean catchExcepti
    on)
       at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteWithResults(
    String sqlCommand)
       --- End of inner exception stack trace ---

    The services all start fine, and I was able to move my CS store over to the new 2016 Always on Cluster without any problems.

    However, I am having trouble with conferencing chat not working (chat which involves 3 or more users)  - and I am getting the following errors over and over in my event log on my FE server:

    Log Name:      Lync Server
    Source:        LS User Store Sync Agent
    Date:          9/24/2018 10:41:30 PM
    Event ID:      57005
    Task Category: (1061)
    Level:         Error
    Keywords:      Classic
    User:          N/A
    Computer:      server.domain.com
    Description:
    Error encountered pushing data to RtcXds Blob Store

    #CTX#{ctx:{traceId:3713627061, activityId:"c6c736b9-b09e-453e-a7ce-ab28a4a2ee32"}}#CTX#
    Push cycle identifier: [server.domain.com.2fd688f5-0f3a-407f-bab5-3fa5c3757443]
    ItemCount: [20]
    Error Message: [PushController: XdsPublishItems failed: System.Data.SqlClient.SqlException (0x80131904): Snapshot isolation level is not supported for distributed transaction. Use another isolation level or do not use distributed transaction.
       at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
       at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
       at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
       at System.Data.SqlClient.SqlDataReader.get_MetaData()
       at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
       at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader()
       at Microsoft.Rtc.Common.Data.DBCore.Execute(SprocContext sprocContext, SqlConnection sqlConnection, SqlTransaction sqlTransaction)
    ClientConnectionId:3dc556b6-9ede-477a-9ffc-37fb5ea3891c
    Error Number:3996,State:1,Class:16]
    Cause: Possible issues with back-end database.
    Resolution:
    Ensure the back-end is functioning correctly.
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="LS User Store Sync Agent" />
        <EventID Qualifiers="50213">57005</EventID>
        <Level>2</Level>
        <Task>1061</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2018-09-25T03:41:30.000000000Z" />
        <EventRecordID>3768060</EventRecordID>
        <Channel>Lync Server</Channel>
        <Computer>server.domain.com</Computer>
        <Security />
      </System>
      <EventData>
        <Data>#CTX#{ctx:{traceId:3713627061, activityId:"c6c736b9-b09e-453e-a7ce-ab28a4a2ee32"}}#CTX#</Data>
        <Data>server.domain.com.2fd688f5-0f3a-407f-bab5-3fa5c3757443</Data>
        <Data>20</Data>
        <Data>PushController: XdsPublishItems failed: System.Data.SqlClient.SqlException (0x80131904): Snapshot isolation level is not supported for distributed transaction. Use another isolation level or do not use distributed transaction.
       at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
       at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean&amp; dataReady)
       at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
       at System.Data.SqlClient.SqlDataReader.get_MetaData()
       at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
       at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task&amp; task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task&amp; task, Boolean&amp; usedCache, Boolean asyncWrite, Boolean inRetry)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader()
       at Microsoft.Rtc.Common.Data.DBCore.Execute(SprocContext sprocContext, SqlConnection sqlConnection, SqlTransaction sqlTransaction)
    ClientConnectionId:3dc556b6-9ede-477a-9ffc-37fb5ea3891c
    Error Number:3996,State:1,Class:16</Data>
      </EventData>
    </Event>

    and this one as well

    Log Name:      Lync Server
    Source:        LS User Store Sync Agent
    Date:          9/24/2018 10:41:30 PM
    Event ID:      57006
    Task Category: (1061)
    Level:         Warning
    Keywords:      Classic
    User:          N/A
    Computer:      server.domain.com
    Description:
    RtcDb Sync Agent sproc failed

    #CTX#{ctx:{traceId:3713627061, activityId:"c6c736b9-b09e-453e-a7ce-ab28a4a2ee32"}}#CTX#
    Sproc: [XdsPublishItems]
    Exception: [System.Data.SqlClient.SqlException (0x80131904): Snapshot isolation level is not supported for distributed transaction. Use another isolation level or do not use distributed transaction.
       at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
       at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
       at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
       at System.Data.SqlClient.SqlDataReader.get_MetaData()
       at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
       at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader()
       at Microsoft.Rtc.Common.Data.DBCore.Execute(SprocContext sprocContext, SqlConnection sqlConnection, SqlTransaction sqlTransaction)
    ClientConnectionId:3dc556b6-9ede-477a-9ffc-37fb5ea3891c
    Error Number:3996,State:1,Class:16]
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="LS User Store Sync Agent" />
        <EventID Qualifiers="33829">57006</EventID>
        <Level>3</Level>
        <Task>1061</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2018-09-25T03:41:30.000000000Z" />
        <EventRecordID>3768059</EventRecordID>
        <Channel>Lync Server</Channel>
        <Computer>server.domain.com</Computer>
        <Security />
      </System>
      <EventData>
        <Data>#CTX#{ctx:{traceId:3713627061, activityId:"c6c736b9-b09e-453e-a7ce-ab28a4a2ee32"}}#CTX#</Data>
        <Data>XdsPublishItems</Data>
        <Data>System.Data.SqlClient.SqlException (0x80131904): Snapshot isolation level is not supported for distributed transaction. Use another isolation level or do not use distributed transaction.
       at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
       at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean&amp; dataReady)
       at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
       at System.Data.SqlClient.SqlDataReader.get_MetaData()
       at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)
       at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task&amp; task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task&amp; task, Boolean&amp; usedCache, Boolean asyncWrite, Boolean inRetry)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader()
       at Microsoft.Rtc.Common.Data.DBCore.Execute(SprocContext sprocContext, SqlConnection sqlConnection, SqlTransaction sqlTransaction)
    ClientConnectionId:3dc556b6-9ede-477a-9ffc-37fb5ea3891c
    Error Number:3996,State:1,Class:16</Data>
      </EventData>
    </Event>

    If I run the following 2 commands (in the order listed below) - the errors will clear up and everything will work fine (including the chat conference) for a few hours before the errors start up again and conference chat stops working

    ALTER DATABASE[rtcxds]SETALLOW_SNAPSHOT_ISOLATIONOFF

    and then

    ALTER DATABASE [rtcxds]SET ALLOW_SNAPSHOT_ISOLATION ON

    immediately after running the 2 commands above - I will get the following alert in the event log and everything will work for awhile:

    Log Name:      Lync Server
    Source:        LS User Store Sync Agent
    Date:          9/24/2018 10:43:58 PM
    Event ID:      57004
    Task Category: (1061)
    Level:         Information
    Keywords:      Classic
    User:          N/A
    Computer:      server.domain.com
    Description:
    The RtcDb Sync Agent successfully pushed data to RtcXds Blob Store.

    #CTX#{ctx:{traceId:3713627061, activityId:"c6c736b9-b09e-453e-a7ce-ab28a4a2ee32"}}#CTX#
    Push cycle identifier: [server.domain.com.2fd688f5-0f3a-407f-bab5-3fa5c3757443]
    ItemCount: [20]
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="LS User Store Sync Agent" />
        <EventID Qualifiers="17445">57004</EventID>
        <Level>4</Level>
        <Task>1061</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2018-09-25T03:43:58.000000000Z" />
        <EventRecordID>3768064</EventRecordID>
        <Channel>Lync Server</Channel>
        <Computer>server.domain.com</Computer>
        <Security />
      </System>
      <EventData>
        <Data>#CTX#{ctx:{traceId:3713627061, activityId:"c6c736b9-b09e-453e-a7ce-ab28a4a2ee32"}}#CTX#</Data>
        <Data>server.domain.com.2fd688f5-0f3a-407f-bab5-3fa5c3757443</Data>
        <Data>20</Data>
      </EventData>
    </Event>

    Thanks for your help!!



    Tuesday, September 25, 2018 4:13 AM
  • Hi,

    The reason for this error is that the new procedure has been added in Skype for Business upgrade but back-end database is not updated yet. You can check whether your Skype for Business databases are up to date with the Test-CsDatabase cmdlet:

    Test-CsDatabase -LocalService | Select SqlServerFqdn, SqlInstanceName, DatabaseName, InstalledVersion, ExpectedVers

    You could refer to this link to solve this issue.

    https://itgala.xyz/sfb-server-2015-event-57005-could-not-find-stored-procedure-xdsquerycriticaldocumentsignatures/

     

    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link.


    Best Regards,
    Leon Lu


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnsf@microsoft.com.


    Click here to learn more. Visit the dedicated forum to share, explore and talk to experts about Microsoft Teams.

    Friday, September 28, 2018 7:36 AM
  • Hi Leon! I appreciate the response.  I had seen the link you included but I don't think it's applicable.  The error I'm getting isn't about a missing stored procedure, it talks about snapshot isolation

    I attached a screenshot to show you that my databases are at the expected level.

    any other thoughts?

    Thanks!

    -Dave

    

    Saturday, September 29, 2018 3:14 AM
  • Hi Dave!

    Any update on solving this? We are in the same state now where we get issues with >2 participants on Chat/ScreenSharing etc.

    BR

    Martin

    Wednesday, May 29, 2019 1:50 PM
  • Hi Martin!

    Yes!  The problem (after having a ticket open with Microsoft for weeks) ended up being that we had DTC Support enabled on our SQL Server 2016 Availability Group.

    Ultimately, this is the command that I had to run to fix it:

    ALTER AVAILABILITY GROUP <THE_NAME_OF_YOUR_SQL_AG>SET (DTC_SUPPORT = None);

    if needed, I can provide you the Microsoft PSS case # in the event that you have a case open with Microsoft, but this was the end result for us that solved the problem.

    Good Luck!

    -Dave

    Thursday, May 30, 2019 3:16 AM