You can configure an on-premises MATLAB® Production Server™ instance to start when the host machine starts by registering the server instance as a Windows® service.
To create a new on-premises server instance and register it as a Windows service, run the mps-new command with the --service option at the
system command prompt.
mps-new \tmp\server_1 --service
You can assign a different name, description, and user for the Windows service than the defaults by providing arguments to
mps-new.
The Windows service created for the server instance does not start automatically.
To start the server instance, start the service, or start the server at the command
prompt using the mps-start. You can edit the
configuration for the instance before starting it.
The Windows service created for the server instance starts when the host machine starts. When the host machine restarts, the server instance restarts with it.
To create a new Windows service for an existing on-premises server instance, use the mps-service command with the
create option at the system command prompt.
mps-service -C \tmp\server_1 create
You can change the name, description, and user for the Windows service by providing arguments to mps-service.
The Windows service created for the server instance is configured to start when the machine starts. When the host machine is restarted, the server instance restarts with it.
You can specify how your system responds if the server instance running as a Windows service fails.
Open Service Control Manager in Windows.
Locate and double-click the server instance service that you want to configure for failure recovery.
Specify recovery options in the Recovery tab.

If you want to use network drives with a server instance that runs as a
Windows service, it is recommended that you specify UNC paths to the network
drives instead of mapped drive letters. When you configure a server instance to run
as a Windows service, the default user account for the service is
SYSTEM. However, the user account that starts the server,
either using mps-start at the command line or by starting the
Windows service, is not SYSTEM, but is a dedicated domain
account—the user account that is logged in to the computer. Using UNC paths makes
the network drives accessible to both the user accounts.
Depending on the permissions on the network share, you might choose to configure the Windows service to run under a dedicated domain account and grant to the dedicated domain account necessary permissions on the network share.
mps-new | mps-service | mps-start