Recently, I came across a strange issue. I noticed that the SQL Server service terminates and restarts automatically and sometimes doesn’t restart and I must manually start it again. In this blog we would learn about Event ID:7034, MSSQLSERVER Service Terminated Unexpectedly.
I referred a lot of online content and they were asking me to refer ERRORLOG. SQL SERVER – Where is ERRORLOG? Various Ways to Find ERRORLOG Location
There was no symptom of SQL Service getting stopped via an external program in ERRORLOG. Looks like it was simply crashing. I checked the System and Application Event log and found below.
Log Name: Application
Source: Windows Error Reporting
Date: 7/7/2018 1:21:53 PM
Event ID: 1001
Task Category: None
Fault bucket 1181302166329499531, type 4
Event Name: APPCRASH
Response: Not available
Cab Id: 0
These files may be available here:
There was no meaningful information in “C:\ProgramData\Microsoft\Windows\WER\ReportArchive\” folder but there were many folders with name AppCrash_sqlserver.exe. As per Quora, 0xC0000005 is a code for Access Violation error. It means that your program just tried to read or write, in a section of memory that it has no access to. Most likely, this happened due to poor usage of pointers.
I had no clue why there was a crash of SQL Service. As per internet reading, the SQL server process might terminate unexpectedly for several reasons.
- Incorrect program configuration
- System memory problems
- Improper license information
- Missing program files
- Corrupt user data
- Severe disk fragmentation.
Once I performed a clean restart of the server, the error didn’t come back again. I am sure it was some rogue process running on the server which got cleared after restart or it might have been some memory corruption. If it comes back again, I think I should report to Microsoft. What do you think? Have you seen this error earlier?
Reference: Pinal Dave (http://blog.SQLAuthority.com)