The Job Monitor displays the jobs in the queue for the scheduler determined by your selection of a cluster profile. Open the Job Monitor from the MATLAB® desktop on the Home tab in the Environment section, by selecting Parallel > Monitor Jobs.
The job monitor lists all the jobs that exist for the cluster specified in the selected profile. You can choose any one of your profiles (those available in your current session Cluster Profile Manager), and whether to display jobs from all users or only your own jobs.
The Job Monitor lets you accomplish many different goals pertaining to job tracking and queue management. Using the Job Monitor, you can:
Discover and monitor all jobs submitted by a particular user
Determine the status of a job
Determine the cause of errors in a job
Delete old jobs you no longer need
Create a job object in MATLAB for access to a particular job in the queue
Using the Job Monitor you can manage the listed jobs for your cluster. Right-click on any job in the list, and select any of the following options from the context menu. The available options depend on the type of job.
Cancel — Stops a running job and changes
its state to
'finished'. If the job is pending or queued,
the state changes to
'finished' without its ever running.
This is the same as the command-line
cancel function for the
Delete — Deletes the job data and
removes the job from the queue. This is the same as the command-line
delete function for the job.
Also closes and deletes an interactive pool job.
Show details — This displays detailed information about the job in the Command Window.
Show errors — This displays all the tasks that generated an error in that job, with their error properties.
Fetch outputs — This collects all the task output arguments from the job into the client workspace.
Because the Job Monitor indicates if a job had a run-time error, you can use it to identify the tasks that generated the errors in that job. For example, the following script generates an error because it attempts to perform a matrix inverse on a vector:
A = [2 4 6 8]; B = inv(A);
If you save this script in a file named
invert_me.m, you can
try to run the script as a batch job on the default cluster:
When updated after the job runs, the Job Monitor includes the job created by the
batch command, with an error icon () for this job. Right-click the job in the list,
and select Show Errors. For all the tasks with an error
in that job, the task information, including properties related to the error,
display in the MATLAB command window:
Task ID 1 from Job ID 2 Information =================================== State : finished Function : @parallel.internal.cluster.executeScript StartTime : Tue Jun 28 11:46:28 EDT 2011 Running Duration : 0 days 0h 0m 1s - Task Result Properties ErrorIdentifier : MATLAB:square ErrorMessage : Matrix must be square. Error Stack : invert_me (line 2)