Run ad-hoc tasks on target Linux and Windows hosts to install Puppet agents, manage packages or system services, or to execute shell commands.

Before you begin

To run tasks on Linux hosts, your SSH credentials must be for the root account on each target host. See Secure Shell (SSH).

There are a number of ways to select a task:
  • On the dashboard menu.

  • On any hosts summary page.

  • On any host or package details page.

When selecting to run a task from either a summary or details page, some of the selected hosts may not be eligible to run the task on. An eligible host must be accessible using the SSH or WinRM credentials you added, or if running the install Puppet agent task, an eligible host doesn't have the agent installed.

  1. Click Run task, and select the task:
    • Install Puppet agent.

    • Run a shell command.

    • Manage package.

    • Manage service.

  2. Enter the values for the task parameters (see below).
  3. Click Select hosts
  4. Select the hosts to run the task on, and click Select credentials.
  5. Select the credentials for accessing the hosts, and click Review task summary.
  6. Review the tasks details, your credentials, the list of target hosts, and click Run task.
    Tip: To view the status of the task run, click Activity feed, and select Status. For more information, see View discovery and task status.

Install Puppet agents

Install a Puppet Enterprise agent to regularly pull configuration catalogs from a Puppet master, and apply them to your target Linux or Windows hosts. The agent maintains the host configuration you want.

Restriction: If you enter an invalid value for the optional cacert_content parameter, the task fails, and you must enter a valid value for the task to run. An empty value is not accepted.
ParameterDescription
cacert_content The master CA certificate content (optional). If not specified, the master's identity is not verified during the agent installation.
certname The unique certificate name for the Puppet agent (optional).
custom_attribute The custom attribute setting added to puppet.conf and included in the custom_attributes section of csr_attributes.yaml. For more information, see custom attributes.
Important: Values must be entered as an array.
dns_alt_names The alternative DNS names for generating the agent certificate.
environment The environment to install with the Puppet agent (optional).
extension_request The extension attribute setting added to puppet.conf and included in the extension_requests section of csr_attributes.yaml. For more information, see extension requests.
Important: Values must be entered as an array.
master The required hostname for the Puppet master. The FQDN must be fully resolvable by the node on which you're installing the agent.

Manage packages

Install, upgrade, or uninstall packages on discovered hosts without installing an agent.

Remember: To run the manage package task on target hosts, the following package management systems are required:
  • APT or YUM for Linux hosts.

  • Chocolatey for Windows hosts.

ParameterDescription
action The action to be applied to the package:
  • install the package. To install a specific version of the package, specify the value in the version parameter. If installing the package for the first time, the package repository on each target host must have the package stored.

  • uninstall the package. To uninstall a specific version of the package, specify the value in the version parameter.

  • upgrade the version of the package. This is particularly useful for upgrading vulnerable packages to secure versions. To upgrade to a specific version, choose install, and specify the value in the version parameter.

name The name of the package.
provider The name of the provider to use for managing or inspecting the package.
version The version, and if applicable, the release value of the package. A version number range or a semver pattern are not permitted. For example, to install the bash-4.1.2-29.el6.x86_64.rpm package, enter 4.1.2-29.el6.
Tip: To install or upgrade to the latest version of a package, leave the version parameter blank.

Run shell commands

Execute an arbitrary shell command on discovered hosts without installing an agent.

ParamterDescription
command The command to execute on the target hosts.

Linux example:

echo "Hello, World ${USER}" > /hello.txt


                                Windows example:

echo "Hello, World $env:UserName" > C:\hello.txt

To execute commands, Windows tasks use the command prompt. To run PowerShell commands, you must invoke PowerShell. For example:

powershell Get-Process
failonfail By default, the task fails when the command returns a non-zero. To disable this default setting, select the checkbox.
interleave By default, content from stdout and stderr is interleaved. To disable this default setting, select the checkbox.

Manage system services

Manage and inspect system services on discovered hosts.

ParameterDescription
action The action to be applied to the service:
  • stop the service.

  • start the service.

  • restart the service.

  • enable the service.

  • disable the service.

  • View the current status of the service (Windows only).

name The name of the service.
provider The name of the provider to use for managing or inspecting the service.
Back to top
The page rank or the 1 our of 5 rating a user has given the page.
The email address of the user submitting feedback.
The URL of the page being ranked/rated.