SharePoint 2010/2013 - Security Patch Updates

Introduction
 
Recently we have completed security patch updates for SharePoint 2010/2013. I just wanted to share these issues we received during recent security patch updates which may help someone if they get the same issue or can plan upgrade activity by taking below notes to avoid issues during an upgrade. After installing required patches when started “PSConfig” wizard, it got failed with some errors.
 
After some investigation, we found the reason for the errors. After taking the necessary actions, the “PSConfig” wizard started again.
 
Below are the few errors we got:
 
Issue 1: An update conflict has occurred, and you must re-try this action
 
Issue Details: Below are the error details found in ULS logs
 
[OWSTIMER] [SPUpgradeSession] [ERROR]: Upgrade Timer job is exiting due to exception:
Microsoft.SharePoint.Administration.SPUpdatedConcurrencyException: An update conflict has occurred, and you must re-try this action. The object SPWebApplication Name= was updated by user, in the w3wp process, on machine View the tracing log for more information about the conflict.
at Microsoft.SharePoint.Administration.SPConfigurationDatabase.StoreObject(SPPersistedObject obj, Boolean storeClassIfNecessary, Boolean ensure)
at Microsoft.SharePoint.Administration.SPConfigurationDatabase.Microsoft.SharePoint.Administration.
ISPPersistedStoreProvider.PutObject(SPPersistedObject persistedObject, Boolean ensure)
at Microsoft.SharePoint.Administration.SPPersistedObject.BaseUpdate()
 
Solution: After some investigation, we found that one of the script (scheduled) was running and trying to make updates into the SharePoint environment which lead to save/update conflicts. So it is recommended that we stop all the jobs/tasks which are updating the data in SharePoint environment.
 
Issue 2: Operation cannot be performed on the database because it is involved in a database mirroring session or an availability group
 
Issue Details: Below are the error details found in ULS logs
[OWSTIMER] [SPUpgradeSession]: SPUsageDatabase Name="DBName"
[OWSTIMER] [SPUpgradeSession] [ERROR]: Exception: The operation cannot be performed on database "DBName" because it is involved in a database mirroring session or an availability group. Some operations are not allowed on a database that is participating in a database mirroring session or in an availability group.
ALTER DATABASE statement failed.
 
Solution: One of the SharePoint databases was added in Always On availability group (AAG) in the SQL server. Make sure before running “PSConfig” wizard, if we have any SharePoint DB that is part of AAG then it is been removed. Once the upgrade activity completed, we can add it back.
 
To know more about AAG click here.
 
I hope this helps someone. Thanks for reading...