Cycle The SQL Server Error Log
From Wiki
When you do a SQL Server restart SQL server closes the current error log file and cycles the error log extension numbers. Every time SQL Server is started, the current error log is renamed to errorlog.1; errorlog.1 becomes errorlog.2, errorlog.2 becomes errorlog.3
What if you don't restart the SQL Server" Your log file can become huge. What can you do? You can run the sp_cycle_errorlog stored proc
- EXEC SP_CYCLE_ERRORLOG
sp_cycle_errorlog closes the current error log file and cycles the error log extension numbers just like a server restart. The new error log contains version and copyright information and a line indicating that the new log has been created.
Permissions: Execute permissions for sp_cycle_errorlog are restricted to members of the sysadmin fixed server role.
Contributed by: --SQLDenis 16:07, 10 June 2008 (GMT)
Part of SQL Server Admin Hacks


