exchange2007使用PowerShell检查邮箱满的用户

exchange的邮箱如果满了,则无法收到邮件,甚至导致邮箱无法打开。于是做了一个Powershell,来导出所有的列表。

1 $strPath = "d:\Script\mailfulldetect\result.txt"
2 
3 Add-PSSnapin Microsoft.Exchange.Management.PowerShell.Admin
4 Get-Mailbox  -OrganizationalUnit "corp.test.com.cn/department" | % { Get-MailboxStatistics -Identity $_.Alias } | ? {$_.StorageLimitStatus -ne "BelowLimit"} | select DisplayName,StorageLimitStatus | Out-File -FilePath $strPath 

在PS上使用exchange的命令提示符,需要先运行:Add-PSSnapin Microsoft.Exchange.Management.PowerShell.Admin
筛选OU使用Get-Mailbox,筛选邮箱是否已满使用Get-MailboxStatistics。

原文地址:https://www.cnblogs.com/zhaofei2013/p/2954388.html