Thursday, December 15, 2016

Migrating Skype for Business Server 2015 CMS from one server to another

I recently had to migrate and decommission a Skype for Business Server after upgrading it from Lync Server 2013 and noticed that the Windows 2012 Server would continuously blue screen every few hours.  One of the tasks involved with the migration was to move the CMS (Central Management Server) from the to-be-decommissioned server to the newly one and this post serves to demonstrate the process.

Note that the CMS is currently on the lyncstd01.domain.bm server:

image

image

Note the newly deployed lyncstd02.domain.bm that we will be moving the CMS to:

image

Begin by backing up the Skype for Business configuration with the following cmdlets:

Export-CsConfiguration -FileName C:\SfB-config.zip

Export-CsLisConfiguration -FileName C:\SfB-lis.zip

image

image

With the backup completed, run the Prepare first Standard Edition server wizard in the Skype for Business Server 2015 – Deployment Wizard on the CMS destination server (lyncstd02):

image

image

image

image

Once the wizard has completed, launch the Skype for Business Server Management Shell on the CMS destination server and execute the following:

Install-CsDatabase -CentralManagementDatabase -SQLServerFQDN <FQDN of your Standard Edition Server> -SQLInstanceName <name of instance - RTC by default>

The cmdlet executed in the screenshot below is:

Install-CsDatabase -CentralManagementDatabase -SQLServerFQDN lyncstd02.domain.bm -SQLInstanceName RTC

image

image

Once the cmdlet completes enable the topology with:

Enable-CsTopology

image

image

With the topology published, execute Move-CsManagementServer to move the Central Management Server to the destination server:

image

image

image

Note the following warning message once the cmdlet completes:

Warning: The move completed successfully but the following additional steps are required:

Run local setup on the following computers to remove Central Management services that are no longer defined in the topology:

- lyncstd01.domain.bm

Reviewing the html log will show the same warning message in the management shell:

image

Continue to run the Install or Update Skype for Business Server System on the new server hosting CMS:

image

Run the Setup or Remove Skype for Business Server Components wizard again:

image

image

image

image

Once the wizard completes, continue by running the Install or Update Skype for Business Server System on the old server that use host the CMS:

image

Run the Setup or Remove Skype for Business Server Components wizard:

image

image

image

There may be times when the wizard will complete but also throw the error:

Command execution failed: ###50021:XdsPublishItems:This central management store has moved to another location. No more changes can be made to this store.

image

Confirm that replication is successful by executing the cmdlet Get-CsManagementStoreReplicationStatus:

image

There may be times when replication does not appear to be working and the UpToDate variable never changes to True.  If this happens, check the Skype for Business Server File Transfer Agent service on both servers because sometimes it is stopped:

image

Restarting the services and rerunning the Get-CsManagementStoreReplicationStatus should show that all of the UpToDate variables is shown as True:

image

The CMS should now be moved and the Skype for Business Topology Builder should reflect the changes:

image

If the old server hosting the CMS is going to remain in the environment and you would like to remove the Central Management store files then execute the following:

Uninstall-CsDatabase -CentralManagementDatabase -SqlServerFqdn <FQDN of SQL Server> -SqlInstanceName <Name of source server>

**Note that it is important not to proceed with the removal of the previous database files until replication is complete and is stable. If you remove the files prior to completing replication, you will disrupt the replication process and leave the newly moved Central Management Server in an unknown state.

The following is an example of executing the cmdlet:

Uninstall-CsDatabase -CentralManagementDatabase -SqlServerFqdn lyncstd01.domain.bm -SqlInstanceName RTC

image

Once the cmdlet completes run the Setup or Remove Skype for Business Server Components wizard:

image

image

With the above completed, the Skype for Business Server Master Replicator Agent will no longer be present:

imageimage

1 comment:

Unknown said...

Hi Terence,

We have got 3 Skype for Business Front Ent Server. Backend is hosted on the SQL 2008 cluster database

Our SQL team wants migrate backend SQL from SQL server 2008 R2 Ent SP2 to SQL 2014 sp2 Ent.

Do i have to follow the steps you mentioned to migrate backend sql or its a different method to be followed.

Any help would be appreicated