3

Unknowingly,I have deleted search service application from a SharePoint standalone system.Now there is no option to create new search service application. In new option of Manage Service Application Page there is no entry called search service application.

Please help.

2
  • under which account you login? and could you please share the screen shot fo new service application drop down? try to login with Farm admin account
    – Waqas Sarwar MVP
    Commented Sep 21, 2016 at 13:17
  • i am logging in with farm account. The new drop down has three options other than search service application.
    – Sharanya
    Commented Sep 21, 2016 at 13:29

3 Answers 3

5

as this is foundation so there is no way to create the search service via manage Service Application from Central admin. Only way is using the Config Wizard or you can try below powershell.

#Start the search service instance on the server
Start-SPEnterpriseSearchServiceInstance $env:computername 
Start-SPEnterpriseSearchQueryAndSiteSettingsServiceInstance $env:computername

#Give a unique name to your search service application
$serviceAppName = "MyCleanDB Search Service Application"

#Get the application pools to use (make sure you change the value for your environment) 
$svcPool = Get-SPServiceApplicationPool "SharePoint Web Services Default" 
$adminPool = Get-SPServiceApplicationPool "SharePoint Web Services Default"

#Get the service from the service instance so we can call a method on it
$searchServiceInstance = Get-SPEnterpriseSearchServiceInstance –Local
$searchService = $searchServiceInstance.Service

#Define your unique DB names without the guids
$adminDB = "Search_Service_Application_DB"
$propertyStoreDB = "Search_Service_Application_PropertyStoreDB"
$crawlStoreDB = "Search_Service_Application_CrawlStoreDB"
$analysticsStoreDB = "Search_Service_Application_AnalyticsStoreDB"
$linkStoreDB = "Search_Service_Application_LinkStoreDB"

#Since this method takes in the value of object type Microsoft.SharePoint.Administration.SPDatabaseParameters we will create these from our clean DB names
$adminDBParameters = [Microsoft.SharePoint.Administration.SPDatabaseParameters]::CreateParameters($adminDB,"None")
$propertyDBParameters = [Microsoft.SharePoint.Administration.SPDatabaseParameters]::CreateParameters($propertyStoreDB,"None")
$crawlStoreDBParameters = [Microsoft.SharePoint.Administration.SPDatabaseParameters]::CreateParameters($crawlStoreDB,"None")
$analyticsStoreDBParameters = [Microsoft.SharePoint.Administration.SPDatabaseParameters]::CreateParameters($analysticsStoreDB,"None")
$linkStoreDBParameters = [Microsoft.SharePoint.Administration.SPDatabaseParameters]::CreateParameters($linkStoreDB,"None")

#Create the search service application by calling the function
$searchServiceApp = $searchService.CreateApplication($serviceAppName, $adminDBParameters, $propertyDBParameters, $crawlStoreDBParameters, $analyticsStoreDBParameters, $linkStoreDBParameters, [Microsoft.SharePoint.Administration.SPIisWebServiceApplicationPool]$svcPool, [Microsoft.SharePoint.Administration.SPIisWebServiceApplicationPool]$adminPool)

#Create the search service application proxy as usual (luckily PowerShell for this works and is bot blocked)
$searchProxy = New-SPEnterpriseSearchServiceApplicationProxy -Name "$serviceAppName Proxy" -SearchApplication $searchServiceApp
#Provision the search service application 
$searchServiceApp.Provision()

Once the above code completed sucessfully then run the below to start topology.

#Get an updated handle on the SearchServiceInstance
$searchServiceInstance = Get-SPEnterpriseSearchServiceInstance –Local
#Now we will call the method to initiate the default topology component creation using reflection
$bindings = @("InvokeMethod", "NonPublic", "Instance")
$types = @([Microsoft.Office.Server.Search.Administration.SearchServiceInstance])
$values = @([Microsoft.Office.Server.Search.Administration.SearchServiceInstance]$searchServiceInstance)
$methodInfo = $searchServiceApp.GetType().GetMethod("InitDefaultTopology", $bindings, $null, $types, $null) 
$searchTopology = $methodInfo.Invoke($searchServiceApp, $values)

read more about this on this: Provision Search for SharePoint Foundation 2013 using PowerShell with clean DB names

1
  • Awesome. I am able to create search service application with the above code. Thanks a lot.
    – Sharanya
    Commented Sep 22, 2016 at 6:56
2

It seems that the ONLY way you can add the Search Service to SharePoint Foundation 2013 is by using the SharePoint Configuration Wizard like so (you can’t even do it with PowerShell! ):

enter image description here

Visit the SharePoint Central administration site and select Configuration Wizards from the Quick Launch Menu on the left hand side.

enter image description here

Press the Start the Wizard button.

enter image description here

Select the account you wish to use for this service. It is always better to have one already created than try and create a new one on the fly here.

Scroll down for more options.

enter image description here

If you want just the Search Service Application then uncheck everything else and press the Next button.

enter image description here

SharePoint will bring out the traffic cones briefly while the service is configured.

enter image description here

You’ll then be asked to create a Site Collection, but since one has normally be created previously during the manual creation of SharePoint Foundation 2013, press the Skip button.

enter image description here

You should now see in the summary page that a Search Service Application has been configured. Interestingly, you’ll note that the following additional service have also been configured (even though they were unselected!):

  • Usage and Health Data Collection Service Application

If you press the Finish button and have then have a look at the Service Applications you should see:

enter image description here

Then if you have a look at Services on Server you’ll see:

enter image description here

Where you should now see that the SharePoint Server Search (at the bottom of the screen shot above) is now Started!

All credits to the blog post here

5
  • Hi Ransher, Thanks for ur helpful post. The problem is SharePoint is installed standalone. So i will not have a option for farm configuration wizard.
    – Sharanya
    Commented Sep 21, 2016 at 13:04
  • @User2809 That should not disable it. I have a standalone for Dev and it shows up for me! Commented Sep 21, 2016 at 13:07
  • It shows farm configuration like in first image posted in the answer but the farm configuration option is not available.
    – Sharanya
    Commented Sep 21, 2016 at 13:10
  • Try logging with Farm admin account, use IE to "Run As" ... More help here sharepoint.stackexchange.com/questions/4022/… Commented Sep 21, 2016 at 13:14
  • i tried all the options. i am logging in with farm admin account and also running ie as administrator. if i try the farm wizard's URL directly it says "The farm configuration does not support standalone configuration. use psconfig.exe"
    – Sharanya
    Commented Sep 21, 2016 at 13:28
2

Follow the below steps:

  • Go to Central Administration Home Page
  • Launch the Farm Configuration Wizard
  • Click Start the Wizard
  • If need then add new service account, and select the Search service Application
  • Click Next

It will prompt for new site creation, Click the Cancel button.

Now your Search Service application is created.

1
  • Thanks !! But it is a standalone installation. so there is no option for farm configuration wizard.
    – Sharanya
    Commented Sep 21, 2016 at 13:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.