Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Exchange power shell 2010 - emptying deleted items folder

Posted on 2013-11-18
5
Medium Priority
?
5,534 Views
Last Modified: 2013-11-19
is there a way or a combination of cmdlets one could use to empty a users deleted folder ?

I have heard of search-mailbox but not seeing much in the help on how to use it.
0
Comment
Question by:jrojas1213
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 13

Expert Comment

by:imkottees
ID: 39657451
Hi,

Here you go:

Search-mailbox -identity <alias> -SearchDumpsterOnly -DeleteContent

http://stevehardie.com/2012/05/exchange-2010-purge-dumpster/
0
 
LVL 1

Author Comment

by:jrojas1213
ID: 39657492
yes I found that and did not work because that is deleting the dumpster which is where it goes after a user empties the deleted folder.  that way when they say oops there is still time to recover it.
0
 
LVL 42

Accepted Solution

by:
Adam Brown earned 2000 total points
ID: 39657812
Search-mailbox can't really be used because you can't use it to return all the results of a specific mailbox folder. Rather, to clear out the deleted Items folder for all or specific users, you would want to make use of the retention policies. Create a retention policy for the Deleted Items folder, set it for a week or a day or however long, and apply it to the user. There is a default retention policy in place that clears the deleted items folder after 30 days, but you have to make sure it's applied and the emails in the deleted items folder are tagged with that policy.
0
 
LVL 1

Author Comment

by:jrojas1213
ID: 39659441
Thanks for the solution acbrown.  I have applied the retention policy and found out that it does not apply the policy according to the mailbox processing which is set in my case to 24 hours.  I have run Start-ManagedFolderAssistant -Identity “Administrator” to force but the policy still has not applied.  does it still take some time even after the force ?
0
 
LVL 42

Expert Comment

by:Adam Brown
ID: 39660734
Existing emails have to be "tagged" with the policy in order to get removed by it. You can do this by opening the mailbox is outlook and right-clicking the folder, then selecting the option to apply the existing retention policy (I think. I don't have a valid test in front of me at the moment. Working off memory).
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After seeing many questions for JRNL_WRAP_ERROR for replication failure, I thought it would be useful to write this article.
The core idea of this article is to make you acquainted with the best way in which you can export Exchange mailbox to PST format.
This tutorial will walk an individual through configuring a drive on a Windows Server 2008 to perform shadow copies in order to quickly recover deleted files and folders. Click on Start and then select Computer to view the available drives on the se…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
Suggested Courses

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question