Unless otherwise specified in this document, only SharePoint 2007 is used, and all other parts are SharePoint 2010.
Recycle Bin Mechanism
Normally, the recycle bin mechanism is helpful to prevent permanent deletion and accidental deletion of content.
PassEnd user Recycle Bin items)You can retrieve the deleted project without the Administrator's intervention. For example, restoring a backup file.
TIPS: click "Recycle Bin" and enter javascript: emptyItems () in the address bar of the browser ();
Note: In 07, you can use the clear recycle bin for one-time operation.
PassThe second Recycle Bin (Delete from end user Recycle Bin items ),You can also provide users with a step by step, which requires the Administrator to perform operations and make reasonable planning.
First, you need to properly plan the storage space for enabling the second recycle bin. At least 20% of the first recycle bin space is allocated to the Second recycle bin. That is to say, if the space of the first recycle bin is 10 Gb, the space of the second recycle bin is preferably 2 GB.
Second, when the dual recycle bin mechanism is enabled, the automatic clearing Mechanism is also enabled.
In addition, the system also has a default automatic overwrite policy for the second recycle bin. That is, when the space of the second Recycle Bin has reached its maximum capacity, the newly added file will overwrite the old file. This is different from the first recycle bin. If the first recycle bin is full, the system will not automatically overwrite it. Instead, it will remind you that the space is full. In this case, you can manually clear the disk space to accommodate new files.
The recycle bin should do the following in routine website maintenance:
First, it is best to use the recycle bin mechanism. Second, it is recommended that the website content be automatically archived before the website is automatically deleted.
Check the recycle bin cleanup task (SharePoint 2007)
Note: SharePoint 2010 is awaiting confirmation.
Timer job The job-recycle-bin-cleanup job is configured to run from 6 to every day. We can use the stsadm.exe command to view:
Stsadm-o getproperty-pn job-recycle-bin-cleanup-url http: // moss
The output value is:
<Property Exist = "Yes" Value = "daily between 22:00:00 and 06:00:00"/>
How to clear the second Recycle Bin (Delete from end user Recycle Bin items)
By default, only the Delete Selection function is supported. A maximum of 200 data records can be deleted on a single page. Usually the data here will expand rapidly, and we usually use the SharePoint object model to write a small program. The most efficient way is to use Power Shell.
param([string]$Url, [switch]$help)[void][System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint")function GetHelp() {$HelpText = @"DESCRIPTION:NAME: Remove-SPSiteSecondStageRecycleBinEmpties the second-stage recycle bin for a Microsoft.SharePoint.SPSite CollectionPARAMETERS: -url Url to SharePoint Site CollectionSYNTAX:Remove-SPSiteSecondStageRecycleBin -url http://mossEmpties the second stage recycle bin for the SiteCollection.Remove-SPSiteSecondStageRecycleBin -helpDisplays the help topic for the script"@$HelpText}function Remove-SPSiteSecondStageRecycleBin([string]$url) { $siteCollection = New-Object Microsoft.SharePoint.SPSite($url); $recycleQuery = New-Object Microsoft.SharePoint.SPRecycleBinQuery; $recycleQuery.ItemState = [Microsoft.SharePoint.SPRecycleBinItemState]::SecondStageRecycleBin; $recycleQuery.OrderBy = [Microsoft.SharePoint.SPRecycleBinOrderBy]::Default; $recycledItems = $siteCollection.GetRecycleBinItems($recycleQuery); $count = $recycledItems.Count; for($i = 0; $i -lt $count; $i++) { $g = New-Object System.Guid($recycledItems[$i].ID); $recycledItems.Delete($g); } $siteCollection.Dispose()}if($help) { GetHelp; Continue }if($url) { Remove-SPSiteSecondStageRecycleBin -url $url }