SharePoint Blogs / SharePoint University
SharePoint Blogs and SharePoint University - all in one place!
Need SharePoint Training? Attend a SharePoint Bootcamp!

Please delete cookies related to sharepointblogs.com and sharepointu.com to resolve login issues!

Failure trying to sync

There's always a lesson to be learned.  Such is the nature of the beast! The more we work with this wonderful product called SharePoint, the more we realize how sensitive it can be, and how wierd things just seem to "happen". I've ran into quite a few on this particular project, and decided to post this in hopes of saving others some possible heartache.  If you've had errors in your event logs like these:

failure trying to synch site [SITE GUID} for ContentDB [contentdb GUID] WebApp [web app GUID]. Exception message was Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED

event id 5533 

or

 A runtime exception was detected. Details follow. Message: Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))Techinal Details:System.UnauthorizedAccessException: Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))at Microsoft.SharePoint.SPGlobal.HandleUnauthorizedAccessException(UnauthorizedAccessException ex)at Microsoft.SharePoint.Library.SPRequest.AddField(String bstrUrl, String bstrListName, String bstrSchemaXml, Int32 grfAdd)at Microsoft.SharePoint.SPFieldCollection.AddFieldAsXmlInternal(String schemaXml, Boolean addToDefaultView, SPAddFieldOptions op)at Microsoft.SharePoint.SPFieldCollection.AddFieldAsXml(String schemaXml, Boolean addToDefaultView, SPAddFieldOptions op)at Microsoft.SharePoint.SPFieldCollection.AddFieldAsXml(String strXml)at Microsoft.SharePoint.SPFieldCollection.AddInternal(String strDisplayName, SPFieldType type, Boolean bRequired, Boolean bCompactName, Guid lookupListId, Guid lookupWebId, StringCollection choices)at Microsoft.SharePoint.SPFieldCollection.Add(String strDisplayName, SPFieldType type, Boolean bRequired, Boolean bCompactName, StringCollection choices)at Microsoft.SharePoint.SPFieldCollection.Add(String strDisplayName, SPFieldType type, Boolean bRequired)at Microsoft.Office.Server.UserProfiles.SiteSynchronizer.UserSynchronizer.TryAddFieldToUserInfoListWithInternalName(String strWSSInternalName, SPFieldType fieldType)at Microsoft.Office.Server.UserProfiles.SiteSynchronizer.UserSynchronizer.AddFieldToUserInfoList(String strProfilePropName, SPFieldType fieldType)at Microsoft.Office.Server.UserProfiles.SiteSynchronizer.UserSynchronizer.PushSchemaToList(Boolean& bAddedColumn)at Microsoft.Office.Server.UserProfiles.SiteSynchronizer.UserSynchronizer.SynchFull()at Microsoft.Office.Server.UserProfiles.SiteSynchronizer.Synch()at Microsoft.Office.Server.Diagnostics.FirstChanceHandler.ExceptionFilter(Boolean fRethrowException, TryBlock tryBlock, FilterBlock filter, CatchBlock catchBlock, FinallyBlock finallyBlock)

evevt id 7888 

there's a good chance that you have a profile synchronization issue (or several).  Here are the steps I took to correct these errors:

1.      I downloaded a wonderful, free (yes, FREE!) utility called SharePoint Inspector, created by Gat Bouveret. His blog with a link to the codeplex download site can be found here.  I used this tool to identify the web applications and sites referred to by their GUID  in the event log errors.

2.      I opened a command prompt and typed stsadm- o preparetomove –Site http://whatevertheguiltysiteis –OldContentDb   <GUID of the contentdb listed in event log error>

3.      After this completed successfully, I ran stsadm –o sync –deleteolddatabases 0 (note: Depending on how long you’ve been seeing these errors, you may be able to use a switch greater than zero. If it’s been 2 days since it synched last, you can use 2. You can tell this by typing stsadm –o sync –listolddatabases <number of days you think> and look for the offending content db guid.

In my case, there were 4 “my site” sites that were not syncing with the profile database. After  performing these steps, I rechecked the event log at the top of the hour to see if the errors had reoccurred. GONE! 

A little something extra: I have also had to do this on occasions where a web application was deleted, leaving the content db intact, and re-created attaching to the same content db without first running the prepare to move command. Same steps apply.

Hope this helps!

 


Posted 10-10-2007 1:02 PM by misterbeefy

Comments

Blogger Loser » Failure trying to sync wrote Blogger Loser &raquo; Failure trying to sync
on 10-10-2007 2:33 PM

Pingback from  Blogger Loser &raquo; Failure trying to sync

Tuan Nguyen wrote re: Failure trying to sync
on 12-03-2007 2:44 PM

I have tried those commands, it didn't generate the errors in the eventlog anymore, but after a day later I rebooted the server and the same errors occured in the errorlog. Not sure how to make them gone away.

Thanks,

Tuan

chetuo wrote re: Failure trying to sync
on 01-28-2008 11:40 AM

very good!!!!

Ross Cosner wrote re: Failure trying to sync
on 04-15-2008 9:51 AM

I may be missing something, but what if you have hundreds of sites?  It doesn't seem very ideal to have to search for the GUID for every single site in your MOSS Farm by scrolling through lists via the object model.

It would be nice if there were a "find" option where you could search through the results of SharePoint Inspector and it takes you directly to whatever you're searching for.  I had a hard time finding SharePoint Inspector on Gat's site since its in French, you have to translate it, etc, so heres the URL to the project on the CodePlex website:

http://www.codeplex.com/spi

Sean wrote re: Failure trying to sync
on 05-23-2008 11:02 AM

Hi found a reference in our website above relating to a rlangley one google search later and I am here now of course could be unrelated but im trying to get on my website ftp?

as the company who where meant to be building it have gone walkies

www.core-web-design.co.uk

this is just on the off chance you could be rlangley, if not sorry to bother you

Bob wrote re: Failure trying to sync
on 09-26-2008 11:37 AM

That did the trick for me.  Thanks very much mate

Jonny wrote re: Failure trying to sync
on 10-06-2008 5:48 AM

The command stsadm –o sync –deleteolddatabases  doesn't even work...

Kunal wrote re: Failure trying to sync
on 10-07-2008 10:43 PM

Similar issue but some extra steps were required in my case to solve the error. Check here:

mossytips.blogspot.com/.../error-event-id-5555-event-id-7888-after.html

Sharepoint Event log filled with these errors every hour | keyongtech wrote Sharepoint Event log filled with these errors every hour | keyongtech
on 01-18-2009 11:23 AM

Pingback from  Sharepoint Event log filled with these errors every hour | keyongtech

Brian wrote re: Failure trying to sync
on 06-17-2009 12:19 PM

Also - if the fix above doesn't work - ensure that your AppPool credentials are the same in both IIS and SharePoint.  If they're not the same and don't have the proper rights to authenticate against both SharePoint and the AppPools, you will receive these errors.

Dhana wrote re: Failure trying to sync
on 06-25-2009 6:26 AM

I have seen that these orphans entries in the database cones up mostlty if you do migration or upgrade without running the preparetomove command and if you have mutliple data.

This issue I feel is fixed in MOSS SP2

www.ekhichdi.com/.../issues-fixed-by-service-pack-2-(sp2)-in-the-2007-office-server-products/

Add a Comment

(required)  
(optional)
(required)  
Remember Me?
Need SharePoint Training? Attend a SharePoint Bootcamp!
Posts (c) their respective authors. Everything else (c) 2009 SharePoint Experts, Inc.