Thor Logo dbatools

SqlAgent

Copy-DbaAgentServer

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaAgentServer View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies all SQL Server Agent objects and server properties between instances. Description Migrates complete SQL Server Agent configuration including jobs, operators, alerts, schedules, job categories, and proxies from one instance to another. This function handles the proper sequence of object creation and also copies server-level Agent properties like job history retention settings, error log locations, and database mail profiles.

Read more

Set-DbaAgentJobOutputFile

Rob Sewell, sqldbawithabeard.com

Set-DbaAgentJobOutputFile View Source Rob Sewell, sqldbawithabeard.com Windows, Linux, macOS Synopsis Configures the output file path for SQL Server Agent job steps to capture step execution logs. Description Modifies the output file location where SQL Server Agent writes job step execution details, error messages, and command output. This centralizes logging for troubleshooting failed jobs, monitoring step execution, and maintaining audit trails without manually editing each job step through SQL Server Management Studio.

Read more