Moving a SharePoint 2010 Site Collection to another Content Database

Moving a Content Database to another Site Collection has never been easier than in PowerShell.  Just fire up your PowerShell, add the Snap-In for SharePoint and run Move-SPSite.

PS C:Usersmrhodes> get-help Move-SPSite -full

NAME
    Move-SPSite

SYNTAX
    Move-SPSite [-Identity] <SPSitePipeBind> -DestinationDatabase <SPContentDatabasePipeBind> [-AssignmentCollection <S
    PAssignmentCollection>] [-Verbose] [-Debug] [-ErrorAction <ActionPreference>] [-WarningAction <ActionPreference>] [
    -ErrorVariable <String>] [-WarningVariable <String>] [-OutVariable <String>] [-OutBuffer <Int32>] [-WhatIf] [-Confi
    rm]

PS C:Usersmrhodes> Move-SPSite -Identity http://mysharepointsite.com.au/sites/user -destinationdatabase WSS-Content-NewUserDB

Confirm
Are you sure you want to perform this action?
Performing operation "Move-SPSite" on Target "http://mysharepointsite.com.au/sites/user".
[Y] Yes  [A] Yes to All  [N] No  [L] No to All  [S] Suspend  [?] Help (default is "Y"): y
WARNING: IIS must be restarted before this change will take effect. To restart IIS, open a command prompt window and
type iisreset.
 

And just that easily, my Site Collection has now been moved to a new Content Database!

Advertisement

One Response to Moving a SharePoint 2010 Site Collection to another Content Database

  1. Pingback: 2010 in review « Mark Rhodes

Leave a Reply

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

Gravatar
WordPress.com Logo

You are commenting using your WordPress.com 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

Follow

Get every new post delivered to your Inbox.

Join 1,102 other followers