SharePoint 2013 – User Profile Synchronization Service not starting
SharePoint 2013 – User Profile Synchronization Service not starting
After you have restored or moved an existing User Profile Service Application and imported the required MIISSKU encryption key then it can be possible, that your User Profile Synchronization Service won’t start or stucks in status starting.
If you analyze the ULS log you should see an error message like:
ILM Configuration: The miissku.exe process exited with error code -2146893813. Error: .
ILM Configuration: The ValidateMiisEncryptionKey process returned False.
Synchronization database is already initialized. Importing the encryption key for the database into the registryUserProfileApplication.SynchronizeMIIS: Failed to configure MIIS pre database, will attempt during next rerun. Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.Office.Server.Administration.UserProfileApplication.RestoreMiisEncryptionKey(ILMPostSetupConfiguration psc)
at Microsoft.Office.Server.Administration.UserProfileApplication.SetupSynchronizationService(ProfileSynchronizationServiceInstance profileSyncInstance).
The reason for this could be that your User Profile Service Application still uses the old miissku encryption key.
You could try to execute an IISRESET but if this will not solve your problem then please try to run the following code with administrative priveleges.
# User Profile Sync database name $spUpaSyncDbName = "<UPA_SYNC_DB_NAME>" # User Profile Service Application Name $upaName = "<UPA_NAME>" # Stop SharePoint Timer Service Stop-Service -Name SPTimerV4 # Get and unprovision the User Profile Sync database $syncDb = Get-SPDatabase | where { $_.Name -eq $spUpaSyncDbName } $syncDb.Unprovision() $syncDb.Status = "Offline" # Get the User Profile Service Application and reset synchronization states $ups = Get-SPServiceApplication | where { $_.DisplayName -eq $upaName } $ups.ResetSynchronizationMachine() $ups.ResetSynchronizationDatabase() # Provision the User Profile Sync database $syncDb.Provision() # Start SharePoint Timer Service Start-Service -Name SPTimerV4
If you now try to start the User Profile Synchronization Service again then it should start.