The way you have structured your command is incorrect. TargetMailbox
and TargetFolder
specify the destination where search results are copied. This is typically a Discovery Mailbox or similar.
What you have specified will look in the mailbox <username>
copy all content (no query or other criteria is specified) to a mailbox called Inbox
, in a folder called Deleted Items
. Everything in the mailbox <username>
should have been deleted from the source mailbox and copied to the Inbox
mailbox (should it exist, I think this would have thrown an error).
Please review TechNet for Search-Mailbox: https://technet.microsoft.com/en-us/library/dd298173%28v=exchg.160%29.aspx
You will want something like the following:
Search-Mailbox -Identity source.mailbox@domain.com -SearchDumpsterOnly -DeleteContent
Now, I should clarify: This would permanently delete the contents of the Recoverable Items
folder, a hidden system folder where things go AFTER they disappear from Deleted Items
. If Legal Holds are employed, all bets are off and it is entirely possible/likely content could still be discovered, depending on the holds employed.