The root of all crawlingIt's a simple cmdlet, Set-SPEnterpriseSearchCrawlContentSource, taking a reference to the search application, the access protocol and the content source. The latter will be identified using its name. Here's the code:
$SearchApp = Get-SPEnterpriseSearchServiceApplication $StartAddresses = "protocol1://localhost/?entity=sheep,protocol1://localhost/?entity=bird,protocol1://localhost/?entity=fish" Set-SPEnterpriseSearchCrawlContentSource -SearchApplication $SearchApp -Identity "Content Source Name" –StartAddresses $StartAddresses -CustomProtocol "protocol1"Above code sets three start addresses for a single content source:
Accessing a content source's propertiesIf you want to modify a content source to e.g. add start addresses instead of replacing them all you have to get the content source. Get-SPEnterpriseSearchCrawlContentSource ist the cmdlet to use:
$SearchApp = Get-SPEnterpriseSearchServiceApplication $ContentSource = Get-SPEnterpriseSearchCrawlContentSource -SearchApplication $searchapp "Content Source Name"The collection $ContentSource.StartAddresses contains all currently configured addresses. Combine them with yours and use the first script to update the configuration.