Getting Started with MATLAB Job Scheduler, Part 5: Monitor MATLAB Parallel Server Usage and Upgrade to a New Release - MATLAB
Video length is 6:01

Getting Started with MATLAB Job Scheduler, Part 5: Monitor MATLAB Parallel Server Usage and Upgrade to a New Release

From the series: Getting Started with MATLAB Job Scheduler

This is the fifth video of a five-part series. It will provide an overview of how to monitor MATLAB Parallel Server™ usage with MATLAB Job Scheduler and upgrade to a new release.

One way to get insight into your MATLAB Job Scheduler cluster is using Admin Center, which is a graphical user interface with which you can control and monitor the MATLAB Parallel Server processes of a MATLAB Job Scheduler cluster. With Admin Center, you can monitor available workers and see which workers are busy or idle.

You can also use nodestatus, a command-line tool, to display the status of the mjs service and the processes that it maintains. You can invoke nodestatus on a remote machine and run it with a series of “infolevels” for additional verbosity.

You can gain insight into MATLAB Parallel Server usage, including any licensing issues, through the network license manager log file or by using the Parallel Server license check utility that ships with the network license manager.

Customize your MATLAB Job Scheduler cluster by modifying the mjs_def. You can modify things such as the security level that MATLAB Job Scheduler uses, support multiple MATLAB releases, and more.

Published: 17 Aug 2023

Hello. My name is Rebecca Silva Alves. I am a part of the installation and licensing team here at MathWorks. This is the fifth video of a five-part series where I am going to provide an overview of MATLAB Parallel Server and how to set up and use MATLAB Job Scheduler and a MathWorks network license manager. The previous video covered how to run and monitor jobs on your MATLAB Job Scheduler cluster. This video will cover how you can monitor MATLAB Parallel Server usage and licensing, as well as how to upgrade to a new MATLAB Parallel Server release.

MATLAB Job Scheduler comes with tools that enable you to monitor the status of your MATLAB Job Scheduler hosts. To get started, navigate to the Toolbox, Parallel, Bin Folder. This folder contains a number of useful scripts for starting, stopping, and monitoring MATLAB Job Scheduler. We will look at how you can monitor MATLAB Job Scheduler worker status with Admin Center.

In the second video of this video series, we covered how you can use Admin Center to start MATLAB Job Scheduler on your cluster. By default, all of the workers will be idle when they are not doing anything. When users run jobs on the cluster, available workers are assigned to the job and become busy. You may need to click the Update Now button to refresh Admin Center.

You can also use the Nodestatus script to keep track of the workers via the command line. You can run Nodestatus with various levels of verbosity for more information. You can also run NodeStatus with the dash JSON flag to view the output in a JSON format. Last but not least, you can pass a remote host name to Nodestatus to check the status of a remote host in the MATLAB Job Scheduler cluster.

Next, we will cover how to monitor MATLAB Parallel Server licenses. When a MATLAB Parallel Server worker runs, it checks out a license key from the network license manager. When the worker finishes, the MATLAB Parallel Server license key is returned to the license pool.

The product name you will see in the license logs is different from MATLAB Parallel Server, but it is the same product. You can see MATLAB Parallel Server worker licenses being checked out and returned to the pool in the network license manager logs. If there are any license-related issues, like not enough MATLAB Parallel Server worker licenses, you will see those errors in here.

You may also use the Parallel Server license check executable to get more information about your MATLAB Parallel Server license. You can see how many workers are available, in use, and how many users are using the software. As we discussed previously, the MATLAB client versions must match the version of MATLAB Parallel Server on the cluster. If you have users who are using different versions of MATLAB, you can install multiple versions of MATLAB Parallel Server on the cluster.

After installing all the necessary versions of MATLAB Parallel Server, you will need to make one modification in the mjs_def file of the newest release. At the bottom of the mjs_def, you will specify the MATLAB Parallel Server installation locations for all versions that you want to support. After making this modification, start the MJS service for the latest release of MATLAB Parallel Server.

When a new version of MATLAB Parallel Server comes out and you want to install it on your cluster, you will need to perform the following steps. Notify your users to retrieve data from their jobs in MATLAB. Upon upgrading MATLAB Parallel Server releases, all job data will be reset. So be sure that all users retrieve any needed data from previous MATLAB Parallel Server jobs before installation.

Verify that no jobs are running on the cluster. Stop all of the MATLAB Job Scheduler services. If there are any jobs running on your cluster, you can run stopworker.bat with the dash on idle flag. This will stop the worker after it has completed the job and will prevent further jobs from running on it.

Install the latest release of MATLAB Parallel Server on the cluster. Update the mjs_def in the newest version of MATLAB Parallel Server with all of the releases you want to support. Start the MATLAB Job Scheduler service, the job scheduler, and the workers for the newest release.

In this video, we covered how you can manage and upgrade MATLAB Job Scheduler. We used Admin Center and Nodestatus to monitor worker status, monitored MATLAB Parallel Server license usage, and diagnosed license-related issues, modified the mjs_def file to support multiple versions of MATLAB Parallel Server, and updated MATLAB Parallel Server to a new release.

This is the last video in this video series. Please feel free to reach out to us with any questions or issues. Bye for now.