更新内核时 Nvidia init 模块未重建

更新内核时 Nvidia init 模块未重建

升级 Linux 内核后,我必须重新安装 nvidia-driver。否则显示器将无法使用 GPU。

现在我需要在内核更新后手动执行以下操作

sudo apt remove nvidia-driver-396
sudo apt autoremove
sudo apt install nvidia-driver-396

这是系统信息

➜  ~ cat /etc/lsb-release                                     
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.1 LTS"

以及 GPU 卡

➜  ~ nvidia-smi   
Wed Sep 12 09:19:56 2018       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 396.54                 Driver Version: 396.54                    |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GTX 108...  Off  | 00000000:01:00.0  On |                  N/A |
| 44%   42C    P2    61W / 250W |    531MiB / 11175MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+

dkms已安装。

➜  R-Net git:(master) ✗ sudo apt install dkms         
[sudo] password for vimos: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
dkms is already the newest version (2.3-3ubuntu9.2).
dkms set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 51 not upgraded.

dkms status输出一些奇怪的错误

➜  coqa_rnet git:(master) ✗ dkms status     
anbox, 1, 4.15.0-33-generic, x86_64: installedError! Could not locate dkms.conf file.
File:  does not exist.

anbox, 1, 4.15.0-34-generic, x86_64: installed

我是否缺少该模块的任何配置?

谢谢你!

相关内容