LDAP Sync Fails due to Cannot Insert Duplicate Key Row Object Error

Still need help?

The Atlassian Community is here for you.

Ask the community

Symptoms

Error when syncing users from LDAP server. 

The following appears in the atlassian-jira.log:

com.atlassian.crowd.embedded.ofbiz.db.DataAccessException: org.ofbiz.core.entity.GenericEntityException: while inserting: [GenericEntity:Membership][id,58623][membershipType,GROUP_
GROUP][lowerParentName,pq-sales-sersol-global][parentId,10078][childId,10054][childName,PQ-Sales-SerSol-APAC][lowerChildName,pq-sales-sersol-apac][directoryId,10000][parentName,PQ-
Sales-SerSol-Global] (SQL Exception while executing the following:INSERT INTO jiraschema.cwd_membership (ID, parent_id, child_id, membership_type, group_type, parent_name, lower_pa
rent_name, child_name, lower_child_name, directory_id) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (Cannot insert duplicate key row in object 'jiraschema.cwd_membership' with unique inde
x 'uk_mem_parent_child_type'.))

Cause

A group name was changed on the LDAP server side, such as from upper case to lower case letters. There is a known bug for this,  JRA-27353 - Getting issue details... STATUS  - please vote and watch on it for future updates from the developers.

Resolution

Please refer to the suggested workaround in JRA-27353 - Getting issue details... STATUS

(info) Please see our Troubleshooting LDAP User Management documentation for further assistance with diagnosing LDAP problems.

Last modified on Nov 1, 2018

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.