Event ID 31128 when RGS can't synchronize an Agent Group member's SIP address in Lync Server 2013

Assume that a member of a distribution list is also a member of a Response Group service (RGS) agent group in a Microsoft Lync Server 2013 environment. When the member's SIP address is changed, all related changes are blocked from synchronizing from Active Directory to the RGS database. Also, event ID 31128 is logged as follows:

Log Name: Lync Server
Source: LS Response Group Service
Date: Date/Time
Event ID: 31128
Task Category: (2001)
Level: Error
Keywords: Classic
User: UserName
Computer: ComputerName
Data synchronization from Active Directory failed.

The following exception was thrown during the synchronization process:
Exception: System.Data.SqlClient.SqlException - Cannot insert duplicate key row in object 'dbo.Agents' with unique index 'IXAgentsUserSid'. The duplicate key value is (0x0105000000000005150000009e7c5c00db5d97c850f8f9d046220000).
The statement has been terminated.
Inner Exception: ~
The next synchronization attempt will be in 480 minutes.
Cause: Unhandled exception.
Verify the connectivity with the domain controller or if the Active Directory schema was properly applied and all user attributes are present.

Additionally, users who were recently added to the RGS agent group experience the following issues:
  • Newly added users don't receive the 'You were added as an agent' notification.
  • Calls that are made to the RGS workflow aren't routed to the newly added RGS agent.
This issue occurs because the SIP address change prevents RGS from referencing the agent. However, the RGS database indexes agents by using their SIP addresses.
To fix this issue, apply the April 2016 cumulative update 5.0.8308.956 for the Lync Server 2013, Response Group Service.

Article ID: 3148256 - Last Review: 05/20/2016 05:05:00 - Revision: 5.0

Microsoft Lync Server 2013

  • kbfix kbqfe kbsurveynew kbexpertiseinter KB3148256