Top
Systemwalker Operation Manager  User's Guide
FUJITSU Software

4.3.18 Executing Jobs on a Remote Machine

Defining the mjrmtjob command as a job to be registered in the Jobscheduler enables you to execute commands or scripts on a remote machine where Systemwalker Operation Manager has not been installed.

Define the mjrmtjob command in the Command field of the Standard information tab of the Add/Change - Job window that is displayed when you click the Execute command job icon in the New Job Net window.


If you specify the mjrmtjob command in the Add/Change - Job window, all the values that you specify including Directory, Request host, and execution user are used for the mjrmtjob command. Specify values for the command or script to be executed on the remote machine in the command or parameter parameter of the mjrmtjob command.

The output of executing the command or script that you specified in the arguments of the mjrmtjob command is displayed in the Jobscheduler.

The completion code (return value) of the command or script will be the completion code that is displayed in the Jobscheduler. However, completion codes 201 to 256 are used by the mjrmtjob command and the Jobscheduler, so ensure that the completion codes (return values) of commands and scripts on the remote machine are not above 200. If the specified command or script has a negative value and is returned with a value of 256 or higher, the job completion code will be 255.

Example of a command to be registered in the Jobscheduler

The following describes the definition to be used for registering the mjrmtjob command in the Jobscheduler.

Click the Execute command job icon in the New Job Net window, and then define the command in the Command field of the Standard information tab of the Add/Change - Job window.

The following shows an example definition and describes its values.

Example definition in the Command field [Unix]

mjrmtjob -h HOSTB -p Linux -l UTF-8 -u UserA -d '/work' '/user/command/keisan aaa bbb ccc'

Description of the example definition

  Host name of the remote machine: HOSTB
  Type of OS on the remote machine: Linux
  Character encoding on the remote machine: UTF-8
  Name of the user who will execute the command or script on the remote machine: UserA
  Current directory that will execute the command or script on the remote machine: /work
  Example command to be executed on the remote machine: /user/command/keisan aaa bbb ccc

Refer to the Systemwalker Operation Manager Reference Guide for information on the mjrmtjob command.

Note

  • You must configure the settings before using the mjrmtjob command. Refer to "Definition of SSH Communication" in the Systemwalker Operation Manager Installation Guide for details.

  • If the operating system of the server that executes the mjrmtjob command is Windows and the operating system of the remote machine is Solaris 11.3 or later, JRE8 or later is required for the server that executes the mjrmtjob command. Set the installation path of the JRE8 or later to the environment variable "MJRMTJOB_JAVA_HOME". Refer to "Configuring SSH Communication" in the Systemwalker Operation Manager Installation Guide for details.

    If the following error is output when the mjrmtjob command is executed, it means that the SSH key exchange algorithm may not match the algorithm supported in the remote machine.

    Failed to access remote machine. Error: session.connect: SSH_MSG_DISCONNECT: 2 Protocol error: no matching DH grp found

    In this case, perform the following on the server that executes the mjrmtjob command.

    1. Install JRE8 or later.

    2. Add "MJRMTJOB_JAVA_HOME" as a system environment variable and set the installation path of JRE installed in 1.

    3. Restart Job Execution Control.