in

SharePoint Blogs

The Best Place for SharePoint-related Blogs

David Wise's Sharepoint blog

A duplicate site ID ... error in Event Log after moving Content Databases.

After moving the content database to another SQL Server, I started getting the following message in the event log every hour : "A duplicate site ID ... was found. This might be caused by restoring a content database from one server farm into a different server farm without first removing the original database and then running stsadm -o preparetomove. If this is the cause, the stsadm -o preparetomove command can be used with the -OldContentDB command line option to resolve this issue."

Nice and simple and even a recommended solution in the error message - except that it wouldn't work. After a lot of additional searching I turned up this command, which did work:

stsadm -o sync -DeleteOldDatabases 0

I am reposting it here because of how hard it was to find in the first place.  For what its worth, the full syntax of this is:

stsadm -o sync
           {-ExcludeWebApps <web applications> |
            -SyncTiming <schedule(M/H/D:value)> |
            -SweepTiming <schedule(M/H/D:value)> |
            -ListOldDatabases <days> |
            -DeleteOldDatabases <days>}


The original answer was posted by Vikram Garlapati.

Published Mar 01 2007, 10:51 PM by DavidWise
Filed under:

Comments

 

JustMigrated said:

Thank you!!! Damn those cryptic and false error messages!

February 15, 2008 12:47 PM
 

Brad Cote said:

I spent FOREVER on this error - attaching and reattaching (at least I figured out how to find old databases GUIDs for the preparetomove command).

Thanks so much for posting this!

June 27, 2008 1:01 PM
 

Ivan Mckenzie Rodriguez said:

Nice work my friend.

Thanks a lot!!!!

July 18, 2008 9:12 AM

Leave a Comment

(required )  
(optional )
(required )  
Add

About DavidWise

I have been writing software for over 16 years and web applications for 11 years. I have been also been elbow deep in SharePoint 2007 since Beta 2 and loving it! Currently, I work for Bennett Adelson Consulting (a Microsoft Gold Partner) based in Cleveland, Ohio.

Need SharePoint Training? Attend a SharePoint Bootcamp!

Posts (c) their respective authors. Everything else (c) 2007 SharePoint Experts