powershell recover deleted items RRS feed

  • Question

  • Is there a way to use powershell to clear the "Recover Deleted Items" ? Or Make the "Recover Deleted Items" do not recover message any more?

    Thursday, May 5, 2011 7:03 AM

All replies

  • Hi,

    To disable "Recover Deleted Items" for single user:

    Set-Mailbox User1 -RetainDeletedItemsFor 0.00:00:00 -RetainDeletedItemsUntilBackup $false -UseDatabaseRetentionDefaults $false

    To disable "Recover Deleted Items" for all user in a database

    Set-MailboxDatabase 'Database-01' -DeletedItemRetention 0.00:00:00 -RetainDeletedItemsUntilBackup $false 

    Adam Bokiniec
    Thursday, May 5, 2011 9:07 AM
  • Agree with Adam

    Check out this article, this will help


    Gulab | MCTS-MCITP Messaging: 2010 | MCTS-MCITP Messaging: 2007 | MCC 2011 | Skype: Gulab.Mallah
    Thursday, May 5, 2011 9:13 AM
  • Hi Catherine,

    Any updates?

    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
    Monday, May 9, 2011 6:02 AM
  • Sorry for late update.

    Set Delete Items Retention is a helpful way to disable "Recover Deleted Items" ,Thanks Adam.

    But because I use powetshell to import PST file to Exchange , so set Delete Items Retention is not work for this kind of message.

    I found a way to clean up "recoverable items folder" :

    Search-Mailbox -Identity "Administrator" -SearchDumpsterOnly -TargetMailbox "Discovery Search Mailbox" -TargetFolder "Administrator-RecoverableItems" -DeleteContent

    But it just for Exchange 2010.

    So for Exchange 2007, how to clean uo "recoverable items folder" ?

    Tuesday, May 10, 2011 3:24 AM