ubuntu22.04安装NVIDIA驱动

文章目录


前言

ubuntu22.04操作系统安装NVIDIA驱动,使用nvidia-smi查看加速卡使用情况。


一、环境

操作系统版本:Ubuntu 22.04.3 LTS (GNU/Linux 5.15.0-119-generic x86_64)

nvidia-driver版本:nvidia-driver-535

二、安装步骤

2.1 获取驱动版本

shell 复制代码
 ubuntu-drivers devices

输出

shell 复制代码
== /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 ==
modalias : pci:v000010DEd00002684sv00001458sd000040C0bc03sc00i00
vendor   : NVIDIA Corporation
driver   : nvidia-driver-545-open - distro non-free
driver   : nvidia-driver-535-server-open - distro non-free
driver   : nvidia-driver-535-server - distro non-free
driver   : nvidia-driver-545 - distro non-free
driver   : nvidia-driver-535 - distro non-free
driver   : nvidia-driver-550 - distro non-free recommended
driver   : nvidia-driver-535-open - distro non-free
driver   : nvidia-driver-550-open - distro non-free
driver   : xserver-xorg-video-nouveau - distro free builtin

2.2 安装驱动

shell 复制代码
apt install nvidia-driver-535 -y

apt update 

#更新号之后重启机器
reboot

3.查看安装结果

shell 复制代码
nvidia-smi 

输出

shell 复制代码
Mon Sep  9 08:32:21 2024       
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 535.183.01             Driver Version: 535.183.01   CUDA Version: 12.2     |
|-----------------------------------------+----------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |         Memory-Usage | GPU-Util  Compute M. |
|                                         |                      |               MIG M. |
|=========================================+======================+======================|
|   0  NVIDIA GeForce RTX 4090        Off | 00000000:01:00.0 Off |                  Off |
|  0%   43C    P8              29W / 450W |      1MiB / 24564MiB |      0%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+
                                                                                         
+---------------------------------------------------------------------------------------+
| Processes:                                                                            |
|  GPU   GI   CI        PID   Type   Process name                            GPU Memory |
|        ID   ID                                                             Usage      |
|=======================================================================================|
|  No running processes found                                                           |
+---------------------------------------------------------------------------------------+

总结

记录一下ubuntu2204安装NVIDIA驱动

相关推荐
想你依然心痛17 小时前
从监控数据到告警管理:Prometheus与Alertmanager部署实战
ubuntu·prometheus·内网穿透·系统监控·cpolar·告警管理
黑白园18 小时前
解决服务器拒绝连接导致ubuntu镜像无法下载问题 https://mirrors.tuna.tsinghua.edu.cn/ubuntu-releases/
ubuntu
yangpan01120 小时前
ubuntu输入法安装及选择
linux·运维·ubuntu
强里秋千墙外道20 小时前
Ubuntu 开机 Kernel Panic:HWE 内核升级失败 + NVIDIA DKMS 踩坑实录
linux·运维·ubuntu
啊啊啊迈 旋棍1 天前
【译】TypeScript 7 测试版已在 Visual Studio 2026 18.6 Insiders 3 中默认启用
ubuntu·typescript·visual studio
Eloudy2 天前
ubuntu 22.04安装 cuda 12.8.2
linux·运维·ubuntu
接针2 天前
Pycharm远程连接Ubuntu的conda环境
ubuntu·pycharm·conda
漂移的电子2 天前
解决Vue3 + TypeScript + Vite搭建的项目,动态路由页面加载失败的最隐蔽原因
javascript·ubuntu·typescript
其实防守也摸鱼2 天前
镜像校验完成iso完整操作流程(Windows 环境,适配 Ubuntu 22.04 / 24.04)
linux·服务器·windows·学习·ubuntu·教程
一叶龙洲2 天前
向日葵远程Ubuntu,支持隐私屏
linux·运维·ubuntu