Book Image

Microsoft Exchange Server Powershell Cookbook (Update)

Book Image

Microsoft Exchange Server Powershell Cookbook (Update)

Overview of this book

Table of Contents (21 chapters)
Microsoft Exchange Server PowerShell Cookbook Third Edition
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Reporting on public folder statistics


Since the public folder structure got created in the earlier recipe, it's now time for taking out statistics of the public folders and retrieving information about the contents.

This is basically done using the Get-Mailbox and Get-PublicFolderStatistics cmdlets.

In this recipe, we will also take a look at exporting the statistics to a CSV file and finally, we will check out the quota settings.

How to do it...

The following commands will give you the possibility to retrieve the statistics information about the public folder structure:

Get-Mailbox –PublicFolder | Get-MailboxStatistics | ft `
DisplayName,TotalItemSize -AutoSize
Get-PublicFolderStatistics | ft `
Name,ItemCount,TotalItemSize,TotalDeletedItemSize,FolderPath,`
MailboxOwnerId -AutoSize
Get-Mailbox –PublicFolder | Get-MailboxStatistics | Select `
DisplayName,TotalItemSize | Export-CSV C:\pf_hierarchy.csv -Notype
Get-PublicFolderStatistics | Select `
Name,ItemCount,TotalItemSize,TotalDeletedItemSize...