zoukankan      html  css  js  c++  java
  • 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。

  • 相关阅读:
    Python_堡垒机开发基础
    用haslib给字符加密
    python学习(集合)
    编码
    小练习03
    python学习(字典)
    小练习02
    python学习(列表,元祖)
    小练习
    python学习
  • 原文地址:https://www.cnblogs.com/zhaofei2013/p/2954388.html
Copyright © 2011-2022 走看看