Monday, August 13, 2012

How To Fix Unable to Move Sites Due to the “Drop Off Library” Error

Problem

You can’t delete the Drop Off Library even after you disable the Content Organizer feature.

Solution

Use powershell to disable the Content Organizer feature, allow deletion of the Drop off Library, and then delete the Drop Off Library.

Do not run this script without careful testing in a lab!!!


$url = "http://sharepointsite"

$feature = Get-SPFeature "DocumentRouting"

Write-Host "Feature ID for Content Organizer is called "$feature.DisplayName

$site = New-Object Microsoft.SharePoint.SPSite($url)

foreach ($web in $site.AllWebs)

{

Write-Host "Subsite: " $web.Title

if ($web.Features[$feature.ID])

{

Write-Host "        -Feature" $feature.DisplayName "Found in " $web.Title

Disable-SPFeature $feature -Url $web.Url -Force -Confirm:$false

Write-Host "        -Feature" $feature.DisplayName "Disabled"

}

$list = $web.Lists["DROP OFF LIBRARY"]

if (!$list)

{

Write-Host "        -Drop Off Library not found";

}

else

{

Write-Host "        -"$list " was found in web" $web

$list.AllowDeletion = $true;

$list.Update()

$list.Delete()

Write-Host "        -"$list " Deleted"

}

}

No comments:

Post a Comment