使用仪表板创建服务器实例
在本地服务器实例中设置并登录仪表板后,您可以创建服务器实例。有关设置仪表板的详细信息,请参阅设置并登录 MATLAB Production Server 仪表板。
在仪表板中,导航到新实例的服务器计算机。
例如:服务器 > localhost
选择新建。
在 Name 字段中,输入实例的名称。
名称可以是任意字符和数字的组合,不能有空格。
名称表明了服务器的用途。例如,供东海岸交易者使用的交易功能的服务器实例可以命名为
trading_east。它对于计算机来说必须是唯一的。
在 Description 字段中,提供服务器实例的可选描述。
它描述了服务器实例的功能。例如,
trading_east的描述可能是:Instance hosting arbitrage functions joe, fred, and arlo. This instance uses strong encryption, and access to the functions is limited to a select group of clients.
点击 Create。
新的服务器实例以停止状态添加到仪表板。您必须手动启动它,然后它才能处理请求。
注意
要启动您的实例,您需要完成另外两个步骤:
设置 MATLAB® Runtime 位置。有关详细信息,请参阅使用仪表板设置 MATLAB Runtime 位置。
指定许可证信息。有关详细信息,请参阅使用仪表板指定服务器实例许可证选项。
未能完成这些步骤将会产生错误。
设置 MATLAB Runtime 位置
在仪表板中,从最左侧的导航窗格中选择服务器实例。
例如:Servers > localhost > myinstance
选择 Settings 选项卡。
展开核心区域。
将字段 MATLAB Runtime 中的值
mCRrOOTuNsET替换为您的 MATLAB Runtime 的位置。例如,此表显示了 R2025b 的默认安装文件夹。平台 MATLAB Runtime 安装文件夹 Windows® C:\Program Files\MATLAB\MATLAB Runtime\R2025bLinux® /usr/local/MATLAB/MATLAB_Runtime/R2025bmacOS /Applications/MATLAB/MATLAB_Runtime/R2025b点击 Save。
启动或重新启动服务器实例。
如果您没有设置 MATLAB Runtime 的位置,您将收到以下错误消息:
Instance cannot be started: please update the MATLAB Runtime option in instance settings by replacing the "mCRrOOTuNsET" with the full path to MATLAB runtime directory