Failed to read from or write to database SharePoint
Check out Best Alternative to InfoPath -> Try Now
This SharePoint tutorial explains, how to solve an error, Failed to read from or write to database. Refresh and try again. which comes in SharePoint 2013/2016
One fine day, I got an email from your customer stating that he/she is unable to add hashtags (Eg: #MSIgnite) in the SharePoint OOB Newsfeed web part added in the intranet homepage. Here is the below error we get once we try to add the Hashtag. The error says:
Something went wrong.
This couldn’t be posted because we’re having some issues at the moment.
Do you want us to retry?
SharePoint returned the following error: Failed to read from or write to a database. Refresh and try again. If the problem persists. please contact the administrator. Contact your system administrator for help in resolving this problem.
But once we start troubleshooting we found out that we were able to add the #Hashtags which we have created already but not a new one.
Basically, the hashtags are part of the Managed Metadata Service. So we checked the service in the Central Administration and it was in an online state. We stopped and restarted once again but that didn’t help.
So I decided to take help from the Social tech-community Forums but didn’t get a solution to solve the issue.
After a while, we went to the term store management and checked the hashtag term and tried creating a new hashtag through GUI, we got the below error. The same error we got while trying to add/delete terms in any group in the Term Store.
Now as per the error statement, the issue seems like there is something wrong in the database. Open the Web Front End Server check if the Managed Metadata Service Database is Read and Write Enabled.
This piece of PowerShell helps in getting the Database Info of the Managed Metadata Service.
$mms = Get-SPServiceApplication -Name Managed_Metadata_Service $mms.Database.Name $mms.Database.IsReadOnly
PS C:\Users\sp13_farm> $mms = Get-SPServiceApplication -Name Managed_Metadata_Service
Now it’s time to check the Database Server.
Go to the DB server > Open SQL Server Management Studio > Check the Managed_Metadata_Service_DB
The permissions are fine for the DB. Ok as a first troubleshooting step, we tried creating a table via GUI, we get the below error,
Finally, we identified that the issue is with the Transaction Log File which is actually full.
Go to the Properties of the Database > Click on Files > under the Logfile type check the Initial Size, Auto growth Column which has got exceeded and the auto-growth was restricted which means the DB won’t allow being modified.
We can’t make any changes to the existing configuration for the log file size. We can only add a new log file and map to the DB. Check out this Microsoft Documentation on how to do that.
Once you are done mapping the new transaction log file, the term store management returns back to the normal state.
You may like following SharePoint tutorials:
- The default termstore for this site cannot be identified error in SharePoint 2010
- SharePoint 2019 (SAML) Claims provider for authentication in TermStore has been fixed
- SharePoint cannot complete this action as the Secure Store Shared Service is not responding
- Migrate custom Search Dictionaries Terms SharePoint 2013/2010 to Office 365 SharePoint Online
- Backup and Restore Site collection in SharePoint 2016/2013/2010/2007
- Steps to Create a managed metadata navigation from Term Store in SharePoint Online
- Create a group, term set and term in SharePoint Online Term Store
- Term Store Management in SharePoint Online Office 365 (Step by Step Tutorial)
- Term update failed because of save conflict SharePoint Online
- SharePoint Online: Create term sets and apply as Global Navigation in Sites using PowerShell
This SharePoint tutorial, we learned how to fix an error, failed to read from or write to database. refresh and try again.
SharePoint Online FREE Training
JOIN a FREE SharePoint Video Course (3 Part Video Series)