Lync Server 2013: Event 14497,14517 LS Protocol Stack

This issue dates a while back, but after Lync Server 2013 Cumulative Update 3 (5.0.8308.556 and above) the Edge Server Access Service won’t start with the Event 14497 LS Protocol Stack:

Event14517-14497-02

One or more configuration errors were detected at startup that cannot be mitigated.

Cause: There are serious problems with the server configuration that prevented it from starting up.
Resolution:
Review the previous event log entries to identify failures. Alter the server configuration as required. If problems persist, contact Product Support Services.

Log Name:      Lync Server
Source:        LS Protocol Stack
Date:          07/05/2015 17:41:09
Event ID:      14497
Task Category: (1001)
Level:         Error
Keywords:      Classic
User:          N/A

Computer:      edge01.gears.lab

In a previous error, we found the following in Event Viewer:

Event14517-14497-01

Event 14517, LS Protocol Stack

The server configuration validation mechanism detected some serious problems.

1 errors and 0 warnings were detected.

ERRORS:
The server at FQDN [sipfed.online.lync.com] is configured as both type ‘allowed partner server’ and type ‘IM service provider’.

WARNINGS:
No warnings

Cause: The configuration is invalid and the server might not behave as expected.
Resolution:
Review and correct the errors listed above, then restart the service. You may also wish to review any warnings present.

Log Name:      Lync Server
Source:        LS Protocol Stack
Date:          07/05/2015 10:32:35
Event ID:      14517
Task Category: (1001)
Level:         Error
Keywords:      Classic
User:          N/A
Computer:      edge01.gears.lab

Both the errors helped us to find the issue easily. In this case, we had configured a Lync Online tenant as Allowed Domain in SIP Federated Domains before updating to Lync Server 2013 CU3:

Lync Server Control Panel

Event14517-14497-03

Event14517-14497-04

Lync Server PowerShell

Lync Server 2013: Get-CsAllowedDomain
https://docs.microsoft.com/powershell/module/skype/Get-CsAllowedDomain

Event14517-14497-03ps

Lync Server 2013: Get-CsHostingProvider
https://docs.microsoft.com/powershell/module/skype/Get-CsHostingProvider

Event14517-14497-04ps

To solve this we simply need to remove the Access Edge service (FQDN), which in this case is sipfed.online.lync.com from the Allowed Domain:

Lync Server Control Panel

Event14517-14497-05

Lync Server PowerShell

Lync Server 2013: Set-CsAllowedDomain
https://docs.microsoft.com/powershell/module/skype/Set-CsAllowedDomain

Event14517-14497-05ps

Before continue, we need to check if the replication was successful:

Lync Server 2013: Get-CsManagementStoreReplicationStatus
https://docs.microsoft.com/powershell/module/skype/Get-CsManagementStoreReplicationStatus

Event14517-14497-06a

Now we can go to Edge Server and use Start-CsWindowsService to start all Lync Server related services. After that, we can check with Get-CsWindowsService that all services are up and running:

Event14517-14497-06

Notice that after Lync Server 2013 Cumulative Update 3 we cannot add a new Allowed Domain with the same Access Edge service (FQDN) as a Hosting Provider:

Event14517-14497-07

When using Allowed Domains without specifying the Access Edge service (FQDN), make sure that Lync Server will rely on the DNS SRV Record for that specific SIP domain.

The Nslookup.exe Command Line Tool

nslookup -type=srv _sipfederationtls._tcp.<SIP Domain>
Event14517-14497-08