The following powershell script migrates a Project Server 2010 to a Project Server 2013 Preview database. Reminder that this is a preview and that many things may change before release. Please send any comments to mwharton@whartoncomputer.com

#
# Author: Michael Wharton
# Date: 10/10/2012
# Description: PowerShell script to automate the migration of Project Server 2010 to Project Server 2013
# V1.0 First draft of migration powerscript. Later versions to check for sanity of script
#
# First provision a PWA site. The script will update the PWA with a new migrated database
#
$URL = "http://betasp2013/"
$PWA = "http://BetaSP2013/PWA"
$DatabaseServer = "WCC035SQL"
$ContentDBname = "PWA_WSS_Content"
$DraftDBname = "PWA_Draft"
$ArchiveDBname = "PWA_Archive"
$PublishedDBname = "PWA_Published"
$ReportingDBname = "PWA_Reporting"
$ProjectServiceDBname = "PWA_ProjectWebApp"
$LCID = "20" # I picked a number that wasn't used in SQL Server
#
#
# Update the following
#
Set-ExecutionPolicy "Unrestricted"
Add-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue
#
# Get-SPContentDatabase -WebApplication $URL | Dismount-SPContentDatabase -WhatIf
Mount-SPContentDatabase -Name $ContentDBname -DatabaseServer $DatabaseServer -WebApplication $URL -NoB2BSiteUpgrade
#
# update the authentication to Claims Authentication ---- this may not be required because the default is CLAIMS Authentication
$WA=Get-SPWebApplication $URL
#$WA.MigrationUserToClaimsUser($true)
#$WA.MigrateUsers($true)
#
Upgrade-SPSite $PWA -VersionUpgrade
#
# Creates a new Project Service Database
#
ConvertTo-SPProjectDatabase -WebApplication $URL -Dbserver $Databaseserver -LCID $LCID -ProjectServiceDbname $ProjectServiceDBname -ArchiveDbname $ArchiveDBname -DraftDbname $DraftDBname -PublishedDbname $PublishedDBname -ReportingDbname $ReportingDBname
#
Mount-SPProjectDatabase $ProjectServiceDBname -ServiceApplication "Project Service Application"
#
# Dismount the current Project Web Instance
Dismount-SPProjectWebInstance -SiteCollection $PWA
#
# Mount the Project Web Instance with converted Project Service DB
Mount-SPProjectWebInstance -SiteCollection $PWA -DatabaseName $ProjectServiceDBname
#
Upgrade-SPProjectWebInstance $PWA

 


See Also