Are you sure? Last good DBCC CHECKDB over 2 weeks old.

So this past week I had a little confusion over a new CheckID that was suddenly firing every day in sp_Blitz. This new CheckId was number 68, ‘Last good DBCC CHECKDB over 2 weeks old.’ What? How could that be? I run it daily from Ola’s maintenance plans.

My first check was to verify if it was a recent occurrence only:

SELECT *
 FROM dbo.BlitzResults
 WHERE
 CheckID = 68;

Yup, in my history of BlitzResults it had only happened in the past day. So I kept looking since this was something new and weird.

Next check … were there errors in the Agent log for the dbcc script? No, nothing there, even though the agent truncates the script output anyway making that log fairly useless.

Next, check Ola’s log table. Clear. There were no errors in the maintenance plan logs for any DBCC_CHECKDB runs for the unit_test_1 database over its entire history.

SELECT *
 FROM [dbo].[CommandLog]
 WHERE
 CommandType = 'DBCC_CHECKDB' AND
 DatabaseName = 'unit_test_1';

Something was fishy, but was it a red herring?

red herring   https://www.flickr.com/photos/24263322@N05/2403978660

Continue reading “Are you sure? Last good DBCC CHECKDB over 2 weeks old.”