Main Content

Diagnose a Corrupted MATLAB Runtime

This example shows a typical diagnostic procedure you might follow to solve a problem starting server prod_server_x.

After you issue the command:

mps-start prod_server_x
from within the server instance folder (prod_server_x), you get the following error:
Server process exited with return code: 4
(check logs for more information)
Error while waiting for server to start: The I/O operation
has been aborted because of either a thread exit 
or an application request

To solve this issue, you might check the log files for more detailed messages, as follows:

  1. Navigate to the server instance folder (prod_server_x) and open the log folder.

  2. Open main.err with any text editor. Note the following message listed under Server startup error:

    Dynamic exception type: class std::runtime_error
    std::exception::what: bad MATLAB Runtime installation: 
    C:\Program Files\MATLAB\MATLAB Runtime\v82 
    (C:\Program Files\MATLAB\MATLAB Runtime\v82\bin\
    win64\mps_worker_app could not be found)
  3. The message indicates the installation of the MATLAB® Runtime is incomplete or has been corrupted. To solve this problem, reinstall the MATLAB Runtime.

Diagnose Corrupted MATLAB Runtime in Dashboard

If you installed MATLAB Production Server™ using the dashboard, follow these steps to diagnose whether the MATLAB Runtime is corrupted.

  1. Select the server instance from the leftmost navigation pane.

  2. Select the Logs tab.

  3. Scan the log for the following error message.

    Dynamic exception type: class std::runtime_error
    std::exception::what: bad MCR installation: 
    C:\Program Files\MATLAB\MATLAB Compiler Runtime\v902 
    (C:\Program Files\MATLAB\MATLAB Compiler Runtime\v902\bin\
    win64\mps_worker_app could not be found)

Tip

You can use the Search field to locate the message.

If the MATLAB Runtime is corrupt, you must reinstall it.