Recently when I was trying to create a new connection in user profile synchronization connections I got the below error which says:
An error has occurred while accessing the SQL Server database or the SharePoint Server Search service. If this is the first time you have seen this message, try again later. If this problem persists, contact your administrator.
Also read: There was no endpoint listening at http://URL/ResourceManagementService/MEX that could accept the message while add new synchronization connection
The solution what I tried was:
Do an IISRESET in the server. Then it worked correctly.
You can also check the User Profile Synchronization Service should be in started stage. If required also you can restart the service once.
Hope this will be helpful.
Download FREE SharePoint 2019 Installation PDF Guide
This FREE PDF contains, Steps by step guide to install SharePoint 2019 Preview, prerequisites, hardware and software new features. First impression to SharePoint Server 2019 new modern site, modern lists and modern document libraries.