PSConfig error at step 3 of 4. Cannot upgrade SharePoint database

PSConfig is failing at step 3 of 4, Cannot upgrade SharePoint database. It is failing to upgrade SharePointSearchAdmin database, throwing an Exception: User does not have permission to perform this action

Here is the complete error description found in logs

at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)   

 at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)   

 at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)   

 at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)   

 at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)   

 at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)   

 at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, String methodName, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite)   

 at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()   

 at Microsoft.Office.Server.Data.SqlSession.ExecuteNonQuery(SqlCommand command)   

 at Microsoft.Office.Server.Data.SqlDatabaseManager.GrantAccess(String user)   

 at Microsoft.Office.Server.Search.Administration.SearchDatabase.GrantAccess(String username, String role)   

 at Microsoft.Office.Server.Search.Administration.SearchDatabase.SynchronizeAccessRules(SearchServiceApplication searchApp)   

 at Microsoft.Office.Server.Search.Administration.SearchServiceApplication.SynchronizeDatabases()   

 at Microsoft.Office.Server.Search.Upgrade.SearchAdminDatabaseSequence.PostUpgrade()   

 at Microsoft.SharePoint.Upgrade.SPUpgradeSession.Upgrade(Object o, Boolean bRecurse)

Farm Admin account has all the permissions configured properly. Search account and all the accounts are also configured properly.

Resolution:

Clearly it is evident from logs that issue is with Search Administration Database. To get past this error, stop the Windows SharePoint Search service through windows services console in all the servers in which search is running.

Then try running PSConfig or configuration wizard. Configuration wizard starts all the services which are supposed to be running after upgrading all the databases and components.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Disable feedback surveys in Power Platform

If you have worked in Microsoft 365 PowerApps or Power Automate, you might be familiar with feedback survey which pops up quite often. Microsoft wants your feedback on how likely are your to recommend Power Automate to a friend or colleague? Well, I ran into a conversation in twitter about this survey. Apparently I learnt […]

Read More

Step by step guide to configure Viva Connections

Update 09/23/2021 – Viva Connections public preview is available now. Steps defined in this article to create an LOB Teams application using PowerShell is not necessary now. Viva Connections app is available in Teams admin center. This new app replaces Step#3 & Step#4 in this article. You still has to go through the home site […]

Read More

Managing global navigation in SharePoint online

Options to manage global navigation in SharePoint online keeps getting better and better. We have come a long way from custom apps, using managed metadata navigation to hub navigation & the shiny SharePoint app bar. SharePoint app bar: SharePoint app bar brings together global navigation and user personalized resources (Sites, News & Files) to every […]

Read More