From d54c6a69364069cc629d4f5220578022e181ebd2 Mon Sep 17 00:00:00 2001 From: Martien Date: Fri, 13 Jun 2025 11:33:05 +0200 Subject: [PATCH] Add Exchange/Get-LargeMailboxes.ps1 --- Exchange/Get-LargeMailboxes.ps1 | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 Exchange/Get-LargeMailboxes.ps1 diff --git a/Exchange/Get-LargeMailboxes.ps1 b/Exchange/Get-LargeMailboxes.ps1 new file mode 100644 index 0000000..e56623e --- /dev/null +++ b/Exchange/Get-LargeMailboxes.ps1 @@ -0,0 +1,4 @@ +#Find mailboxes that are larger than 100GB (for migrating to exchange online) +Get-Mailbox -ResultSize Unlimited | Get-MailboxStatistics | Where-Object { + [int64]($_.TotalItemSize.Value.ToBytes()) -gt 100GB +} | Select DisplayName, @{Name="SizeGB";Expression={"{0:N2}" -f ($_.TotalItemSize.Value.ToBytes()/1GB)}}