Before starting, you will need the following:
- A MATLAB® license that is current on Software Maintenance Service (SMS). For more information, see Configure MATLAB Licensing on the Cloud.
- An Amazon Web Services™ (AWS) account.
- An SSH Key Pair for your AWS account in the US East (N. Virginia) region. For more information, see Amazon EC2 Key Pairs.
Click the Launch Stack button to deploy a standalone MATLAB desktop client on AWS. This will open the CloudFormation Create Stack screen in your web browser.
Release | Region | Ubuntu 16.04 VM |
---|---|---|
MATLAB R2019a | us-east-1 | |
MATLAB R2019a | eu-west-1 |
For other releases, see How do I launch a template that uses a previous MATLAB release?
Note: Creating a stack on AWS can take a few minutes.
-
Provide values for parameters in the Create Stack page:
Name Value Stack name Choose a name for the stack. This will be shown in the AWS console. This must be unique within an AWS account. Example: Boston
AWS EC2 Instance type Choose the AWS instance type to use for running MATLAB. Check to ensure the instance type is available as not all types are available in all regions. For more information, see Amazon EC2 Instance Types and Pricing. Example: m5.xlarge
MATLAB AMI This is the image prepared by MathWorks which contains MATLAB 2018a pre-installed running on Ubuntu 16.04 and pre-configured drivers. If you've created your own custom image you can enter your AMI ID here. Example: my-matlab-ami
Allow RDP connections from This is the IP address range that will be allowed to connect to this instance using the Remote Desktop Protocol. The format for this field is IP Address/Mask. Example:
10.0.0.1/32- This is the public IP address which can be found by searching for "what is my ip address" on the web. The mask determines the number of IP addresses to include.
- A mask of 32 is a single IP address.
- Use a CIDR calculator if you need a range of more than one IP addresses.
- You may need to contact your IT administrator to determine which address is appropriate.
SSHKeyName A valid SSH key pair from AWS used to SSH into the instance. This is the only way to perform sudo operations on the instance itself. Example: my-keypair
Username Enter a username you would like to use to connect to the virtual machine in the cloud using remote desktop. Password Enter a password you would like to use to connect to the virtual machine in the cloud using remote desktop. Confirm Password Retype the password to confirm. Note: Make sure you select US East (N.Virginia) as your region from the nagivation panel on top. Currently, this is the only supported region.
-
Click the Create button. The CloudFormation service will start creating the resources for the stack.
After clicking Create you will be taken to the Stack Detail page for your stack. Wait for the Status to reach CREATE_COMPLETE. This may take up to 10 minutes.
- Expand the Outputs section in the the Stack Detail page.
- Look for the key named
RDPConnection
and copy the corresponding public DNS name listed under value. For example: ec2-11-222-33-44.compute-1.amazonaws.com - Launch any remote desktop client, paste the public DNS name in the appropriate field, and connect. On the Windows Remote Desktop Client you need to paste the public DNS name in the Computer field and click Connect.
- In the login screen that's displayed, use the username and password you specified while setting up the stack in Step 2.
Double-click the MATLAB icon on the virtual machine desktop to launch MATLAB. The first time you start MATLAB you will need to activate it. By default you will be asked to use your MathWorks Account to activate MATLAB. For other ways to activate MATLAB, see Configure MATLAB Licensing on the Cloud.
Note:It may take a few minutes for activation to complete and MATLAB to start. You will experience this delay only the first time you start MATLAB.
Once you have finished using your stack, it is recommended that you delete all resources to avoid incurring further cost. To delete the stack, do the following:
- Log in to the AWS Console.
- Go to the AWS CloudFormation page and select the stack you created.
- Click the Actions button and click Delete Stack from the menu that appears.
Release | Region | Ubuntu 16.04 VM |
---|---|---|
MATLAB R2018b | us-east-1 | |
MATLAB R2018a | us-east-1 |
All your files and changes are stored locally on the virtual machine. They will persist until you either terminate the virtual machine instance or delete the stack. Stopping the instance does not destroy the data on the instance. If you want your changes to persist outside the stack or before you terminate an instance you’ll need to:
- copy your files to another location (Example: S3 or Mount an Amazon EBS volume and create a snapshot), or
- create an image of the virtual machine.
You may want to shutdown the instance when you aren’t using it to save some money (you only pay for the storage used by the virtual machine when it is stopped). To shutdown an EC2 instance, locate it in the AWS web console, select the instance and choose “Instance State/Stop” from the “Actions” menu. You can restart it from the same menu. Any files or changes made to the virtual machine will persist when shutting down and will be there when you restart. A side-effect of shutting down the virtual machine and restarting is that the public IP address and DNS name may change. Inspecting the EC2 instance in the AWS console will reveal the new IP address and DNS name.
To avoid having to change the IP address between restarts you can establish a static IP using AWS Elastic IP Address. For more information, see https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/elastic-ip-addresses-eip.html.
To save a VM image, locate the EC2 Instance in the AWS web console and from the "Actions" menu select the instance and choose “Image/Create Image”.
You can customize a VM image by launching the reference architecture, applying any changes you want to the EC2 Instance such as installing additional software, drivers and files and then saving an image of that instance using the AWS Console. For more information, see How Do I save a VM image?. When creating a stack, replace the AMI ID in the CloudFormation template with the AMI ID of your custom image.
The VM image uses MathWorks Hosted License Manager by default. For information on using other license managers, see Configure MATLAB Licensing on the Cloud.
In the templates
folder of this repository you will find an example template for launching the reference architecture within an existing VPC and subnet. Edit the template to deploy this reference architecure to an existing VPC.
Provide suggestions for additional features or capabilities using the following link: https://www.mathworks.com/cloud/enhancement-request.html
Email: [email protected]