MsExchange Blog Spot Telnet25

August 2, 2011

Move Public Folders All replica to Exchange 2010 Server PS Script

Filed under: General — telnet25 @ 3:24 am

If you are in the middle of migration and it is time to move all PF folder replicas from Exchange 2007 to Exchange 2010 server PS is your friend.

Lets say your Existing Exchange 2007 Server name is EXC07 and you want to move all PF replicas to newly build Exchange 2010 Server called EXC210 , you can use fallowing PS commands…..

Connect to your Exchange Server , open EMS


Navigate fallowing directory from PS command line

[PS] E:\Program Files\Microsoft\Exchange Server\V14\Scripts>

  • AddReplicaToPFRecursive.ps1
  • RemoveReplicaFromPFRecursive.ps1
  • ReplaceReplicaOnPFRecursive.ps1
  • MoveAllReplicas.ps1


Now we are ready to execute existing scripts sits on this directory. All PF replicas sits on the server called “EXC07” and I like to add Exchange 2010 Server called “EXC210 into PF replica  folders as second server.


.\AddReplicaToPFRecursive.ps1 –Server EXC210 –TopPublicFolder \ –ServerToAdd “EXC07”


Remove Replica  ( pay attention  Exchange  server must have all of its public folder replicas removed before it can be decommissioned…. )

.\RemoveReplicaToPFRecursive.ps1 –Server EXC210 –TopPublicFolder \ –ServerToRemove “EXC07”
  • Now System folders
.\AddReplicaToPFRecursive.ps1 -TopPublicFolder "\NON_IPM_Subtree" ServerToAdd


  • To view a list of the replicas in the public folder hierarchy
Get-PublicFolder -recurse |fl name,replicas
  • Move all replicas from EXCH07 to EXC210

MoveAllReplicas.ps1 –Server EXC07 –NewServer EXC210

  • For System Folders
Get-PublicFolder -recurse \non_ipm_subtree |fl name, replicas
  • To compare content replicated between the source and destination servers
Get-PublicFolderStatistics | FL
  • Also
Get-PublicFolderStatistics –Server ServerA
  • Compare Output to ServerB
Get-PublicFolderStatistics –Server ServerA



Oz Casey, Dedeal ( MVP north America)
MCSE 2003, M+, S+, MCDST
Security+, Project +, Server + (Blog) (Blog


Leave a Comment »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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

Create a free website or blog at

%d bloggers like this: