User Command Example: Echo Command

This example shows how to create an echo user command. You can see the use of TALES expressions in the definition of this command.
  1. Add a command called "echoDevice"
  2. In the command definition, echo the name and IP address of the device:
    echo name = ${here/id} ip = ${here/manageIp}
    In a TALES expression, here is the object against which the expression is executed. Some TALES expressions in the system have other variables (such as evt for event, and dev or device for the device). See the Appendix titled TALES Expressions for more information about TALES expressions syntax.
  3. Select a device and then run the command.
  4. Edit the command to add more information:
    echo name = ${here/id} ip = ${here/manageIp} hw = ${here/getHWProductName}
  5. Run the command against a group of devices and view the command outputs.