Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm upgrading my organisation's Exchange set-up from 2007 to 2010 (by provisioning a new server with 2010 on, moving the mailboxes across, then decommissioning the 2007 server). The move went by without any real problems, however I've got a problem where I can't get rid of the old 2007 server without error messages.

The 2007 server has the Public Folder database on it still, when I try to Remove the Public Folder database from within EMC I get this error:


Microsoft Exchange Error

The public folder database 'Public Folder Database' cannot be deleted.

Public Folder Database Failed Error: The public folder database "OLDSERVER\Second Storage Group\Public Folder Database" contains folder replicas. Before deleting the public folder database, remove the folders or move the replicas to another public folder database. For detailed instructions about how to remove a public folder database, see http://go.microsoft.com/fwlink/?linkid=81409.

OK

I followed the links and saw that I need to move all the replicas within the database using this command:

.\MoveAllReplicas.ps1 -Server Server01 -NewServer Server02

So I ran it:

[PS] C:\Program Files\Microsoft\Exchange Server\Scripts>.\MoveAllReplicas.ps1 -Server "OLDSERVER" -NewServer "NEWSERVER"
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
Set-PublicFolder : The parameter "Replicas" cannot be $null or an empty array.
At C:\Program Files\Microsoft\Exchange Server\Scripts\ReplaceReplicaOnPFRecursive.ps1:147 char:24
+         $_ | set-publicfolder  <<<< -server $_.OriginatingServer;
[PS] C:\Program Files\Microsoft\Exchange Server\Scripts>

When I run the same command from the Exchange 2010 shell it simply quits and returns to the shell prompt. I still get the Replica error when I try to remove the Public Folders database.

I had a look around inside the 2010 version of ReplaceReplicaOnPFRecursive.ps1 and it turns out that it doesn't do anything at all with the data it's given. The recursive list of folders to modify that it builds is empty, so no commands end up being executed.

Any ideas?

share|improve this question
add comment

3 Answers

up vote 2 down vote accepted

Move public folder data to Exchange 2010

Public folders are an optional feature in Exchange 2010. If all client computers in your organization are running Microsoft Office Outlook 2007 or later, then public folders are an optional feature. However, if Outlook 2003 clients are in use, then public folders are required. In addition, if you're currently using public folders for collecting, organizing, or sharing documents and other information and you want to continue doing so, you can use public folder replication to move your public folder data to Exchange 2010.

Learn more at: Understanding Public Folder Replication 28

How do I do this?

You can use the Exchange Management Console to perform this task.

  1. In the Console tree, click Toolbox.
  2. In the Result pane, double-click Public Folder Management Console. The Public Folder Management Console appears.
  3. In the public folder tree, click or expand Default Public Folders, and then select the parent public folder of the public folder that you want to move to Exchange 2010. Note: To configure replication for the offline address book (OAB) or for Schedule+ free/ busy information, expand System Public Folders, and then click OFFLINE ADDRESS BOOK or SCHEDULE+ FREE BUSY.
  4. In the Result pane, right-click the public folder you want to replicate to Exchange 2010 and select Properties.
  5. On the Replication tab, click Add to select an Exchange 2010 public folder database and then click OK.
  6. By default, Exchange uses the replication schedule configured for the public folder database. To create a custom replication schedule for the public folder, clear the Use public folder database replication schedule check box and select one of the settings in the list.
  7. To create a customized schedule, click Customize.
  8. To set the schedule, click the time grid in the Schedule dialog box. Public folder replication will run during the time slots that you specify.
  9. Click OK to close the Schedule dialog box.
  10. To specify the age limit for items in this public folder, type the number of days in the Local replica age limit (days) box. Items that have reached the age limit are deleted.

Note: Age limits should be used for public folders only. They should not be used for System Folders, such as OFFLINE ADDRESS BOOK or SCHEDULE+ FREE BUSY.

  1. Click OK to close the Properties dialog and to save your changes.
  2. Repeat Steps 4-11 for each public folder you want to move to Exchange 2010.

How do I know this worked?

You can use the Get-PublicFolder cmdlet in the Exchange Management Shell to verify replicas on the Exchange 2010 public folder database. For example, to determine the replicas for all public folders in the public folder tree, run the following command: Get-PublicFolder -Recurse | Format-List Name,Replicas To determine the replicas for all system folders, run the following command: Get-PublicFolder \NON_IPM_SUBTREE | Format-List Name,Replicas 29 Learn more about the cmdlet at: Get-PublicFolder

Visit Link : http://technet.microsoft.com/en-us/exdeploy2010/default.aspx#DeploymentCheckList/ee958313/2007

share|improve this answer
    
I went through changing the replication settings for all the public folders, but it didn't work. I left it alone for a few hours and came back to see a queue had formed filled with PublicFolder messages that couldn't be delivered to the other Exchange server. I think that's the cause of the problems. –  Dai Dec 9 '10 at 13:41
    
Now that I see I've earned a 'famous question' badge from this question, I should add some closure. I (think) I fixed the problem by following-up the blockage in the mail queue - I forget what exactly I did, but I'm sure the solution was in there somewhere. I apologise for being so vague. –  Dai Dec 5 '11 at 23:16
add comment

If you have UAC enabled, are you running the Exchange Management Shell as administrator (right click -> "Run as Administrator")?

I've had issues with the Public Folder scripts before when you don't use the run as admin option (addreplicatopfrecursive.ps1 and removereplicafromPFrecursive.ps1 won't work properly).

share|improve this answer
add comment

protected by Iain Dec 2 '11 at 7:44

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.