May 2013
Intermediate to advanced
504 pages
12h 2m
English
If you support a large Exchange environment, it's likely that users come and go frequently. In this case, it's quite possible over time that you will end up with multiple unused mailboxes. In this recipe, you will learn a couple of techniques used when searching for inactive mailboxes with the Exchange Management Shell.
The following command will retrieve a list of mailboxes that have not been logged on to in over 90 days:
$mailboxes = Get-Mailbox -ResultSize Unlimited $mailboxes | ?{ (Get-MailboxStatistics $_).LastLogonTime -and ` (Get-MailboxStatistics $_).LastLogonTime -le ` (Get-Date).AddDays(-90) }
You can see here that we're retrieving all of the mailboxes in the organization using ...
Read now
Unlock full access