This example shows how to install, configure, and start an instance of MATLAB® Production Server™ in an on-premises installation. The example uses the command-line for server creation, configuration and start up.
Download the installer from MathWorks Downloads.
Run the installer.
Select MATLAB Production Server from the product list.
When the installer asks where to install MATLAB Production Server, enter the name of an empty folder.
Once the installation is complete, add the
folder to your
system $MPS_INSTALL\scriptPATH environment variable.
represents your
MATLAB
Production Server installation folder.$MPS_INSTALL\script
For more information about installation options, see Install MATLAB Production Server.
You must add your MATLAB Production Server license file to the license manager.
Download the installer from MathWorks Downloads, if you do not already have it.
Run the installer.
When the installer prompts you to sign in, click Advanced Options > I want to install network license manager.
If your organization already has a network license manager installed, simply add the MATLAB Production Server license file to it.
For more information about installation options, see Install Network License Manager.
MATLAB Production Server requires the MATLAB Runtime. You must install the MATLAB Runtime, if you do not have it installed on your system.
Download the MATLAB Runtime installer from https://www.mathworks.com/products/compiler/mcr.
Run the MATLAB Runtime installer.
For more information, see Supported MATLAB Runtime Versions.
Use the mps-setup command to set the default
MATLAB Runtime for all the server instances that you create.
To set the default MATLAB Runtime:
Open a system command prompt with administrator
privileges.
Run mps-setup.
For more information, see Specify Default MATLAB Runtime for New Server Instances.
To create a server configuration or instance, enter the mps-new command from the system prompt. Specify the name of the server that
you want to create as an argument to the mps-new command.
For example, to create a server instance with the name prod_server_1
located in C:\tmp and to use the verbose mode, run the following on your
system command prompt.
C:\tmp>mps-new prod_server_1 -v
For more information, see Create Server Instance.
After you create a new server instance, you must configure it. At a minimum, ensure that
the following properties in the main_config server configuration file are
set.
license — Specify the host and
port of the license server, typically
27000@license-server-host.
mcr-root — Specify the path to the
versions of MATLAB Runtime to use. You can set this property to use multiple versions of MATLAB Runtime. For more information, see Support Multiple MATLAB Runtime Versions.
For more information on editing main_config, see Configure Server.
To start the server instance that you created, enter the mps-start command from the system prompt. Specify the name of the server that
you want to start as an argument to the mps-start command.
For example, to start a server instance with the name prod_server_1
located in C:\tmp, run the following on your system command
prompt.
C:\tmp>mps-start -C prod_server_1
For more information, see Start Server Instance.
mps-restart | mps-setup | mps-start | mps-status