Topology provisioning failed due to an error

When modifying your search topology, you might end up getting an error like this:

Errors were encountered during the configuration of the Search Service

Application.Microsoft.Office.Server.Search.Administration.SearchConfigWizard+SearchConfigWizardException:
Topology provisioning failed due to an error.Search Service Instance provisioning failed on SHAREPOINT. at
Microsoft.Office.Server.Search.Administration.SearchConfigWizard.WaitForTopologyTimerJobToFinish() at
Microsoft.Office.Server.Search.Administration.SearchConfigWizard.UpdateSearchApp() at
Microsoft.Office.Server.Search.Administration.SearchConfigWizard.ProvisionSearchServiceApplication() at
Microsoft.Office.Server.Search.Administration.SearchConfigurationJobDefinition.ExecuteTimerJob()
1/19/2012 4:39:02 PM

After this error occurs, the SharePoint Server Search service is on status “Error Starting”:

sharepointserversearcherrorstarting

For some reason, there’s a permission mismatch which occurs on the target server. It’s quite easy to fix actually, by manually starting the service using PowerShell. Firstly rdp to the server where the error happened and fire up the SharePoint 2010 Management Shell. The following 2 lines will start the service:

$si = Get-SPEnterpriseSearchServiceInstance -local
$si.Provision()

After the service is started, you may rerun the topology modification which will succeed for that particular server. Make sure, if you’re using a multiserver farm, that you run the PowerShell command on each server which is targeted in the search topology modification.

Using crawl rules to hide list view names

One of the things SharePoint search does, is showing almost everything it finds. Even names of views.

For instance you create a new view, named NewView, and when you search for “new” or “view”, SharePoint will return you http://sharepoint/lib/Forms/NewView.aspx in the search results. Do I want that? Hm, no it’s not really relevant to the search I’m making.

A solution to this problem is using crawl rules to exclude the /Forms/ bit. By adding *://*/Forms/* to the crawl exclude rule, nothing was crawled anymore. Strange. A quick test showed me that changing the rule to *://*/Forms/*.aspx made my search results appear again. Make sure to run a full crawl after you change any crawl rule to apply its effect.