SQL Server :- Trace Flags and Upgrades

Background In the last couple of weeks one of our customers complained about a downed database. Reviewed the SQL Server Error Log and noticed a few things. Error Log Error Log - Trace Flag - 1117 Image Textual Error Log - Trace Flag - 1118 Image Textual Resolution To resolve the error, be sure to … Continue reading SQL Server :- Trace Flags and Upgrades

SQL Server – Number of Error Log Files

  Background Trying to review error logs on one of our SQL Server Instances and discovered that it is likely that the error logs we might have to mine is so far back and we might no longer have it. And, so took to see if we have properly calibrated the Number of Error Logs Files … Continue reading SQL Server – Number of Error Log Files

SQL Server – Reading Instance Configuration saved in Registry

Background For a script that I am working on, I need to access System Properties such as the base folder of the errorlog.   SQL Server Management Studio ( SSMS ) Of course the information is available via SSMS, just click on the Server's Property and you will see something like this...   Explanation We … Continue reading SQL Server – Reading Instance Configuration saved in Registry

SQL Server – Error Log – Parsing – FindStr

Background A need to parse all available SQL Server Error Logs for a SQL Server Instance and find I/O issues. Code Stored Procedure - dbo.sp_errorLog_findstr Sample Output   Explanation Part of the problem in our case is that all files are using our system drive ( Drive C:)   Source Code Repository GitHub Placed here … Continue reading SQL Server – Error Log – Parsing – FindStr

Microsoft – SQL Server – Error – Error: 17066, Severity: 16, State: 1 // SQL Server Assertion: File: cxrowset.cpp, line=1538 Failed Assertion = ‘pXacc–>FHasVirtualColumn()’. This error may be timing-related

We started getting this "error - Error: 17066, Severity: 16, State: 1:" Due to its severity level 16 and SQL Server's suggested remediation steps: Run DBCC CheckDB (to check database for structural integrity) Restart the server (to ensure in-memory data structures are not corrupted) .... I am thinking I am in for long nights...and not … Continue reading Microsoft – SQL Server – Error – Error: 17066, Severity: 16, State: 1 // SQL Server Assertion: File: cxrowset.cpp, line=1538 Failed Assertion = ‘pXacc–>FHasVirtualColumn()’. This error may be timing-related

Microsoft – SQL Server – Cannot open user default database – Error 4064

Microsoft - SQL Server - Cannot open user default database - Error 4064 Since I already googled for this problem in the past, I already know what to do. Syntax: use <db-name> exec sp_change_users_login 'report' Sample: use [HRSales] exec sp_change_users_login 'report' Result of running sp_change_users_login: So the obvious next step is to align the user … Continue reading Microsoft – SQL Server – Cannot open user default database – Error 4064

Microsoft – SQLServer – ErrorLog File – Grooming

Microsoft - SQLServer - ErrorLog File - Grooming MS SQL Server ErrorLog files can grow for various reasons: Resource Issues - Particularly Low Storage TraceFlag Configuration Frequent backup, particularly frequent transaction backups which are logged as informational enytries There are many other reasons.  But, what to do when your error log file has grown to … Continue reading Microsoft – SQLServer – ErrorLog File – Grooming