Run an Automated Task when a check fails
You can configure an Automated Task to run when a check fails while adding or editing a task or a check. For example, you can run a Clean All Temp Files task when the Disk Space Check fails to help resolve the issue automatically.
Automated Tasks are supported for Windows, Mac (from Agent 2.3.0), and Linux (from Agent 2).
An Automated Task runs only when a check changes from passing to failing and creates an entry in the Outages tab. The task does not continue to run while the check remains in a failed state. The check must pass and then fail again to trigger the task.
Tasks tab
To set up an Automated task when you add or edit a task from the Tasks tab:
- In the All Devices view North-pane, select the device.
- Go to the Tasks tab in the South-pane.
- To add a task, select Add Automated Task.
- To edit a task, right-click a task and select Edit Automated Task.
- Select a script from the expandable sections, then select Next.
- Only scripts uploaded for Automated Tasks and compatible with the device OS appear.
- Enter a name for the task
and any required script parameters required, then Next.
The following example shows the script parameters for the Active Directory Users Query task.
- In the Select Frequency Method menu, select On Check Failure.
- Choose the check that triggers the task in When Check Fails.
- Configure additional settings in With These Settings, if available, then select Next.
- (Optional) Set maximum permitted execution time for the script.
- Select Finish to save and apply the task.
Checks tab
To set up an Automated task when you add or edit a check from the Checks tab:
- In the All Devices view North-pane, select the device.
- Go to the Checks tab in the South-pane.
- To add a check , select Add Check, then choose 247 Check or Add DSC Check, and the select a check.
- To edit a check, right-click a check and select Edit Check.
- Configure the check as needed.
- Select Assign a Task after creating the Check, then select OK.
- Select the Automated Task script, then select Next.
- Enter any required Command Line parameters or Script parameters, then select Next.
- (Optional) Set maximum permitted execution time for the script.
- Select Finish to save and apply the task.
View check and Automated Task associations
- In the Checks tab, the Assigned Tasks column shows all Automated Tasks linked to a check. Select the link to open the Tasks tab and view details.
- If multiple tasks are associated with a check, the column shows the number of configured tasks.
-
In the Tasks tab, the Assigned Check column lists associated checks. Select the link to open the Checks tab and view details.
Any changes to the Automated Task are completed on the Tasks tab.




