Backup Content Databases-The Right Way

So running an stsadm command to backup a content database is not difficult in a WSS 3.0 or SharePoint 2007 environment. However, there are some other additional steps you should take when doing these backups which I have outlined here.

1. Run “stsadm -o setsitelock” with the “-lock” parameter of either “readonly” or “noaccess”
This ensures no changes are made to the database while backing it up.

2. Run “stsadm -o preparetomove”
This breaks the relationship between the database and the SSP. This allows a new/updated relationship to be established with this database and any SSP, as needed, when it is restored. This allows you to avoid the dreaded error message “Failure to synch web application <guid>: A duplicate site ID…”

3. Run “stsadm -o backup”
No explanation needed.

4. Run “stsadm -o sitelock” with the “-lock” parameter of “none”
This removes all locks on the database after the backup so changes can be made again.

Please see TechNet or “stsadm -help” for detailed instructions on all parameters needed to run these commands.

UPDATE (May 2008): If you would like more information about why I make the recommendation about preparetomove or you are having the sync issue and need a way to resolve, see this blog post.

About J.D. Wade

Lead Technical Cloud Architect, husband, active in community theatre, love watching movies, have been described as “quirky”, aka “KB Man”
This entry was posted in Microsoft Office SharePoint Server 2007 (MOSS 2007), Microsoft SharePoint, Outdated: Do Not Use, Windows SharePoint Services 3.0 (WSS 3.0) and tagged . Bookmark the permalink.

2 Responses to Backup Content Databases-The Right Way

  1. J.D. Wade says:

    He had changed the URL of the blog post. I have updated the link. Thanks!

Join the discussion by leaving a comment

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.