SharePoint 2010 – Drop Off Library Not Indexed For Searching

After patching our SharePoint 2010 farm to SP1 & the Feb 2013 CU, we noticed that our drop off library was no longer being indexed for searching…. The configured crawls were taking place, but new items were no longer showing in the search results for some reason. Under Library Settings > Advanced Settings > Search we could see that the option “Allow items from this document library to appear in search results?” was set to ‘No’. We turned it back on, ran a crawl & items now appeared again.

Allow items from this document library to appear in search results?

Allow items from this document library to appear in search results?

When the users reported that the issue had recurred, we checked this option & it was set back to ‘No’. So we turned it back to ‘Yes’, and then ran a crawl again. An hour later the same thing happened again. We found this post from P Griffiths which indicated that the Content Organizer Timer Job was affecting this setting…. This tied in perfectly with the behavior we were seeing, as the timer job is running every 30 minutes turning this setting back off.

We couldn’t find much information about this online, but from what we could see this was by design as a Drop Off Library is not meant to be configured to be indexed like this. As the crawls are running every 10 minutes and this job is disabling indexing every 30 minutes, I needed a way of quickly forcing this back on without manual intervention.

We came up with the below solution…. Our SharePoint developer wrote this powershell script:

Add-PSSnapIn Microsoft.SharePoint.PowerShell
$site=Get-SPSite ""
$docLibrary =$web.Lists["Drop Off Library"]
# Change the advanced settings
$docLibrary.NoCrawl = $false;

And then a batch file to call the script:

powershell -file "C:\\scripts\\DropOffCrawl.ps1"

And scheduled as a task to run every 5 minutes on the Web Front End server, forcing the option back on in time for the next crawl each time. Biggles.

This entry was posted in SharePoint and tagged , , , . Bookmark the permalink.

Leave a Reply