Moving the SQLAGENT.OUT file

  • Is there a way to move the SQLAGENT.OUT without restarting?

  • this command moves the location of the file

    USE msdb

    GO

    EXEC msdb.dbo.sp_set_sqlagent_properties @errorlog_file=N''new path\SQLAGENT.OUT'

    GO

    Sqlagent will need restarting to write to this new location though. what's the problem with restarting the agent?

    ---------------------------------------------------------------------

  • I had to move the system databases and log files to free up a directory last night. The error logs and sqlagent.out were on the same directory as the databases, but I thought changing the dump file location for the SQLSERVER service, would change the location of the error log and SQLAGENT.OUT, but it didn't.

    So I was trying to find a way to move it without another downtime.

  • sorry, no can do, but a restart of just SQLAgent should not affect the app.

    move the errorlog via the startup parameters in config manager, that will require a SQL restart

    ---------------------------------------------------------------------

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply