Creating a Reboot Worklet

This guide explains how to create a Worklet in the Automox console for the sole purpose of rebooting a device. This can be useful when a policy does not automatically restart a system or staged updates are pending installation.

Overview

Some update packages require a system restart to finalize. In the Automox console, such updates are marked as Reboot Required. However, certain restart methods might skip applying these patches. This Worklet ensures the system restarts if it is being flagged as Pending Reboot.

Worklet Setup

Follow these steps to create and configure the Worklet:

1. Access the Worklet Feature

  1. Log in to the Automox console.
  2. Navigate to Manage > Policies.
  3. Click Create Policy and select Worklet.

2. Configure Basic Details

  1. Enter a descriptive name for your Worklet (e.g., "Reboot Devices If Required).
  2. Choose the target operating system.
    Note: The same setup applies across all operating systems, but the Worklet runs only on the selected OS.
  3. Assign the relevant groups or use Device Targeting as necessary.

3. Add Code Blocks

Evaluation Code:

exit 1
  • This ensures the Worklet always runs.

Remediation Code:

exit 0
  • This completes the execution successfully.

4. Set Scheduling

  • Schedule the Worklet if required.

5. Configure User Notifications

  • In the User Notifications section, enable the option Force automatic restart after Worklet completion.
    Note: Restart notification settings are enabled by default.

worklet-notifications.png

Tips for Success

  • Verify that the device is online and connected to the Automox console to avoid execution issues.
  • If the Worklet doesn’t execute correctly, check the agent logs on the device for errors.
Was this article helpful?
0 out of 0 found this helpful