Why am I getting an error when trying to start my MATLAB Production Server instance after changing the port number in the "main_config" file?
2 views (last 30 days)
Show older comments
MathWorks Support Team
on 28 Oct 2019
Edited: MathWorks Support Team
on 16 Jun 2022
I just finished installing and setting up my MPS and was trying to set up and start a new server instance using the Command Line, as detailed in the documentation here:
I was able to set up and start a server successfully using HTTP on port 9910, but when I went into the generated "main_config" file and tried to change the port to HTTPS on port 9920 I got an error upon trying to start the server again. Why is this happening and how can I fix it?
Accepted Answer
MathWorks Support Team
on 16 Jun 2022
Edited: MathWorks Support Team
on 16 Jun 2022
The issue in this case is not the result of changing the port number, rather the result of changing from HTTP to HTTPS. An MPS server instance must be specifically configured in order to work using HTTPS. Specifically, to use HTTPS you much generate a certificate chain and private key for your server instance, and then place these PEM files into the appropriate directories as detailed in the doc link here:
If you are running multiple servers on the same machine, the same
certificate (self-signed or CA) can be used across multiple MPS instances
as the Fully Qualified Domain Name goes into the certificate (thus the identifier for that particular physical machine will be a part of the certificate).
If you are doing this on a larger scale with multiple machines and do not want to have to go through the trouble of setting up a certificate for each machine, or are looking to migrate existing HTTP servers to HTTPS then you could also choose to use a Load Balancer. This would mean that the only externally visible end-point would be that of the Load Balancer, and you could configure your MPS servers to just use HTTP. By then setting the Load Balancer's endpoint to HTTPS, you could still maintain the same secure layer between the client and the Load Balancer. This topology works best if all the instances are deploying the same CTF, but even if they do not, then a LB can still be configured and used mostly for authentication.
0 Comments
More Answers (0)
See Also
Categories
Find more on Installation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!