当前位置:网站首页>Nvidia 显卡 Failed to initialize NVML Driver/library version mismatch 错误解决方案
Nvidia 显卡 Failed to initialize NVML Driver/library version mismatch 错误解决方案
2022-07-02 16:19:00 【u013250861】
本文记录错误 Failed to initialize NVML: Driver/library version mismatch 错误解决方案。
问题复现
$ nvidia-smi
-->
Failed to initialize NVML: Driver/library version mismatch
问题分析
- NVIDIA 内核驱动版本与系统驱动不一致
查看显卡驱动所使用的内核版本
cat /proc/driver/nvidia/version
-->
NVRM version: NVIDIA UNIX x86_64 Kernel Module 430.34 Wed Jun 26 12:19:48 CDT 2019
GCC version: gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.12)
- 内核版本 Kernel Module 为 430.34, 系统内核 16.04.12
查看系统驱动日志
cat /var/log/dpkg.log | grep nvidia
-->
2021-03-30 14:04:55 install libnvidia-compute-460-server:amd64 <none> 460.32.03-0ubuntu0.18.04.2
2021-03-30 14:04:55 status half-installed libnvidia-compute-460-server:amd64 460.32.03-0ubuntu0.18.04.2
2021-03-30 14:04:57 status unpacked libnvidia-compute-460-server:amd64 460.32.03-0ubuntu0.18.04.2
2021-03-30 14:04:57 status unpacked libnvidia-compute-460-server:amd64 460.32.03-0ubuntu0.18.04.2
2021-03-30 14:05:15 install nvidia-cuda-dev:amd64 <none> 9.1.85-3ubuntu1
2021-03-30 14:05:15 status half-installed nvidia-cuda-dev:amd64 9.1.85-3ubuntu1
2021-03-30 14:05:34 status unpacked nvidia-cuda-dev:amd64 9.1.85-3ubuntu1
2021-03-30 14:05:34 status unpacked nvidia-cuda-dev:amd64 9.1.85-3ubuntu1
2021-03-30 14:05:34 install nvidia-cuda-doc:all <none> 9.1.85-3ubuntu1
2021-03-30 14:05:34 status half-installed nvidia-cuda-doc:all 9.1.85-3ubuntu1
2021-03-30 14:05:38 status unpacked nvidia-cuda-doc:all 9.1.85-3ubuntu1
2021-03-30 14:05:38 status unpacked nvidia-cuda-doc:all 9.1.85-3ubuntu1
2021-03-30 14:05:38 install nvidia-cuda-gdb:amd64 <none> 9.1.85-3ubuntu1
2021-03-30 14:05:38 status half-installed nvidia-cuda-gdb:amd64 9.1.85-3ubuntu1
2021-03-30 14:05:39 status unpacked nvidia-cuda-gdb:amd64 9.1.85-3ubuntu1
2021-03-30 14:05:39 status unpacked nvidia-cuda-gdb:amd64 9.1.85-3ubuntu1
2021-03-30 14:05:39 install nvidia-profiler:amd64 <none> 9.1.85-3ubuntu1
2021-03-30 14:05:39 status half-installed nvidia-profiler:amd64 9.1.85-3ubuntu1
可以看到曾经安装过系统内核 18.04 的 460.32 的驱动
查看驱动程序
sudo dpkg --list | grep nvidia-*
-->
ii libnvidia-compute-460-server:amd64 460.32.03-0ubuntu0.18.04.2 amd64 NVIDIA libcompute package
ii libnvidia-container-tools 1.0.5-1 amd64 NVIDIA container runtime library (command-line tools)
ii libnvidia-container1:amd64 1.0.5-1 amd64 NVIDIA container runtime library
ii nvidia-container-runtime 3.1.4-1 amd64 NVIDIA container runtime
ii nvidia-container-toolkit 1.0.5-1 amd64 NVIDIA container runtime hook
ii nvidia-cuda-dev 9.1.85-3ubuntu1 amd64 NVIDIA CUDA development files
ii nvidia-cuda-doc 9.1.85-3ubuntu1 all NVIDIA CUDA and OpenCL documentation
- 可以看到系统安装了ubuntu 内核18.04 下的 nvidia 460 驱动
- 实际系统内核版本与驱动需求的版本不一致是问题产生的根源
解决方案
- 卸载现有驱动,重新安装
卸载驱动
sudo /usr/bin/nvidia-uninstall
sudo apt-get --purge remove nvidia-*
sudo apt-get purge nvidia*
sudo apt-get purge libnvidia*
直到命令不输出任何内容
sudo dpkg --list | grep nvidia-*
重新安装
sudo chmod a+x NVIDIA-Linux-x86_64-450.80.02.run
sudo ./NVIDIA-Linux-x86_64-450.80.02.run -no-x-check -no-nouveau-check -no-opengl-files
–no-opengl-files 只安装驱动文件,不安装OpenGL文件
–no-x-check 安装驱动时不检查X服务
–no-nouveau-check 安装驱动时不检查nouveau查看驱动更新结果
$ nvidia-smi

参考资料
https://blog.csdn.net/qq_40200387/article/details/90341107
https://www.zywvvd.com/2020/12/03/linux/driver/nvidia-driver-install-linux/
边栏推荐
- [golang | grpc] generate certificates using OpenSSL
- Huimang micro IO MCU ft60f011a-rb
- em120.gige. h
- Tips for self defined packaging of Yingguang SCM 003 burner
- 求求你们,别再刷 Star 了!这跟“爱国”没关系!
- Does pytorch support 32 bits?
- 好评率计算
- The price is only 40 yuan. Pico development board of raspberry pie is added with WiFi module, and it is out of stock as soon as it comes into the market
- Keras深度学习实战——基于VGG19模型实现性别分类
- Problems needing attention in the development and debugging of Yingguang single chip microcomputer
猜你喜欢

Asemi rectifier bridge umb10f parameters, umb10f specifications, umb10f package

Yingguang single chip microcomputer development specification pmc131 with AD chip to detect battery voltage single chip microcomputer sop8/14

台湾飞凌FM8PB513B单片机提供单片机方案开发 产品设计

详解Kubernetes网络模型

使用Zadig从0到1搭建持续交付平台

Viewing technological changes through Huawei Corps (VI): smart highway
![[golang | grpc] generate certificates using OpenSSL](/img/a6/0c9c80cc24c5f8585051e00e73072f.png)
[golang | grpc] generate certificates using OpenSSL
![[target tracking] |siamfc](/img/40/3419761d2eb7f1193b699cdd431761.png)
[target tracking] |siamfc

Hbuilderx runs to the mobile phone or simulator and prompts that the device is not found

【Zuul】com.netflix.zuul.exception.ZuulException: Hystrix Readed time out
随机推荐
D constructor problem
[today in history] July 2: BitTorrent came out; The commercial system linspire was acquired; Sony deploys Playstation now
977. Square of ordered array
In Linux, MySQL sets the job task to start automatically
MySQL -- basic operation of database
铁塔安全监测系统 无人值守倾角振动监测系统
应广单片机(MCU单片机科普)
Modbus protocol communication exception
Yilong em78p153k dip14 MCU
How can you omit a large number of switch statements
Outsourcing for five years, abandoned
架构设计——ID生成器「建议收藏」
应广单片机PMS150/PMC150/PMS150C消费类单片机
515. 在每个树行中找最大值
深入理解ThreadLocal
567.字符串中的排列
Many scenic spots are temporarily closed due to the typhoon. The provincial culture and tourism department reminds you to pay attention to safety!
Linux中,mysql设置job任务自动启动
Development and application case of pms134 scheme of Yingguang single chip microcomputer with original packaging
Troubleshooting ideas that can solve 80% of faults