CX_UserMemberships_RecordId_MemberGroupId_SID Event Source: Office SharePoint Server
Error :
failure trying to synch site abc12d90-7d1d-4341-8df3-a1d92eba7a47 for ContentDB db7fb0d6-7d0d-4230-8de5-e7cc00ca0db7 WebApp e4b621e3-148d-4822-96bf-357b341b715d. Exception message was Cannot insert duplicate key row in object 'dbo.UserMemberships' with unique index 'CX_UserMemberships_RecordId_MemberGroupId_SID'. The statement has been terminated..
Solving:
to solve this error on SharePoint 2007 FARM run a Query on Configration Database and take the name webapplication
SELECT Id, ClassId, ParentId, Name, Status, Version, Properties
FROM Objects
WHERE (Id = 'e4b621e3-148d-4822-96bf-357b341b715d')
and run this 3 stsadm command on your sahrePoint enviroment
stsadm -o preparetomove -ContentDB YOUR_SQL_SERVER_NAME:YOUR_SITE_CONTENT_DB_NAME -Site http://yourSiteName
stsadm -o deletecontentdb -url http://yourSiteName -databaseserver YOUR_SQL_SERVER_NAME -databasename YOUR_CONTENT_DB_NAME
stsadm -o addcontentdb -url http://yourSiteName -databasename YOUR_CONTENT_DB_NAME -databaseserver YOUR_SQL_SERVER_NAME