sp_cycle_agent_errorlog (Transact-SQL)
SQL Server 2005
Closes the current SQL Server Agent error log file and cycles the SQL Server Agent error log extension numbers just like a server restart. The new SQL Server Agent error log contains a line indicating that the new log has been created.
Every time SQL Server Agent is started, the current SQL Server Agent error log is renamed to SQLAgent.1; SQLAgent.1 becomes SQLAgent.2, SQLAgent.2 becomes SQLAgent.3, and so on. sp_cycle_agent_errorlog enables you to cycle the error log files without stopping and starting the server.
This stored procedure must be run from the msdb database.
