Install Ryzen Software for Linux with ROCm#

The ROCm™ Software Stack and other Ryzen™ software for Linux components are installed using the amdgpu-install script to assist you in the installation of a coherent set of stack components.

  • Simplifies the installation of the AMDGPU stack by encapsulating the distribution-specific package installation logic and by using command line options.

  • Performs post-install checks to verify whether the installation was performed successfully.

  • Installs the uninstallation script to allow you to remove the ROCm stack from the system by using a single command.

The script is provided by the installer package. See Compatibility matrices for support information.

Prepare the system#

For ROCm on Ryzen, it is required to operate on the 6.14 OEM kernel.

  1. To install the kernel, run the following command:

    sudo apt update && sudo apt-get install linux-oem-24.04c
    
  2. Once installation is complete, reboot your system and boot into the 6.14 OEM kernel:

    uname -r
    

    Note
    This returns a 6.14.0 based string.

  3. Ensure that the system is up to date:

    sudo apt upgrade -y
    

Install AMD Unified Driver Package Repositories and Installer Script#

Select the applicable Ubuntu® version to download and install the amdgpu-install script on the system.

Ubuntu® 24.04#

Enter the following commands to install the installer script for Ubuntu® version 24.04:

sudo apt update
wget https://repo.radeon.com/amdgpu-install/6.4.4/ubuntu/noble/amdgpu-install_6.4.60404-1_all.deb
sudo apt install ./amdgpu-install_6.4.60404-1_all.deb

Install AMD ROCm package#

Run the installer script with appropriate --usecase parameters to install the components once the Unified Driver Deb Package repositories are installed.

Set up ROCm usecase#

The --no-dkms parameter must be passed, as inbox drivers are required for ROCm on Ryzen.

  1. Run the following command to install ROCm:

    amdgpu-install -y --usecase=rocm --no-dkms
    

    Note:
    The -y option installs non-interactively. This step may take several minutes, depending on internet connection and system speed.
    Look out for output warning or errors that indicate an unsuccessful installation.

  2. Reboot the system:

    sudo reboot
    

See Using the amdgpu-install script for more information.

Next, set Groups permissions.

Set Groups permissions#

Once the driver is installed, add any current user to the render and video groups to access GPU resources.

Reboot for group changes to take effect.

  1. Add User to Render and Video Groups Enter the following command to check groups in the system:

    groups
    
  2. Add the user to the render and video group using the command:

    sudo usermod -a -G render,video $LOGNAME
    
  3. Reboot the system:

    sudo reboot
    

See Setting Permissions for Groups for more information.

Post-install verification checks#

Run these post-installation checks to verify that the installation is complete:

  1. Verify that the current user is added to the render and video groups:

    groups
    

    Expected result:

    <username> adm cdrom sudo dip video plugdev render lpadmin lxd sambashare
    

    <username> indicates the current user, and this result will vary in your environment.

  2. Check if the GPU is listed as an agent:

    rocminfo
    

    Expected result:

    *******
    Agent 2
    *******
      Name:                    gfx1151
      Uuid:                    GPU-XX
      Marketing Name:          Radeon 8050S Graphics
      Vendor Name:             AMD
      [...]
    

    See Installing the all open use case for additional troubleshooting tips.

Configure shared memory#

ROCm utilizes a shared system memory pool, and is configured by default to half the system memory.

This amount can be increased by changing the kernel’s Translation Table Manager (TTM) page setting, available at /sys/module/ttm/parameters/pages_limit. The units are in pages, and must be converted. A helper script is available to assist with configuration.

  1. Install the pipx utility.

    sudo apt install pipx
    
  2. Add the path for pipx installed wheels into the system search path.

    pipx ensurepath
    
  3. Install the amd-debug-tools wheel from PyPi.

    pipx install amd-debug-tools
    
  4. Run the amd-ttm tool to query the current settings for shared memory.

    amd-ttm
    
  5. Reconfigure shared memory settings by using the --set argument (units in GB).

    amd-ttm --set <NUM>
    
  6. Reboot the system for changes to take effect.

amd-ttm usage examples#

Query effective memory settings in the current kernel

amd-ttm
💻 Current TTM pages limit: 16469033 pages (62.82 GB)
💻 Total system memory: 125.65 GB

Set usable shared memory

 amd-ttm --set 100
🐧 Successfully set TTM pages limit to 26214400 pages (100.00 GB)
🐧 Configuration written to /etc/modprobe.d/ttm.conf
 NOTE: You need to reboot for changes to take effect.
Would you like to reboot the system now? (y/n): y

Clear TTM setting and revert to kernel defaults

 amd-ttm --clear
🐧 Configuration /etc/modprobe.d/ttm.conf removed
Would you like to reboot the system now? (y/n): y

Advanced install methods#

For advanced install methods, such as Multi-Version and Package Manager, refer to AMD GPU Install Script.

Uninstall ROCm#

Run the following command to uninstall the ROCm software stack and other Ryzen software for Linux components:

sudo amdgpu-uninstall

Upgrade to newer Ryzen Software versions for Linux#

The recommended method to upgrade is to uninstall, followed by an install.

Note
Ryzen Software for Linux does not support in-place upgrades.