Cannot connect current devices to Exchange 2010 using ActiveSync


I'm having a problem with Exchange ActiveSync on Exchange 2010 in Small Business 2011 environment, recently I had to roll back to a previous system state (the image was taken in May) due to a hard drive failure.
The exchange data and logs weren't on the drive that failed so they have not been rolled back at all, I had to run a repair using eseutil on the exchange to re-mount after the recovery.

Now when I connect a brand new device to a users mailbox on the server it works fine, however when the phones / tablets that were previously connected try and re-connect to the server it seems like it's connected, but then nothing is synced to the device. I receive the following error in event viewer:

An exception occurred and was handled by Exchange ActiveSync. This may have been caused by an outdated or corrupted Exchange ActiveSync device partnership. This can occur if a user tries to modify the same item from multiple computers. If this is the case, Exchange ActiveSync will re-create the partnership with the device. Items will be updated at the next synchronization.

--- Exception start ---
Exception type: Microsoft.Exchange.Data.Storage.SyncStateExistedException
Exception message: The sync state named 5 already exists.
Exception level: 0
Exception stack trace:    at Microsoft.Exchange.Data.Storage.SyncState.CreateSyncStateFolderInFolder(SyncStateInfo syncStateInfo, Folder syncStateParentFolder, PropertyDefinition[] properties, Object[] values)
   at Microsoft.Exchange.Data.Storage.SyncState.CreateSyncStateStoreObject(SyncStateStorage syncStateStorage, SyncStateInfo syncStateInfo, Folder syncStateParentFolder, PropertyDefinition[] properties, Object[] values)
   at Microsoft.Exchange.Data.Storage.FolderSyncState.CreateSyncState(SyncStateStorage syncStateStorage, Folder syncStateParentFolder, ISyncProviderFactory syncProviderFactory, String syncFolderId)
   at Microsoft.Exchange.Data.Storage.SyncStateStorage.CreateFolderSyncState(ISyncProviderFactory syncProviderFactory, String syncFolderId)
   at Microsoft.Exchange.AirSync.SyncCollection.OpenSyncState(Boolean autoLoadFilterAndSyncKey, SyncStateStorage syncStateStorage)
   at Microsoft.Exchange.AirSync.SyncCommand.SyncTheCollection(SyncCollection collection, Boolean createSubscription, Boolean tryNullSync)
   at Microsoft.Exchange.AirSync.SyncCommand.OnExecute()
   at Microsoft.Exchange.AirSync.SyncCommand.ExecuteCommand()
   at Microsoft.Exchange.AirSync.Command.WorkerThread()
Inner exception follows below:
Exception type: Microsoft.Exchange.Data.Storage.ObjectExistedException
Exception message: Could not create folder 5.
Exception level: 1
Exception stack trace:    at Microsoft.Exchange.Data.Storage.FolderCreatePropertyBag.CreateMapiFolder()
   at Microsoft.Exchange.Data.Storage.FolderCreatePropertyBag.SaveFolderPropertyBag(Boolean needVersionCheck)
   at Microsoft.Exchange.Data.Storage.CoreFolder.Save(SaveMode saveMode)
   at Microsoft.Exchange.Data.Storage.Folder.Save(SaveMode saveMode)
   at Microsoft.Exchange.Data.Storage.SyncState.CreateSyncStateFolderInFolder(SyncStateInfo syncStateInfo, Folder syncStateParentFolder, PropertyDefinition[] properties, Object[] values)
Inner exception follows below:
Exception type: Microsoft.Mapi.MapiExceptionCollision
Exception message: MapiExceptionCollision: Unable to create folder. (hr=0x80040604, ec=-2147219964)
Diagnostic context:
    Lid: 55847   EMSMDBPOOL.EcPoolSessionDoRpc called [length=60]
    Lid: 43559   EMSMDBPOOL.EcPoolSessionDoRpc returned [ec=0x0][length=244][latency=0]
    Lid: 23226   --- ROP Parse Start ---
    Lid: 27962   ROP: ropCreateFolder [28]
    Lid: 17082   ROP Error: 0x80040604
    Lid: 25953  
    Lid: 21921   StoreEc: 0x80040604
    Lid: 27962   ROP: ropExtendedError [250]
    Lid: 1494    ---- Remote Context Beg ----
    Lid: 26426   ROP: ropCreateFolder [28]
    Lid: 21970   StoreEc: 0x8004010F PropTag: 0x668F0040
    Lid: 21970   StoreEc: 0x8004010F PropTag: 0x3FE5000B
    Lid: 15348   StoreEc: 0xFFFFFA84
    Lid: 63733  
    Lid: 5079    StoreEc: 0x80040604
    Lid: 6255    StoreEc: 0x80040604
    Lid: 6511    StoreEc: 0x80040604
    Lid: 8047    StoreEc: 0x80040604
    Lid: 7310    StoreEc: 0x80040604
    Lid: 1750    ---- Remote Context End ----
    Lid: 31418   --- ROP Parse Done ---
    Lid: 22417  
    Lid: 30609   StoreEc: 0x80040604
    Lid: 29073  
    Lid: 20369   StoreEc: 0x80040604
Exception level: 2
Exception stack trace:    at Microsoft.Mapi.MapiExceptionHelper.ThrowIfError(String message, Int32 hresult, SafeExInterfaceHandle iUnknown, Exception innerException)
   at Microsoft.Mapi.MapiFolder.CreateFolder(String folderName, String folderComment, Boolean openIfExists, Boolean createSearchFolder, Byte[] folderId)
   at Microsoft.Mapi.MapiFolder.CreateFolder(String folderName, String folderComment, Boolean openIfExists)
   at Microsoft.Exchange.Data.Storage.FolderCreatePropertyBag.CreateMapiFolder()
--- Exception end ---.

I have tried creating a new mailbox database and moving this specific user into it, and also removing the partnership for his devices within EMC and through OWA and reset the ActiveSync virtual directory to no avail.

I am getting lost and not sure where to go from here, any help is appreciated,
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Andy MIT Systems ManagerCommented:
Couple of things to try:

1. Remove the existing accounts from the affected phones.
2. For the affected user log onto OWA and under options > phones remove any partnership listed for that user.
3. Try re-adding the account.

If that doesn't work try the following:

In ADUC (Active Directory User and Computers) enable advanced features in the View menu.
Then right-click on the affected user(s) account and go to properties
Select the Security tab and click on Advanced
Click Enable Inheritance then click OK until you are back to ADUC

Then try re-adding the account to the device.

I'd recommend trying the above on one affected user first before doing every single one as depending on the number of affected accounts it can be time consuming.
Norbert2000Author Commented:
Hi Andy,

I've tried steps 1 through 3, the account seems to verify and go on the phone but there's nothing synced. What i have also tried is getting a the user to reset his phone (iPhone 5) and then adding the account the reset phone. This seemed to work but when he restored his settings / apps it started not syncing again.

I will try the ADUC solution above and come back.

Norbert2000Author Commented:
in Active Directory the user was already inheriting permissions, so i unticked and added the permissions and then re-ticked the inherit permissions button. Tried the phone again and still the same, connects but doesn't sync anything with the same event log on the server.

Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

Andy MIT Systems ManagerCommented:
Hmm, is the server fully up-to-date with exchange service packs and updates?

Could also try disabling Activesync for the account on exchange, remove the account from the device, re-enable activesync on the account in exchange and then try re-creating the account on the device.
Norbert2000Author Commented:
Server is fully up to date. I tried what you suggested but still the same problem. I have now removed the exchange mailbox for the users and re-add and re-imported the mail and it seems to be working.

Thanks for the help.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Norbert2000Author Commented:
After trying to solve the issue I resorted to a workaround of removing and re-adding the exchange accounts.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.