This is my working list for decom for older Lync and Skype deployments on prem for organizations that are moving to Microsoft Teams. **more info to be added around trunk removal.
Look for disabled accounts that are still registered to Lync 2013
Get-CSuser | Disable-CSuser
Get-CsConferenceDirectory | Remove-CsConferenceDirectory
Check for Analog devices
Get-CsAnalogDevice | Select-Object DisplayName, LineUri
Check for Meeting Rooms
Get-CsMeetingRoom
Check for old conference directories
Get-CsConferenceDirectory
UM Contact Objects find and remove.
Get-CsExUmContact -Filter {RegistrarPool -eq “<LyncServerPoolFqdn>”} | Remove-CsExUmContact
UM Response Group Objects.
Get-CsRgsWorkflow -Identity:Service:ApplicationServer:<LyncServerPoolFqdn> | Remove-CsRgsWorkflow
Reassign the PSTN Gateway. This is used to move PSTN gateways from old mediation server to new Skype mediation server. To remove use second command
Set-CsPstnGateway -Identity “PstnGateway:<Xds Identity of PSTN Gateway>” -MediationServer:”MediationServer: <Name of Mediation Server Identity>”
Get-CsTrunkConfiguration -Filter site:* | Remove-CsTrunkConfiguration
Validate front end pool is vacant.
Get-CsVoiceRoute | select Identity,PstnGatewayList
Topology Clean up
- Log on to the computer where Topology Builder is installed.
- Start Topology Builder: Click Start, click All Programs, click Microsoft Lync Server 2010, and then click Lync Server Topology Builder.
- In the Actions pane, click Remove Deployment.
- Read the information regarding Remove Deployment
- Click Next, and then click Finish.
Once the above is done you can open topology builder and publish the empty topology by choosing the option Download Topology from existing deployment.
SQL DB uninstall
Uninstall-CsDatabase -DatabaseType User -SqlServerFqdn sqlbe.contoso.net[-SqlInstanceName <instance name>]
Central Store removal
Remove-csconfigureationstorelocation