Debian multi-version installation#
2025-05-27
3 min read time
Caution
Ensure that the Installation prerequisites are met before installing.
Registering ROCm repositories#
Package signing key#
Download and convert the package signing key.
# Make the directory if it doesn't exist yet.
# This location is recommended by the distribution maintainers.
sudo mkdir --parents --mode=0755 /etc/apt/keyrings
# Download the key, convert the signing-key to a full
# keyring required by apt and store in the keyring directory
wget https://repo.radeon.com/rocm/rocm.gpg.key -O - | \
gpg --dearmor | sudo tee /etc/apt/keyrings/rocm.gpg > /dev/null
Note
The GPG key may change; ensure it is updated when installing a new release. If the key signature verification fails while updating, re-add the key from the ROCm to the apt repository as mentioned above.
Register packages#
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/amdgpu/6.4.1/ubuntu jammy main" \
| sudo tee /etc/apt/sources.list.d/amdgpu.list
# Note: There is NO trailing .0 in the patch version for repositories
for ver in 6.4.1 6.4; do
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/rocm.gpg] https://repo.radeon.com/rocm/apt/$ver jammy main" \
| sudo tee --append /etc/apt/sources.list.d/rocm.list
done
echo -e 'Package: *\nPin: release o=repo.radeon.com\nPin-Priority: 600' \
| sudo tee /etc/apt/preferences.d/rocm-pin-600
sudo apt update
Installing#
Before proceeding with a multi-version ROCm installation, you must remove ROCm packages that were previously installed from a single-version installation to avoid conflicts.
# Note: There IS a trailing .0 in the patch version for packages
for ver in 6.4.1 6.4.0; do
sudo apt install rocm$ver
done
Note
For versions earlier than ROCm 6.0.0, use rocm-hip-sdk
instead of rocm
(for example, rocm-hip-sdk5.7.1
).
Complete the Post-installation instructions.
Tip
For a single-version installation of the latest ROCm version on Debian, use the steps in Registering ROCm repositories and Installing.
Uninstalling#
Uninstall specific meta packages#
# Note: There IS a trailing .0 in the patch version for packages
for ver in 6.4.1 6.4.0; do
sudo apt autoremove rocm$ver
done
Uninstall ROCm packages#
# Note: There IS a trailing .0 in the patch version for packages
for ver in 6.4.1 6.4.0; do
sudo apt autoremove rocm-core$ver
done
Remove ROCm repositories#
# Remove ROCm and AMDGPU repositories
sudo rm /etc/apt/sources.list.d/rocm.list
sudo rm /etc/apt/sources.list.d/amdgpu.list
# Clear the cache and clean the system
sudo rm -rf /var/cache/apt/*
sudo apt clean all
sudo apt update
# Restart the system
sudo reboot