3

One of our jobs failed but the job history had already expired by the time we investigated. We could, however, see that a new log file was created around the time it failed.

There was no instance restart (checked os_sys_info) or agent restart (looked in sys.processes) and nobody using it knows how to cycle the log.

Must it have been a corruption of some kind?

2 Answers 2

5

I would assume it's more likely that the procedure sp_cycle_errorlog was called. There's a possibility someone accidentally right clicked on Error Log and then clicked Recycle instead of Configure which also calls this procedure.

What I would do is create an audit event on this procedure for the future so you can see how this occurs. If you do have some SQL Auditing in place, I'd search the history to see if that procedure was caught in the audit.

Jeremiah Peschka from Brent Ozar on the log recycling.

1
  • I didn't think anyone knew the sp_cycle_errorlog so ruled a manual cycle out. Didn't realise there was an option from the object browser. That is possible.
    – cloudsafe
    Nov 21, 2018 at 8:59
1

Perhaps somebody configured re-cycling based on the size (registry setting)? http://sqlblog.karaszi.com/managing-the-errorlog-file/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.