sharepoint service instance start stop stuck

How to manage sharepoint service instance using powershell ? You can manage service instance in like starting service instance, stopping service instance. If sharepoint service stuck unprovisioning or provisioning, you have to use powershell to resolve the error. You can remove delete instance mostly search service instance by getting service instance id or using get-spserviceinstance by name powershell command. Status of serivice instance will change to disabled or online after running powershell. you can unprovision duplicate service instances by identifying instance id using powershell.

Advertisements

Run below powershell command to get all services instances

Get-SPServiceInstance | Sort TypeName
sharepoint service instance id
Advertisements

powershell command to get a specific service instance below

Get-SPServiceInstance -Identity 431394e7-df13-4784-af78-719789210fdc # GUID of User Profile Service
Advertisements

start specific service instance powershell command as below

Start-SPServiceInstance -Identity 431394e7-df13-4784-af78-719789210fdc # GUID of User Profile Service
Advertisements

stop instance in sharepoint using powershell command mentioned below

Stop-SPServiceInstance -Identity 431394e7-df13-4784-af78-719789210fdc # GUID of User Profile Service
Advertisements

provision/start – service instance

you can provision or start service instance running any one of the powershell command mentioned below

Get-SPServiceInstance | Where-Object {$_.TypeName -eq "User Profile Service"} | select Status, Id

Get-SPServiceInstance | Where-Object {$_.Id -eq "431394e7-df13-4784-af78-719789210fdc"} # GUID of User Profile Service

Get-SPServiceInstance | where {$_.Status -eq "online" -and $_.TypeName -eq "User Profile Service" } | Sort TypeName | Format-Table TypeName,Id,Server
Advertisements

unprovision/stop – service instance

you can unprovision or stop sevice instance using any one of the commands below

$srvc = Get-SPServiceInstance “431394e7-df13-4784-af78-719789210fdc” # GUID of User Profile Service
$srvc.Unprovision()

$srvc = Get-SPServiceInstance -Server WIN-56R9D2TBFOB | where-object {$_.TypeName -eq “User Profile Service”}
$srvc.Unprovision()

Get-SPServiceInstance | Where-Object {$_.Id -eq "431394e7-df13-4784-af78-719789210fdc"} | Stop-SPServiceInstance | Format-Table -AutoSize # GUID of User Profile Service

Get-SPServiceInstance -Server WIN-56R9D2TBFOB | where-object {$_.TypeName -eq “User Profile Service”} | Stop-SPServiceInstance -confirm:$false > $null

You can get more details related to service application in sharepoint from the link “Service Applications in SharePoint

Advertisements

Watch the video to get step by step, more in detail

Advertisements



Categories: administration, powershell command, service application in sharepoint, SharePoint 2019, sharepoint server, sharepoint services

Tags: , , , , , , , , , , , , , , , ,

%d