Hitachi

JP1 Version 12 JP1/Client Process Automation Configuration and Administration Guide


8.2.1 Command execution

Organization of this subsection

(1) Overview of the function

This item executes actions using specified commands and parameters.

(2) List of settings

Name

Required

Format

Can specify inherited information?

Execution command

Yes

String (1 to 512 bytes)

Yes

Parameter

No

String (0 to 512 bytes)

Yes

Virtual user name

No

String (0 to 512 bytes)

Yes (The profile information cannot be specified.)

(3) Settings

Execution command

Specify the file name of the command to execute.

A command is executed as a child process of the job execution service. When commands that require interactive operations are executed, those commands can be left running if you cannot perform operations in the window. (You can check this by the Task Manager or an alternative.) If you execute a command that requires interactive operations, use the command execution with the window item.

If specifying a file whose extension is other than .exe or .bat, you need to associate the file extension with an appropriate application.

Parameter

Specify the parameter for the execution command.

Virtual user name

Specify the name of the virtual user mapped to the name of the Windows user who executes the item. If the virtual user name is omitted, the item is executed with the account for the CPA job execution service.

To map the virtual user name, use the cpasetumap command. For details on the cpasetumap command, see cpasetumap in 9. Commands.

(4) Return values

Value

Description

Other than 126

The return value of the execution command. A value other than 0 indicates an abnormal end.

126

The internal processing of CPA ended abnormally during startup of the execution command.

Note:
  • If an error occurs in the internal processing of CPA during startup of the execution command, 126 is set to the return value of the command. Check whether the specified execution command file exists.

    If it exists, check the message log and take action according to the message.

    Note that if the execution command ends with the return value of 126, you cannot determine whether an error occurred in the internal processing or the execution command ended abnormally. We recommend that commands specified as the execution command return values other than 126.

  • If a virtual user name is specified for the item, fix the error by checking if:

    - The virtual user name is specified properly.

    - The virtual user name is registered.

    - The Windows user associated with the virtual user name is correct.

    - The Windows user associated with the virtual user name has the correct user rights.

    - The password for the Windows user associated with the virtual user name has not expired.

    - The password for the Windows user associated with the virtual user name is correct (the account is not locked).

    - The Net Logon service has been running.

(5) Example

  1. Execute the tasklist /V command.

    Execution command

    C:\Windows\System32\tasklist.exe

    Parameter

    /V

  2. Execute the tasklist /V command and output the results to c:\temp\tasklist_work.txt.

    Execution command

    cmd.exe

    Parameter

    /C tasklist /V >c:\temp\tasklist_work.txt