Solved

Exchange power shell 2010 - emptying deleted items folder

Posted on 2013-11-18
5
4,503 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
  • 2
  • 2
5 Comments
 
LVL 13

Expert Comment

by:imkottees
Comment Utility
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
Comment Utility
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 38

Accepted Solution

by:
Adam Brown earned 500 total points
Comment Utility
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
Comment Utility
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 38

Expert Comment

by:Adam Brown
Comment Utility
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

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Follow this checklist to learn more about the 15 things you should never include in an email signature from personal quotes, animated gifs and out-of-date marketing content.
Scam emails are a huge burden for many businesses. Spotting one is not always easy. Follow our tips to identify if an email you receive is a scam.
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 tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles to another domain controller. Log onto the new domain controller with a user account t…

763 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

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now