Exchange Powershell Exchange and Powershell Helps, Tips, and Tricks

Archive for the ‘Exchange’ Category

List Members of a Dynamic Distribution List

07.12.2010 · Posted in Exchange, GAL - Global Address List

This post was inspired by a post found on www.howexchangeworks.com But I have modified the commands some to get a better listing. $group = Get-DynamicDistributionGroup –identity “AllStaff” Get-Recipient –RecipientPreviewFilter $group.RecipientFilter | sort name | select name > d:\_temp\dlist_members.txt These changes will give you an alphabetical list of members, with names only in the list. I ...

Exchange – Cannot remove ACE on object … because it is not present.

06.03.2010 · Posted in Exchange, PowerShell V2

I have run into a problem while doing some routine maintenance on some shared mailboxes for the company I work for. During the maintenance process, we audit the list of users that have full mailbox rights to any shared mailbox. In the process, I was trying to remove full permissions from several user accounts. Here ...

Delete all messages after date from mailbox

11.24.2009 · Posted in Exchange, Powershell

I was asked to delete everything from a mailbox called familydomains that was older than 2009. Here is the Exchange Powershell command that I used to delete everything earlier than 12/31/2008 to a PST file located in my C:\temp directory. export-mailbox familydomains -PSTFolderPath C:\temp\ -DeleteContent -endDate 12/31/2008 The advantage to doing it this way is ...

Command to list all messages to a specific domain for the day

11.20.2009 · Posted in Exchange, Powershell

If you want to list all of the messages sent to a recipient with a specific domain, you can run this command. It will export a list of all message from 8:00AM – 5:00PM on 10/17/2009 that were to someone on the domainname.com domain. The list will be saved to c:\send.xls get-transportserver | Get-MessageTrackingLog -ResultSize ...