Remove Multiple Public Folders from a Public Folder Database

 

Applies to: Exchange Server 2010 SP3, Exchange Server 2010 SP2

You can use the Shell to remove all the public folders from a public folder database.

This procedure removes all the user and system public folders from a public folder database. If you only want to remove one public folder from a public folder database, see Remove Public Folders. This procedure is required if you are removing the last public folder database in your Exchange organization. For detailed instructions about how to remove public folder databases, see Remove Public Folder Databases.

Warning

The Remove-PublicFolder cmdlet removes the public folder data from all servers in your organization. If you only want to remove data from one server, use the Set-PublicFolder cmdlet with the Replicas parameter. For more information, see Set-PublicFolder.

Looking for other management tasks related to public folder databases? Check out Managing Public Folder Databases.

Use the Shell to delete user public folders

You need to be assigned permissions before you can perform this procedure. To see what permissions you need, see the "Public folders" entry in the Mailbox Permissions topic.

Note

You can't use the EMC to delete user public folders.

This example removes all user public folders.

Get-PublicFolder -Server <server containing the public folder database> "\" -Recurse -ResultSize:Unlimited | Remove-PublicFolder -Server <server containing the public folder database> -Recurse -ErrorAction:SilentlyContinue

For detailed syntax and parameter information, see Get-PublicFolder and Remove-PublicFolder.

Use the Shell to delete system public folders

You need to be assigned permissions before you can perform this procedure. To see what permissions you need, see the "Public folders" entry in the Mailbox Permissions topic.

Note

You can't use the EMC to delete system public folders.

This example removes all system public folders.

Get-PublicFolder -Server <server containing the public folder database> "\Non_Ipm_Subtree" -Recurse -ResultSize:Unlimited | Remove-PublicFolder -Server <server containing the public folder database> -Recurse -ErrorAction:SilentlyContinue

For detailed syntax and parameter information, see Get-PublicFolder and Remove-PublicFolder.

 © 2010 Microsoft Corporation. All rights reserved.