Delete specific email from all mailboxes

MXS 2013

Would like to be able to delete specific email from entire organization.

Email with malware, confidential email that was sent wrong or just junk removal.

Maybe search with subject or attachment name.

July 29th, 2015 12:53pm

This would help you...

Search and delete messages - https://technet.microsoft.com/en-us/library/Ff459253(v=EXCHG.150).aspx

Free Windows Admin Tool Kit Click here and download it now
July 29th, 2015 1:18pm

Great info from Amit and if you are interested in a 3rd party solution check out DigiScope which provides an intuitive GUI and the ability to search for all sorts of parameters, i.e. subject, words/phrases in body, with without attachments, sent, receive date etc and you can then tell it to Delete or Purge as soon as an item is found OR to export to MSG or PST before deleting/purging
July 29th, 2015 2:47pm

I get error below:

[PS] C:\>Search-Mailbox -Identity "receptionist" -SearchQuery 'Subject:"car wash"' -DeleteContent
A parameter cannot be found that matches parameter name 'DeleteContent'.
    + CategoryInfo          : InvalidArgument: (:) [Search-Mailbox], ParameterBindingException
    + FullyQualifiedErrorId : NamedParameterNotFound,Search-Mailbox
    + PSComputerName        :

Free Windows Admin Tool Kit Click here and download it now
July 29th, 2015 3:27pm

Make sure you have proper permission mentioned in the article....

  • You need to be assigned the following management roles to search for and delete messages in users' mailboxes:

    • Mailbox Search   This role allows you to search for messages across multiple mailboxes in your organization. Administrators aren't assigned this role by default. To assign yourself this role so that you can search mailboxes, add yourself as a member of the Discovery Management role group. See Assign eDiscovery permissions in Exchange.

    • Mailbox Import Export   This role allows you to delete messages from a user's mailbox. By default, this role isn't assigned to any role group. To delete messages from users' mailboxes, you can add the Mailbox Import Export role to the Organization Management role group. For more information, see the "Add a role to a role group" section in Manage role groups .

July 29th, 2015 5:11pm

Yes, added administrator as member of Discovery Management roles.

Also added Mailbox Import Export role to Org Mgmt role group
Free Windows Admin Tool Kit Click here and download it now
July 29th, 2015 5:51pm


Also added Mailbox Import Export role to Org Mgmt role group

I believe this is what you mean by adding mailbox import export role to org mgmt role group...

new-ManagementRoleAssignment -Role "Mailbox Import Export" -SecurityGroup "Organization Management"

Did you reopen the Exchange Management Shell after this?

July 29th, 2015 6:04pm

yep, u r right. I just didn't re-open the shell after the changes.

Thank you very much!!!!

Free Windows Admin Tool Kit Click here and download it now
July 29th, 2015 6:15pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics