Define MATLAB Job Scheduler Startup Parameters
MATLAB® Job Scheduler service runs using several parameters. These parameters set the process name, the user name, log file location, ports, and so on of the MATLAB Job Scheduler cluster.
You can edit the parameters in the mjs_def
before installing or starting
the mjs service. Find this file in these locations:
on Microsoft® Windows® operating systemsmatlabroot
\toolbox\parallel\bin\mjs_def.bat
on Linux® operating systems.matlabroot
/toolbox/parallel/bin/mjs_def.sh
The mjs
service reads the mjs_def
file when you start
or stop the mjs
service, run the mjs
service with the
arguments console, or install or uninstall the mjs
service on a Windows operating system. When you start and stop workers and job managers, they contact
the mjs
service they are running under to obtain the values of the definitions
and defaults stored in this file. Thus, the mjs
service does not read the
mjs_def
file again when starting and stopping workers and job
managers.
For a working cluster setup, the mjs_def
files must use consistent
settings across all hosts of the cluster.
Note
If you want to run more than one job manager on the same host, they must all have unique names. Specify the names using flags with the startup commands.
The user-configurable parameters in the mjs_def
file are defined
below.
MATLAB Job Scheduler Process and Logging
Parameter | Description |
---|---|
| Name of the host reading the The
processes under the On Windows operating systems, the default for /F "usebackq skip=2 tokens=4" %%A in (`reg query HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters /v "NV Hostname" 2^>nul`) do ( set strHostname=%%A ) for /F "usebackq skip=2 tokens=4" %%A in (`reg query HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters /v "NV Domain" 2^>nul`) do ( set strDomain=%%A ) HOSTNAME=%strHostname%.%strDomain% On Linux operating systems, the HOSTNAME=`hostname -f` Change this setting only if:
|
| Base port of the The If you use a host that runs a total of For example, if you use a host with 1 job manager and 16 workers, then you need the following ranges of ports to be open:
To connect from MATLAB to a cluster with a non-default |
| Username to start the By default,
all the processes that the You can set this parameter to run the
The
For more information about the privileges and requirements for
the |
| Password for username specifies in the To run the If you specify the password in the
|
| Folder used to store PID and lock files. (Linux operating systems only.) The You must ensure that the user the
|
| Folder used to store The
You must ensure that the user the |
| Folder used to store The
On the host that runs the job manager, the checkpoint folder stores database information related to the job manager and can require substantial diskspace. On the hosts that runs the workers, the checkpoint folder stores data transferred with tasks for workers. You must ensure that the user the
|
| Set the Java® Runtime Environment (JRE™) path for the By default, the
|
Job Manager Security
Parameter | Description |
---|---|
| Security level for the cluster. You can specify the security level for your MATLAB Job Scheduler cluster. Select from one of these levels:
For more information, see Set Security Level. |
| Username of the cluster administrator account. At Security Level 2 and 3, the administrator can access and manipulate all users' jobs and tasks. They can also change users' passwords if LDAP server authentication is not enabled. The
If
LDAP server authentication is enabled, the username specified in the
If you do not specify a username, the cluster administrator account
username defaults to |
| Use encrypted communication between services. Set up encrypted communication between job manager, client and workers. By default, job managers and workers communicate over non-encrypted channels. This can be useful when you do not have a requirement to protect the data or the connection is already protected from unauthorized access (for example, if your cluster network is isolated and has no access to the Internet). Additionally, encrypted communication can cause a performance decrease due to the extra overhead incurred when encrypting messages. When you set
Encrypted
communication requires a shared secret file on each participating host (excluding the
MATLAB client). For more information about the shared secret file, including how to
generate one, see the description for
|
| Require verification for privileged commands sent to the cluster. By
default, Privileged commands
include any command which can modify the cluster state. When you set
For more information, see Set Cluster Command Verification. |
| Location of the shared secret file. To establish encrypted
connections between job managers and workers, a shared secret file is required on all
participating hosts. You can create a shared secret file with the
If the shared
secret file does not already exist when you start the When you set the cluster
to Security Level 3, the
Note Secret files contain sensitive data and you must protect it against unauthorized access. Anyone that can access the secret file might be able to eavesdrop on the connections between services.
|
| Remember user passwords for future sessions. If set to
|
| List of users allowed to log on to the job manager. This property
defines a list of users that are allowed to access the job manager. Multiple usernames must
be separated by commas. By default, To allow any user to access the job manager, use the
keyword |
| Require MATLAB clients to present a certificate to connect to the job manager when using encrypted communication. By default,
|
| Windows domain workers use when logging on at security level 3 (Windows operating systems only). To run tasks as the user that submitted
them, Windows requires a domain in addition to the user name. By default, if a task belongs
to In most circumstances the default value is correct and must not be altered.
Note This property is required only when running on Windows at security level 3.
|
| Option to use an LDAP server to authenticate user credentials. (since R2023a) By default,
Cluster users must use their LDAP server username and password to connect to the cluster. |
| URL of the LDAP server to authenticate users. (since R2023a) If you have configured the cluster to use LDAP server authentication,
you must set the ldap://HOST:PORT If you have configured your LDAP server over SSL, specify the URL as: ldaps://HOST:PORT For more information, see Configure LDAP Server Authentication for MATLAB Job Scheduler. |
| Format of a security principal for the LDAP server. (since R2023a) You can specify the format of a security principal the LDAP server uses for authentication. Common formats include
|
| Frequency at which the cluster synchronizes with the LDAP server. (since R2023a) The default value is
You can specify one of the following:
|
| Option to export cluster monitoring metrics from job manager. (since R2024b) You can export metrics from the job manager for integration with cluster monitoring tools. For more information, see Configure Metrics for MATLAB Job Scheduler. |
| Port for exporting metrics. (since R2024b)
The job manager uses an HTTP(S) server at the port you specify to export metrics. By
default, this port number is |
| Option to use encrypted communication to export metrics. (since R2024b) By default, |
| Job manager's trusted certificate authority (CA) for encrypted metrics. (since R2024b) Path to a CA certificate to verify client
certificates. If You can use the |
| Job manager's certificate for encrypted metrics. (since R2024b) Path to the job manager's public certificate. The job manager
presents this certificate to clients that want to form encrypted connections for metrics.
You must set this parameter if You can use the |
| Job manager's private key for encrypted metrics. (since R2024b) Path to the private key associated with the certificate file you
specify for You can use the
|
Job Manager and Worker Settings
Parameter | Description |
---|---|
| Default name of the job manager. When you start a new job manager,
it needs to be identified by a name on the network, and when a new worker is started, it
needs to know the name of the job manager to register with. The values specified with the
To override the default job manager name, use the |
| Host on which the job manager lookup process runs. The MATLAB worker processes and the job manager process contact the job manager lookup process on the specified host. You can override the job manager host using the
|
SAVE_JOB_HISTORY | Save job and task accounting information to disk. (since R2024a) By default, |
| Maximum heap size of the job manager Java process. You can adjust the amount of heap memory for the job
manager Java process. By default, |
| Default name of the worker. You can override the default worker by
calling the |
| Maximum heap size of all worker Java process. You can adjust the amount of heap memory for the worker
Java process. By default, |
| Number of seconds for worker sessions wait for MATLAB to start before detecting a stall. The default value is
|
| Shell workers use in system calls (Linux operating systems only). You can specify the shell that is
spawned when a worker invokes a MATLAB system command. For example, to use the Bourne shell, set
MATLAB checks internally for the Note that some
shells (for example |
| Use a license that is managed online. Set
When enabled, users must log in to their MathWorks® account to connect to the cluster, and their account must be linked to a MATLAB Parallel Server™ license that is managed online. |
| Initiate connections from the client to the cluster. To make all
connections outbound from client, set |
| Path to additional installations of previous MATLAB releases.
You must list the path to the MATLAB installation without quotes. Multiple entries are allowed separated by semi-colons, for example: MJS_ADDITIONAL_MATLABROOTS=C:\Program Files\MATLAB\R2016a;C:\Program Files\MATLAB\R2016b Only versions of MATLAB released prior to the MATLAB Parallel Server version you are using are supported, starting with R2016a. MATLAB clients can only use this cluster if a path to their version is specified. |
| The maximum number of Linux workers the cluster can scale up to on demand. Only set this value if you have set up your cluster for auto-resizing. For more details, see Set up MATLAB Job Scheduler Cluster for Auto-Resizing. |
| The maximum number of Windows workers the cluster can scale down to on demand. Only set this value if you have set up your cluster for auto-resizing. For more details, see Set up MATLAB Job Scheduler Cluster for Auto-Resizing. |
| Scheduling algorithm for the job manager. (since R2023b) Select from one of these options:
|
See Also
startworker
| stopworker
| mjs