amd 显卡GPU驱动在ubuntu22.04驱动安装 7600x显卡驱动安装

AMD显卡GPU驱动在ubuntu22.04驱动安装

在公司新配置了台最新的7600x CPU带集显的UBUNTU22.04电脑,用于做代码的编译服务器。发现Ubuntu22.04并没有默认安装AMD 集成显卡的GPU驱动,有的只是最简单的驱动。网上收集了许多AMD gpu驱动的安装重新,最新的型号显卡驱动都没有相关教程。我一开始也是遇到各种坑,不过最终也是搞定了。我这边讲我的采坑经验分析给大家。

1,下载AMD(RDNA 2)显卡驱动

通过 AMD驱动官网:https://www.amd.com/en/support/linux-drivers 下载最新的AMD GPU显卡驱动命令包。
选择对应linux版本的驱动,我这边是Ubuntu22.04。
AMD的最新linux驱动都是通过amdgpu-install命令来安装,所以我们这边只要下载最新的amdgpu-install安装包即可。

amd 显卡GPU驱动在ubuntu22.04驱动安装 7600x显卡驱动安装

2,用amdgpu-install安装显卡驱动

安装过程中,会报一个错误,不要理会这个错误。但是最终amdgpu-install也是可以正常使用的。

sudo apt install ./amdgpu-install_5.4.50403-1_all.deb
sudo apt install ./amdgpu-install_5.4.50403-1_all.deb
sudo apt install ./amdgpu-install_5.4.50403-1_all.deb

3,通过运行amdgpu-install 安装GPU驱动

我们通过amdgpu-install -h看看这个命令的协助。

ubuntu@ubuntu-caimore:~/hd$ amdgpu-install -h
Usage: amdgpu-install [options...]
Options:
-h|--help Display this help message
--rocmrelease= Install a specific ROCm release. By default only
one release of ROCm can be installed. Using this
option will allow installation of multiple releases.
Note: when used during uninstall, the specific rocm
release will be removed. Use --rocmrelease=all
to uninstall all rocm releases.
--dryrun Print list of commands to run and exit
--pro (DEPRECATED) Install legacy OpenGL, pro Vulkan, and
open source multimedia. This is equivalent to:
amdgpu-install --usecase=workstation --vulkan=pro
--usecase= Install a set of libraries for a specific use case
--list-usecase Show all available usecases and descriptions
--opencl= Install a specific OpenCL implementation. This
option implies the addition of the opencl usecase.
Available implementations:
rocr (ROCr/KFD based OpenCL)
legacy (Legacy OpenCL)
--opengl= Install a specific OpenGL implementation. This
option implies the addition of the graphics usecase.
Available implementations:
mesa (Open source Mesa 3D)
oglp (Cloud/Other use, Ubuntu 20.04 only)
--vulkan= Install a specific vulkan implementation
Available implementations:
amdvlk (AMD open source implementation)
pro (AMD closed source implementation)
--no-dkms Do not install dkms and use built-in kernel driver
--no-32 Do not install 32 bit graphics runtime support
--accept-eula Accept EULA for this run only (for non-free install)
Note: only use this option if you accept the EULA
--uninstall Uninstall the graphics driver
Options --opencl/--vulkan/--usecase can be used together, e.g.:
amdgpu-install --usecase=graphics --vulkan=amdvlk --opencl=rocr
Multiple implementations can be selected if comma separated, e.g.:
amdgpu-install --usecase=graphics,opencl --opencl=rocr,legacy --vulkan=amdvlk,pro
Unless the -h|--help option is given, 'apt-get' options may be present
ubuntu@ubuntu-caimore:~/hd$ amdgpu-install -h
Usage: amdgpu-install [options...]

Options:
  -h|--help                Display this help message
  --rocmrelease=           Install a specific ROCm release. By default only
                           one release of ROCm can be installed. Using this
                           option will allow installation of multiple releases.
                           Note: when used during uninstall, the specific rocm
                                 release will be removed. Use --rocmrelease=all
                                 to uninstall all rocm releases.
  --dryrun                 Print list of commands to run and exit
  --pro                    (DEPRECATED) Install legacy OpenGL, pro Vulkan, and
                           open source multimedia. This is equivalent to:
                           amdgpu-install --usecase=workstation --vulkan=pro
  --usecase=               Install a set of libraries for a specific use case
  --list-usecase           Show all available usecases and descriptions
  --opencl=                Install a specific OpenCL implementation. This
                           option implies the addition of the opencl usecase.
                           Available implementations:
                           rocr        (ROCr/KFD based OpenCL)
                           legacy      (Legacy OpenCL)
  --opengl=                Install a specific OpenGL implementation. This
                           option implies the addition of the graphics usecase.
                           Available implementations:
                           mesa        (Open source Mesa 3D)
                           oglp        (Cloud/Other use, Ubuntu 20.04 only)
  --vulkan=                Install a specific vulkan implementation
                           Available implementations:
                           amdvlk      (AMD open source implementation)
                           pro         (AMD closed source implementation)
  --no-dkms                Do not install dkms and use built-in kernel driver
  --no-32                  Do not install 32 bit graphics runtime support
  --accept-eula            Accept EULA for this run only (for non-free install)
                           Note: only use this option if you accept the EULA
  --uninstall              Uninstall the graphics driver

  Options --opencl/--vulkan/--usecase can be used together, e.g.:
  amdgpu-install --usecase=graphics --vulkan=amdvlk --opencl=rocr

  Multiple implementations can be selected if comma separated, e.g.:
  amdgpu-install --usecase=graphics,opencl --opencl=rocr,legacy --vulkan=amdvlk,pro

  Unless the -h|--help option is given, 'apt-get' options may be present
ubuntu@ubuntu-caimore:~/hd$ amdgpu-install -h Usage: amdgpu-install [options...] Options: -h|--help Display this help message --rocmrelease= Install a specific ROCm release. By default only one release of ROCm can be installed. Using this option will allow installation of multiple releases. Note: when used during uninstall, the specific rocm release will be removed. Use --rocmrelease=all to uninstall all rocm releases. --dryrun Print list of commands to run and exit --pro (DEPRECATED) Install legacy OpenGL, pro Vulkan, and open source multimedia. This is equivalent to: amdgpu-install --usecase=workstation --vulkan=pro --usecase= Install a set of libraries for a specific use case --list-usecase Show all available usecases and descriptions --opencl= Install a specific OpenCL implementation. This option implies the addition of the opencl usecase. Available implementations: rocr (ROCr/KFD based OpenCL) legacy (Legacy OpenCL) --opengl= Install a specific OpenGL implementation. This option implies the addition of the graphics usecase. Available implementations: mesa (Open source Mesa 3D) oglp (Cloud/Other use, Ubuntu 20.04 only) --vulkan= Install a specific vulkan implementation Available implementations: amdvlk (AMD open source implementation) pro (AMD closed source implementation) --no-dkms Do not install dkms and use built-in kernel driver --no-32 Do not install 32 bit graphics runtime support --accept-eula Accept EULA for this run only (for non-free install) Note: only use this option if you accept the EULA --uninstall Uninstall the graphics driver Options --opencl/--vulkan/--usecase can be used together, e.g.: amdgpu-install --usecase=graphics --vulkan=amdvlk --opencl=rocr Multiple implementations can be selected if comma separated, e.g.: amdgpu-install --usecase=graphics,opencl --opencl=rocr,legacy --vulkan=amdvlk,pro Unless the -h|--help option is given, 'apt-get' options may be present

直接运行这个命令会报各种包依赖错误。

amd 显卡GPU驱动在ubuntu22.04驱动安装 7600x显卡驱动安装

正确的安装r5 7600x GPU方式:

由于我们目前安装的操作系统,一般都是64位的。而下载的AMD GPU驱动,默认都是32位,所以我们需要添加–no-32选项。

amdgpu-install --no-32
amdgpu-install --no-32
amdgpu-install --no-32

安装成功后,然后重启。目前可以尽情体验有GPU驱动的Ubuntu啦。

注意,64位系统需要加–no-32,否则会安装失败。

至此,我们在UBUNTU22.04上成功安装了AMD 的显卡驱动。

© 版权声明
THE END
如果内容对您有所帮助,就支持一下吧!
点赞0 分享
评论 共1条

请登录后发表评论