Missing User Profile Synchronization Service

I ran into an issue where I was missing the User Profile Synchronization Service from one of my SharePoint servers in the farm. I could see all other services (e.g. User Profile Service), but running a Get-SPServiceInstance -Server SPServer did not display the User Profile Synchronization Service, nor did Central Administration -> Services on Server.

To resolve this particular issue, just run:

Install-SPService

Trevor Seward is a Microsoft Office Apps and Services MVP who specializes in SharePoint Server administration, hybrid scenarios, and SharePoint Online. He has been working with SharePoint for 16 years from SharePoint 2003 on up, managing environments with terabytes of content for 150,000+ user organizations. Trevor is an author of Deploying SharePoint 2016 and Deploying SharePoint 2019. You can find him on Twitter and in /r/sharepoint.