Skype for Business Server – Fabric Logs Consuming Disk Space (Script)

You may notice that your Skype for Business Front End server consumes a lot of disk space and the culprit will either be: C:\ProgramData\Windows Fabric\Log (SfB 2015) or C:\ProgramData\Microsoft\SF\Log (SfB 2019) This is caused by Windows Fabric log growth and can be rectified by either: Increase disk space Limit how long Fabric Logs are kept (default 3 days) This post shows how to do option 2 manually in SfB 2015: https://myhybridsetup.org/skype-for-business-2015-limit-fabric-tracing-logs-growth/ ...

30 April 2020 · 2 min · Chris Hayward

Skype for Business Server – Script – Check if migrated to Cloud Voicemail

There doesn’t appear to be any obvious way to check if you have been migrated from Exchange Online UM to Cloud Voicemail in O365, other than calling your Voicemail box and checking to see if the announcement is different. I have been through various settings in O365 Remote PowerShell for different customers and can’t find anything concrete (Sorry SfBo customers). SfB Server customers can use the Skype for Business Monitoring Reports to identify if users have been migrated. Calls diverted to Voicemail will show RTCC/7.0.0.0 LyncTeamsGateway/1.1.319.0 rather than RTCC/5.0.0.0 MSExchangeUM/15.20.2686.025. But that’s not very fun, so here is a script to do it for you: ...

6 February 2020 · 3 min · Chris Hayward

Teams/Skype Online – Unable to discover PowerShell endpoint URI

When connecting to Microsoft Teams or Skype Online ( https://docs.microsoft.com/en-us/office365/enterprise/powershell/manage-skype-for-business-online-with-office-365-powershell) you may experience the following error: Unable to discover PowerShell endpoint URI At C:\Program Files\Common Files\Skype for Business Online\Modules\SkypeOnlineConnector\SkypeOnlineConnectorStartup.psm1:114 char:9 + throw $resources.DiscoveringEndpointFail + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : OperationStopped: (Unable to disco...ll endpoint URI:String) [], RuntimeException + FullyQualifiedErrorId : Unable to discover PowerShell endpoint URI This occurs when your Office 365 Admin Account is not an onmicrosoft.com account. To resolve you need to specify the -OverrideAdminDomain switch on New-CsOnlineSession and specify your default O365 onmicrosoft domain. E.g: ...

30 May 2019 · 1 min · Chris Hayward

Skype for Business – Bulk Set Client Pin

Note this script is provided as an example only - By default a user can set their own Client Pin via the Dial-In Conferencing page (usually dialin.domain.com). You may have a requirement to bulk set a Client Pin if you’re rolling out a large number of VOIP phones. The script example below sets a 6 digit client PIN consisting of a two digit prefix followed by the last 4 digits of the users LineUri: ...

25 July 2018 · 1 min · Chris Hayward

Skype for Business – Automatically set RGS Holiday Sets with PowerShell and JSON

Every Lync/Skype admin has the same nightmare with Response Group Holiday sets, something that has to manually be programmed each year for Public Holidays in your country. What if you could script populating Holiday Sets automatically using PowerShell and an API? I live in England and most of my customers are UK based so I needed a service that would give me Public Holidays for the UK. Our government website lists all Public Holidays here: https://www.gov.uk/bank-holidays. They are also conveniently provided in JSON format here: https://www.gov.uk/bank-holidays.json ...

7 July 2017 · 2 min · Chris Hayward

Skype for Business – Import Common Area Phones from CSV

I recently had a customer that required 90 Common Area Phones creating in Skype for Business. This is quite a tedious task so the easiest way is to populate a CSV and use a PowerShell script to do the import. When creating a Common Area Phone in Lync/SfB it can take a few seconds before you’re able to assign Policies and Pin numbers to the objects. This slows the script down significantly if waiting 20 seconds between creating the object, then assigning Policies. So, I’ve actually made three ForEach loops, the first one creates the Common Area Phone objects, then it waits 20 seconds before assigning policies to every object, then it waits another 20 seconds before assigning the pins (I found that assigning Pins would fail if I didn’t wait longer). ...

11 January 2017 · 2 min · Chris Hayward

Skype for Business – Get QoS Configuration with PowerShell

When configuring QoS (Quality of Service) in Microsoft Lync / Skype for Business you need to modify the media port ranges for various Services and Configuration using PowerShell. Pat Richard has made a brilliant QoS calculator for Lync/Skype for Business here http://www.ehloworld.com/2821. The calculator will provide you with the PowerShell commands required to configure QoS port ranges and the GPO’s. The calculator also gives you the commands to verify the Configuration (which this post is based on). ...

26 January 2016 · 3 min · Chris Hayward

Skype for Business 2015 – Automated Backup Script

A few years ago I created a Lync 2013 backup script that would backup data from all servers in the Topology. Lync 2013 Automated Backup Script This script also works with Skype for Business 2015 but it specifically backed up Response Group and User data by identifying the pool version. The script below has been updated and tested on SfB 2015. <# Author: Chris Hayward, chrishayward.co.uk Purpose: Centralised script to backup Lync 2013 and SfB 2015 Version: 1.2 Changes: DATE - Change 06/11/2013 - Release 1.1 - Fixed code that deletes old backup directories (CH) 27/11/2015 - 1.2 Updated for Skype for Business (version -gt 7 rather than -eq 6) #> Import-Module Lync # Script Config $BackupPath = "D:\_Backup\" # Backup Path $BackupRetention = -14 # Number of days to keep old backups (Requires a "-", e.g. two weeks would be -14, 5 days would be -5) # *** Start of script *** # Delete old backup directories Get-ChildItem $BackupPath |? {$_.psiscontainer -and $_.lastwritetime -le (get-date).adddays($BackupRetention)} |% {remove-item $_.FullName -recurse -force} # Get date in day-month-year format and set backup path $DateStamp = Get-Date -Format dd-MM-yy $BackupPath = $BackupPath + "LyncBackup_" + $DateStamp +"\" New-Item $BackupPath -type directory -force # Backup the Lync Central Management Store $CMSBackupFile = $BackupPath + "Lync-CMS-Config.zip" Export-CsConfiguration -FileName $CMSBackupFile # Backup Location Information Service data $LISBackupFile = $BackupPath + "Lync-LIS-Config.zip" Export-CsLisConfiguration -FileName $LISBackupFile # Backup User Data (Lync 2013 & SfB 2015 servers only) $UserServer = Get-CsService -UserServer | Where-Object {$_.version -ge 6} ForEach ($Service in $UserServer) { $UserDataBackupFile = $BackupPath + "Lync-User-Config_" + $($Service.PoolFqdn) + ".zip" Export-CsUserData -PoolFQDN $($Service.PoolFqdn) -FileName $UserDataBackupFile } # Backup Response Group Configuration (Lync 2013 & SfB 2015 servers only) $ApplicationServer = Get-CsService -ApplicationServer | Where-Object {$_.version -ge 6} ForEach ($Service in $ApplicationServer) { $RGSBackupFile = $BackupPath + "Lync-RGS-Config_" + $($Service.PoolFqdn) + ".zip" Export-CsRgsConfiguration -Source ApplicationServer:$($Service.PoolFqdn) -FileName $RGSBackupFile } # Backup Voice Configuration $BackupPath = $BackupPath + "Lync-Voice-Config\" New-Item $BackupPath -type directory -force Get-CsDialPlan | Export-Clixml -path $BackupPath\DialPlan.xml Get-CsVoicePolicy | Export-Clixml -path $BackupPath\VoicePolicy.xml Get-CsVoiceRoute | Export-Clixml -path $BackupPath\VoiceRoute.xml Get-CsPstnUsage | Export-Clixml -path $BackupPath\PSTNUsage.xml Get-CsVoiceConfiguration | Export-Clixml -path $BackupPath\VoiceConfiguration.xml Get-CsTrunkConfiguration | Export-Clixml -path $BackupPath\TrunkConfiguration.xml To run the script as a scheduled task: ...

27 November 2015 · 2 min · Chris Hayward

Lync 2013 – Script Policy Summary – LyncPolicySummary.ps1

This simple script will summarise how many users are assigned each policy in Lync as well as how many users are against each registrar pool. # Author: Created by Weakest Lync, www.WeakestLync.com # Purpose: Script to show the number of users assigned each policy # Version: 1.0 # Changes: DATE - Change # 09/11/2014 - Release 1.0 $users = Get-CsUser Write-Host "Registrar Pool Sumamry" -ForegroundColor Yellow $users | Group-Object RegistrarPool | Select-Object Count, Name Write-Host "Voice Policy Summary" -ForegroundColor Yellow $users | Group-Object VoicePolicy | Select-Object Count, Name Write-Host "Dial Plan Summary" -ForegroundColor Yellow $users | Group-Object DialPlan | Select-Object Count, Name Write-Host "Conferencing Policy Summary" -ForegroundColor Yellow $users | Group-Object ConferencingPolicy | Select-Object Count, Name Write-Host "External Access Summary" -ForegroundColor Yellow $users | Group-Object ExternalAccessPolicy | Select-Object Count, Name Write-Host "Location Policy Summary" -ForegroundColor Yellow $users | Group-Object LocationPolicy | Select-Object Count, Name Write-Host "Client Policy Summary" -ForegroundColor Yellow $users | Group-Object ClientPolicy | Select-Object Count, Name Write-Host "Archiving Policy Sumamry" -ForegroundColor Yellow $users | Group-Object ArchivingPolicy | Select-Object Count, Name Write-Host "Pin Policy Sumamry" -ForegroundColor Yellow $users | Group-Object PinPolicy | Select-Object Count, Name Write-Host "Mobility Policy Sumamry" -ForegroundColor Yellow $users | Group-Object MobilityPolicy | Select-Object Count, Name Write-Host "Persistent Chat Policy Sumamry" -ForegroundColor Yellow $users | Group-Object PersistentChatPolicy | Select-Object Count, Name Write-Host "Hosted Voicemail Policy Sumamry" -ForegroundColor Yellow $users | Group-Object HostedVoicemailPolicy | Select-Object Count, Name

9 November 2014 · 2 min · Chris Hayward

Lync 2013 – Standard Edition Pool Pair Failover Script

Lync 2013 introduced a new feature called Pool Pairing. Given the scenario below with 2 sites using Lync Standard Edition with paired pools, in the event that Front End 01 was to fail, or Site 1 failed completely all users will automatically register to Front End 02. However they will receive an error in their Lync client “Limited Functionality due to Outage”, lose their buddy lists, presence information, conferencing features and any Response Groups that were homed on FE01. They will still be able to make inbound and outbound PSTN calls (assuming you have resilient Voice Routing) and they will still be able to search contacts to make P2P audio and video calls. To restore full functionality you need to manually failover the pool following the procedure here: http://technet.microsoft.com/en-us/library/jj204678.aspx ...

22 January 2014 · 9 min · Chris Hayward