Skip to content

Execute Command Activity

The Execute Command activity enables users to run Linux commands directly on a remote server. This activity facilitates server interaction, allowing for tasks such as system administration, file manipulation, or data retrieval through command-line operations.

Field Description Requirement
Session name The reference name of the session established by a Connect activity. Required
Command The Linux command to be executed on the server. Required
Timeout (sec) The maximum duration, in seconds, before the activity generates an error and terminates the process if the command does not complete. Required
Command result The variable name to which the output value of the executed command is assigned. Optional

Action Types & Examples

Session name

  • Format: String
  • Example Result: testSession

Command

  • Format: String
  • Example Result: ssh test.server.com

Timeout (sec)

  • Format: Digit (Integer)
  • Example Result: 8

Command result

  • Format: String (Variable Name)
  • Example Result: pwdResult

Implementation Examples

Field Setup - Command result: myCommandOutput

Execution Parameters - Session name: myServerSession - Command: ls -l /var/log - Timeout (sec): 30

Technical Notes

The successful execution of commands depends on the configured user's permissions on the remote server. Ensure that the command syntax is valid for the target Linux distribution. Commands that require interactive input or produce extensive output might require specific handling or increased timeout values.