February 29, 2016 at 10:32 am
I am new to SQL Server, and something novel happened this weekend.
So, in SSMS, under SQL Server Agent>>Error Logs, I am used to seeing the Current log be synonymous with the timing of the last instance restart. But this last weekend, one of my instance's did not restart (confirmed by running "exec xp_readerrorlog"), but the current-most reference in this area of SSMS mentions 2/28/2016 9:45am.
What is the relationship between these 10 entries (Current->Archive #9) under Error Logs in SSMS, and occurrences within the instance itself? Since it's not related to an instance restart, and the error log itself didn't actually cycle, I am curious how it happened, and, if it really matters.
Thanks for the help,
--=Chuck
March 9, 2016 at 6:33 am
I'm not quite following your question but there are differences between the Agent Log and the Error Log
The current Agent log file is named SQLAGENT .OUT, archived files are numbered sequentially. SQL Server defaults to 9 archives of the file.
The current error log file is named ERRORLOG. SQL Server defaults to 6 archives of the file.
You can read them in SSMS or find them in the MSSQL\LOG folder.
Are you saying you have an entry in the SQL Agent log but it doesn't coincide with a SQL Server restart? That's ok, what does it say?
March 9, 2016 at 8:33 am
I'm just saying that the current-most SQL Agent log file's ...err ... create date(?) doesn't coincide with the most recent restart of the database instance. Up until now, across all 20 or so servers, they've always been in sync.
And by create-date, I'm referring to the date displayed in SSMS under the SQL Agent>>Error Logs folder, where it says "Current - 2/28/2016 9:45am". This particular server hasn't been restarted since January.
March 9, 2016 at 10:15 am
I think I understand.
I've definitely seen the 'Current - date time' display part be inaccurate, or not what I was expecting. I think it reflects the 'date modified' property of the file when looking at it in explorer but that doesn't seem to be accurate sometimes.
I'm looking at a SQL (not Agent) ErrorLog now which has a 'date modified' of 15 minutes ago but there are entries in the log of 5 minutes ago. And a 'refresh' didn't bring it up to date.
I wouldn't worry about it.
Of course the SQL Agent can be stopped and started without stopping SQL Server but that would cycle the errorlog.
March 9, 2016 at 10:22 am
Ok, thanks. I thought it was probably a non-issue, but it was asynchronous with what all of our other servers were displaying, so I thought I'd check. --=cf
March 9, 2016 at 3:41 pm
As DouglasH mentioned, it could have been a restart of SQL Server Agent or someone may have run sp_cycle_agent_errorlog.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply