Users Guide

Device Capability Matrix
Managing Generic Command Line Task
Using Generic command line task, you can run different types of tasks such as, a batch file, a script file such as a
Powershell or VBS script, an executable, or a command, on the local OpenManage Essentials system. While the task
always runs on the local OpenManage Essentials system, you can structure the local task to interact with or act upon a
variety of remote devices or servers.
You can enter tokens (substitution parameters) in the command line task to be passed to the script file, executable,
command, or batch file and execute local scripts on devices that are discovered in OpenManage Essentials.
To manage Generic command line tasks:
1. From OpenManage Essentials, click ManageRemote TasksCommon TasksCreate Command Line Task.
2. In the General tab, choose Generic Command.
3. If required, update the task name.
4. Enter the path and command (batch, script, or executable) to run on the local system.
5. (Optional) Enter any arguments for the command. If $USERNAME and $PASSWORD are used in Arguments, you can
pass the credentials to the command by the entering the credentials under Script Credentials. If $IP or $RAC_IP are
used in Arguments, you can run the command against the selected target(s) by passing the IP address of each
target to the command.
NOTE: The tokens provided in the Arguments field must entirely be in either uppercase or lowercase. For
example, $HOSTNAME or $hostname.
NOTE: If you are running a command that does not require any tokens or arguments, the Script Credentials
section and the Task Target tab are not displayed.
6. (Optional) Choose Ping Device if you want to ping the device first.
7. (Optional) Choose Output to file to capture task output from multiple targets. Enter path and file name.
To log the information from all selected targets, select Append.
To write all the detected errors to the log file, select Include errors.
8. On Task Target, do one of the following:
Select a query from the drop-down list or create a new query by clicking the New button.
Select targets for running the commands.
9. On Schedule and Credentials, enter the local administrator credentials with privileges to run commands on the
OpenManage Essentials system. Set schedule for the task(s) and then click Finish.
For more information, see About Tokens and Generic Command.
About Tokens
The following tokens can be used to pass values to the batch, script, or executable file:
$IP and $RAC_IP — If these arguments are used, the Task Target tab appears in the Create a Command Link
Task screen. The Task Target tab allows you to select the targets to pass the arguments. $IP is used for a server
IP and $RAC_IP is used for a RAC (iDRAC) IP. From the Task Target tab, you can select either groups, a device or
use dynamic queries.
$USERNAME and $PASSWORD — In some instances, you must provide credentials for a remote system in your
batch or script file. If $USERNAME or $PASSWORD are used in arguments, the Script Credentials section
appears for these values. The credentials entered in the Script Credentials section is passed to the command
line. You can pass either of these values or both.
153