Wading Through

Entries from June 2008

2nd Stage Recycle Bin Fallacy

June 12, 2008 · 3 Comments

In the SharePoint community, I regularly hear a statement made that I myself use to believe was correct but I want to clear up the misconception. It is easy to understand why people believe this based on unclear wording in Central Administration.

The statement is made that if you do not set site quotas for the site collection, then your second stage (site collection) recycle bin will never be emptied because the second stage recycle bin is based on a percentage of the site quota. Therefore, your second stage recycle bin can grow uncontrollably because it will never be emptied. This reasoning is incorrect because it is based on some misinformation.

So lets clear up how the recycle bin works including the second stage. I will first explain how it works. Then link to documentation and provide tips if you wish to test this statement yourself.

In Central Admin, you can state the numbers of days items are to be retained in the Recycle Bin. The first stage and the second stage (site collection) are BOTH part of the Recycle Bin. Therefore, items in either the first stage OR the second stage will be deleted after the number of days set for the web application. However, an additional size limit can be placed on the second stage recycle bin by using a percentage of the site collection quota to limit it.

Therefore, I am still recommending that you set site quotas. Without site quotas, there is nothing to stop your second stage recycle bin from growing uncontrolled and increasing the size of your content database on the SQL server.

But you might say, if it is only there for 30 days (the default), why would I worry? Imagine you have many large documents libraries in the same site collection. Then, you have multiple users all decided to do cleanup in those libraries (deleting many files) and empty their recycle bins. Then, they add new documents to the libraries to “update” them. Then, a week later, they do it again. There is still the possibillity of your content database growing larger than you would want to manage or have space on your SQL server to hold.

So I have tested this scenario and I have confirmed on numerous client sites that there are no files in their second stage recycle bins older than the day limit placed on the recycle bin as a whole. If you read this Microsoft article, you will find following statement in the last sentence of the Overview:

Regardless of whether or not an item is sent to the users’ Recycle Bin or to the Site Collection Recycle Bin, items are deleted automatically after the number of days that the central administrator specified. 

If you wish to test this yourself, please be aware that in order for items to be emptied from the recycle bin, the Timer Job “Recycle Bin” has to have run. By default, this timer job only runs once per day usually early in the morning. I would recommend you use the stsadm -o setproperty -propertyname job-recycle-bin-cleanup command to set the job to run more frequently while testing.

Categories: Microsoft Office Sharepoint Server
Tagged: , ,