Steps
  1. Open your SharePoint Management Shell.
  2. Copy the code given below and paste it there.
  3. Run the code given below to delete SharePoint search component.
Code
  1. $SearchServiceApplication = Get-SPEnterpriseSearchServiceApplication -Identity "Search Service Application"
  2. #Get the Local SharePoint sites content source
  3. $ContentSource = $SearchServiceApplication | Get-SPEnterpriseSearchCrawlContentSource -Identity "CustomCrwalComponent"
  4. #Check if Crawler is not already running or Idle
  5. if($ContentSource.CrawlState -eq "Idle")
  6. {
  7. Write-Host "Incremental/Full Crawl Starts..."
  8. }
  9. else
  10. {
  11. $ContentSource.StopCrawl()
  12. }
Thanks for reading this blog.