Main Content

mpm install

(Linux, Windows, macOS) Install products from operating system command line

mpm install requires MATLAB® Package Manager. See Get MATLAB Package Manager.

Description

example

mpm install --release <release> --destination </full/path/to/destination> --products <product1> ... <productN> installs MathWorks® products and support packages for a release to the specified installation folder. mpm also installs any required products, if they are not installed already.

Run mpm install from the operating system command line. You can also use this command in a MATLAB Dockerfile to create a MATLAB container image. For more details, see Create a MATLAB Container Image on GitHub®.

example

mpm install --source </full/path/to/source> --destination </full/path/to/destination> --products <product1> ... <productN> specifies the installation source. Valid sources include products and support packages downloaded using mpm download, a mounted product ISO image downloaded from MathWorks Downloads, or product files downloaded using the MathWorks product installer. If you do not specify --source, then mpm installs products from MathWorks.

example

mpm install ... <installOptions> sets additional product installation options, using either of the previous syntaxes. For example, you can omit the installation of GPU libraries when installing Parallel Computing Toolbox™, or omit the installation of the default Java® Runtime Environment (JRE) used by MATLAB. You can specify options in any order.

example

mpm install --inputfile </full/path/to/file> installs products using an input file. You can download a template input file for your release from the mpm-input-files folder on GitHub. You must specify --inputfile without any other options.

Examples

collapse all

Install the latest release of Simulink® and Deep Learning Toolbox™ Model for ResNet-50 Network. If they are not already installed, mpm also installs the required products: MATLAB and Deep Learning Toolbox.

Linux® or macOS:

./mpm install --release R2024a --destination /home/<USER>/matlab --products Simulink Deep_Learning_Toolbox_Model_for_ResNet-50_Network

Windows® (run as administrator):

.\mpm.exe install --release R2024a --destination "C:\Users\<USER>\matlab" --products Simulink Deep_Learning_Toolbox_Model_for_ResNet-50_Network

You can install additional products later. For example, add Robotics System Toolbox™ to the installation.

Linux or macOS:

./mpm install --release R2024a --destination /home/<USER>/matlab --products Robotics_System_Toolbox

Windows (run as administrator):

.\mpm.exe install --release R2024a --destination "C:\Users\<USER>\matlab" --products Robotics_System_Toolbox

Download MathWorks products and support packages, copy them to another computer, and install them on that computer. This example assumes that both computers are using the same version and platform of mpm.

  1. Download the latest release of Simulink and Deep Learning Toolbox Model for ResNet-50 Network. mpm also includes the required products in the download: MATLAB and Deep Learning Toolbox.

    Linux or macOS:

    ./mpm download --release R2024a --destination /home/<USER>/downloads/mathworks --products Simulink Deep_Learning_Toolbox_Model_for_ResNet-50_Network

    Windows (run as administrator):

    .\mpm.exe download --release R2024a --destination "C:\Users\<USER>\Downloads\MathWorks" --products Simulink Deep_Learning_Toolbox_Model_for_ResNet-50_Network

    mpm downloads the product files to the specified destination folder.

  2. (Optional) If you are installing these products on a different computer, make the destination folder available for installation on the target computer. Use one of these options:

    • Copy the folder to a shared network drive that the computer can access.

    • Copy the folder directly to the computer using removable media.

  3. Install the downloaded products on the target computer using mpm install. Using the --source option, specify the absolute path to the downloaded files. mpm also installs the required products: MATLAB and Deep Learning Toolbox.

    Linux or macOS:

    ./mpm install --destination /home/<USER>/matlab --source /home/<USER>/downloads/mathworks --products Simulink Deep_Learning_Toolbox_Model_for_ResNet-50_Network

    Windows (run as administrator):

    .\mpm.exe install --destination "C:\Users\<USER>\matlab" --source "C:\Users\<USER>\Downloads\MathWorks" --products Simulink Deep_Learning_Toolbox_Model_for_ResNet-50_Network

Install MATLAB R2024a and specify to omit the installation of the default JRE used by MATLAB. Also install Parallel Computing Toolbox, specifying to omit the installation of the GPU libraries to reduce the installation size.

Linux or macOS:

./mpm install --release R2024a --products MATLAB Parallel_Computing_Toolbox --no-gpu --no-jre

Windows (run as administrator):

.\mpm.exe install --release R2024a --products MATLAB Parallel_Computing_Toolbox --no-gpu --no-jre

After installing MATLAB, you must set a supported custom JRE, or MATLAB will not run. To set a custom JRE, see the support article for your operating system:

Install products and support packages for MATLAB R2024a by specifying installation options in an input file.

From the mpm-input-files folder, open the folder for the latest MATLAB release, and download a copy of the mpm_input_<release>.txt file. In the downloaded file, configure the MATLAB installation by uncommenting lines that start with a single '#' and updating their values.

Update these sections:

  • SPECIFY DESTINATION FOLDER

    Uncomment the destinationFolder line and set an installation folder.

    Linux or macOS:

    destinationFolder=/home/<USER>/matlab
    

    Windows (run as administrator):

    destinationFolder="C:\Users\<USER>\matlab"
    
  • INSTALL PRODUCTS

    Uncomment the product.MATLAB and product.Simulink lines for installing MATLAB and Simulink.

    product.MATLAB
    # ...
    product.Simulink
  • INSTALL SUPPORT PACKAGES

    Uncomment the product.Deep_Learning_Toolbox_Model_for_ResNet-50_Network line to install a Deep Learning Toolbox support package. During installation, mpm automatically installs this support package's required product, Deep Learning Toolbox.

    product.Deep_Learning_Toolbox_Model_for_ResNet-50_Network

Save the file. Then, install the products and support package.

Linux or macOS:

./mpm install --inputfile /path/to/file/mpm_input_<release>.txt

Windows (run as administrator):

.\mpm.exe install --inputfile "\path\to\file\mpm_input_<release>.txt"

Since R2022a

Install products from an ISO image mounted to a drive on your computer. This example runs on Linux and Windows only. On macOS, installing products from a mounted DMG image is not supported.

  1. From MathWorks Downloads, get an ISO image containing MATLAB and Simulink products.

  2. Mount the image. For instructions on mounting an image for your platform, see the support article How do I install MathWorks products using an ISO or DMG image?

  3. Install products from this image by specifying the path to the image in the --source option. For example:

    Linux:

    ./mpm install --source /path/to/mounted/image --destination /home/<USER>/matlab --products MATLAB
    

    Windows (run as administrator):

    .\mpm.exe install --source "\path\to\mounted\image" --destination "C:\Users\<USER>\matlab" --products MATLAB
    

Input Arguments

collapse all

Release to install, specified as a MATLAB release name.

  • To install the latest update of a release, specify only the release name, for example R2024a.

  • To install a specific update release, specify the release name with an update number suffix, for example R2024aU4.

  • To install a release without updates, specify the release name with an update 0 or general release suffix, for example R2024aU0, R2024aGR.

Example: --release R2024a

Destination folder for the installation, specified as an absolute folder path. If the destination folder does not exist, mpm creates it, including any intermediate folders.

If you are installing products or support packages into an existing MATLAB installation, specify the absolute path to the folder where MATLAB is installed.

If you do not set --destination, then mpm installs to the following locations by default, where <release> is the specified --release option.

PlatformDefault Installation Destination
Linux

/usr/share/matlab

Windows

C:\Program Files\MATLAB\<release>

macOS

/Applications/MATLAB/<release>

Products and support packages to install, specified as a list of product and support package names, separated by spaces.

For the full list of products and support packages that mpm can install, open the input file for your release from the mpm-input-files folder on GitHub. Specify products using the format shown in the input file. For example, suppose you want to install Computer Vision Toolbox™. In the input file, the line containing this product is formatted as follows, with spaces replaced by underscores:

#product.Computer_Vision_Toolbox

Copy the text after the dot into the --products option. For example:

--products Computer_Vision_Toolbox

You do not need to specify required products. If a product or support package requires another product, mpm includes it in the installation.

For information on products that mpm is unable to install, see Limitations.

Example: --products MATLAB Simulink Fixed-Point_Designer installs MATLAB, Simulink, and Fixed-Point Designer™.

Example: --products Deep_Learning_Toolbox installs Deep Learning Toolbox and its required product, MATLAB.

Installation source, specified as an absolute file path to one of the following installation sources:

If you do not set --source, then mpm downloads the product files from MathWorks.

Example: --source /mnt/mathworks/matlab.iso

Input file for configuring your installation, specified as the absolute path to a valid input file.

Download a template input file for your release from the mpm-input-files folder on GitHub. Using this file, you can specify the installation folder and select the products and support packages you want to install without having to enter them at the command line. You must specify --inputfile without any other options.

Example: --inputfile /home/<USER>/matlab/mpm_input_r2024a.txt

Since R2023a

Option to omit the installation of the GPU libraries that are included, by default, in installations of Parallel Computing Toolbox. If you do not intend to use GPU computing in MATLAB, specify this option to reduce the size of the installation.

You can install the GPU libraries later by calling a GPU function, such as gpuArray or gpuDevice, in MATLAB.

Option to omit the installation of the default Java Runtime Environment (JRE) used by MATLAB, so that you can set a custom JRE instead. You must set a supported JRE, or MATLAB will not run. For details, see one of these support articles:

R2022a and R2022b only

Option to include documentation with the MATLAB installation.

In R2022a and later releases, the documentation is not included in the installation by default, and MATLAB uses the web documentation instead. To include the documentation in the R2022a and R2022b releases, specify the --doc option. In R2021b and earlier releases, the documentation is included in the installation by default.

To include the documentation in R2023a and later releases, use mpm install-doc.

Limitations

  • mpm supports installing products and support packages for these releases only:

    • Products — R2017b or later

    • Support Packages — R2019a or later

  • Not all MathWorks products are available for all operating systems and architectures that MATLAB supports:

  • mpm supports installing specific update releases only for R2021b and later. For R2021a and earlier, mpm always installs the latest update release.

  • On macOS, installing products from a mounted DMG image is not supported.

  • On Windows, you cannot uninstall products that were installed using mpm.

  • The following products and support packages can only be installed from an ISO image downloaded from MathWorks Downloads, or from product files downloaded using the product installer, by using the --source </full/path/to/source> option.

    ProductsSupport Packages
    • IEC Certification Kit

    • DO Qualification Kit

    • Simulink Code Inspector™

    • Polyspace® Client™ for Ada

    • Polyspace Server™ for Ada

    • Image Acquisition Toolbox™ Support Package for GenICam™ Interface

    • Image Acquisition Toolbox Support Package for GigE Vision® Hardware

    • Simulink Coder™ Support Package for BBC micro:bit

    • MATLAB Support Package for IP Cameras

    • New Desktop for MATLAB

    • MATLAB Support Package for Parrot® Drones

    • MATLAB Support Package for Ryze Tello Drones

    • Simulink Real-Time™ QNX Target Support

More About

collapse all

Resolve Common Installation Issues

If you have trouble installing products using mpm, review these common issues that might occur during the installation process:

If you continue to have problems, contact support. Provide any error messages, log files, or screenshots related to the problem in your help request.

Tips

  • You can specify options using either an equal sign (=) or a space between the option name and its parameter value. For example, --destination=/full/path/to/destination is equivalent to --destination /full/path/to/destination.