How to configure a Dedicated Web Front End for crawling in SharePoint 2010
Moved from https://blogs.msdn.com/vijgang
Applies to SharePoint 2010
In SharePoint 2007 (MOSS v3) we have an option in the Office Server Search User Interface to configure a specific Web Front End as the server to be used for crawling. This functionality is very useful as it allows us to have a dedicated WFE for crawling as that ensures the crawling load is not distributed across the entire farm. Usually the indexer is configured with the Web Application services and is dedicated for crawling and then, this server is removed from the NLB .
Screen shot from SharePoint 2007
This option in SharePoint 2010 has been removed from the UI and is part of Powershell functionality. So how do you go about doing this? Here goes,
########## Start of Script to Configure a Dedicated Web Frontend in SharePoint 2010 ##########
$listOfUri = new-object System.Collections.Generic.List[System.Uri](1)
$zoneUrl = [Microsoft.SharePoint.Administration.SPUrlZone]'Default'
$webAppUrl = "Your Default Zone FQDN URL"
$webApp = Get-SPWebApplication -Identity $webAppUrl
$webApp.SiteDataServers.Remove($zoneUrl) ## By default this has no items to remove
$listOfUri.Add("Your Dedicated WFE Server URL");
$webApp.SiteDataServers.Add($zoneUrl, $listOfUri);
$WebApp.Update()
########## End of Script to Configure a Dedicated Web Frontend in SharePoint 2010 ##########
Now you might have a requirement to roll back this change, which means change the setting back to “Use all web front end computers for crawling”. The script for doing that is as follows,
########## Start of Script to reset Dedicated Web Front end crawling settings to default in SharePoint 2010 ##########
$zoneUrl = [Microsoft.SharePoint.Administration.SPUrlZone]'Default'
$webAppUrl = " Your Default Zone FQDN URL "
$webApp = Get-SPWebApplication -Identity $webAppUrl
$webApp.SiteDataServers.Remove($zoneUrl);
$WebApp.Update()
########## End of Script to reset Dedicated Web Front end crawling settings to default in SharePoint 2010 ##########
Comments
Anonymous
April 28, 2012
Hello Spses. My name is Marco and I would like to know what I need to set here: $webAppUrl = "Your Default Zone FQDN URL" # could you give some sample here? ... $listOfUri.Add("Your Dedicated WFE Server URL"); # could you give some sample here? Thank you for this help, and congrats for this article! MarcoAnonymous
February 07, 2018
Great solution in some environments!