I am getting the following error every one hour in SharePoint. Not sure what exactly is happening. Any help will be appreciated. The error is below.

Event Id: 5553 failure trying to synch site 98f9c566-412c-49e3-b184-b22437447056 for ContentDB 362b1bf3-2234-417f-bf6c-7da5c9ad3444 WebApp 62a34660-7022-4a36-88a7-6813c8ad7788. Exception message was Cannot insert duplicate key row in object 'dbo.UserMemberships' with unique index 'CX_UserMemberships_RecordId_MemberGroupId_SID'. The duplicate key value is (0c37852b-34d0-418e-91c6-2ac25af4be5b, 123, 476, 0x0105000000000005150000001525af477973dd0607e53b2b9b190000). The statement has been terminated..



This event occurs when the SharePoint Timer Job "User Profile to SharePoint Full Synchronization" fails. The "User Profile to SharePoint Full Synchronization" job runs every hour by default. The most common reason for this job to fail is inconsistent user profile data between the user profile service, and the content database. This inconsistency can occur when content databases are deleted or incorrectly moved.


You can use stsadm command to list information about the databases that have not been synchronized with the user profile service.

stsadm -o sync -listolddatabases n
stsadm -o sync -deleteolddatabases n

where 'n' is the number of days that have passed since the databases have been synchronized

The '-listolddatabases' command lists the content databases that have not been synchronized since 'n' days while the 'deleteolddatabases' command performs the same operation as the listolddatabases parameter, except it deletes old records corresponding to these databases. It does not delete the databases themselves. Once the synchronization references are deleted and a new profile synchronization occurs, new references will be stored in the database.

You must run the stsadm shell as the farm account for the previous commands to work successfully.

Source: First hit in Google

| improve this answer | |
  • when i try to delete stsadm -o sync -deleteold databases. I am getting a error message saying A failure occurred during the processing of this command. Check diagnostic logs for more information – Mohammed Eliyas Ahmed Jan 11 '16 at 19:50
  • I could see that syncronization shows dated 3 years ago – Mohammed Eliyas Ahmed Jan 11 '16 at 19:51
  • What does the ULS log say when you run the -deleteolddatabases? – Jussi Palo Jan 12 '16 at 7:16
  • Clipboard reader could not understand a line. The line was: stsadm -o sync -deleteolddatabases n. Error was: System.FormatException: The string was not recognized as a valid DateTime. There is a unknown word starting at index 0. at System.DateTimeParse.Parse(String s, DateTimeFormatInfo dtfi, DateTimeStyles styles) at UlsGump.Column.TimeColumn.ParseTime(StringFacade timeString) at UlsGump.UlsEntry.SetEntryFromThread(StringFacade[] threadFacades, StringCacheFile stringCacheFile, Int64 messageLocation) – Mohammed Eliyas Ahmed Jan 12 '16 at 19:21
  • n must be integer, such as 0, e.g. stsadm -o sync -deleteolddatabases 0 – Jussi Palo Jan 12 '16 at 20:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.