如何从软件更新程序中删除 nvidia 驱动程序?

如何从软件更新程序中删除 nvidia 驱动程序?

我已从笔记本电脑中完全删除了 NVidia 驱动程序,因为它无法与我的显卡正常工作,因此我切换为使用英特尔显卡。

sudo apt-get purge nvidia*

但是,在软件更新期间,总是建议我再次安装 nvidia 依赖项。我该如何避免这种情况?

在此处输入图片描述

dpkg -l | grep nvidia 给出了卸载后剩余的相关库:

ii  libnvidia-cfg1-390:amd64                             390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA binary OpenGL/GLX configuration library 
ii  libnvidia-common-390                                 390.48-0ubuntu0~gpu18.04.1                     all          Shared files used by the NVIDIA libraries 
ii  libnvidia-compute-390:amd64                          390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA libcompute package 
ii  libnvidia-compute-390:i386                           390.42-0ubuntu1+gpu18.04.1                     i386         NVIDIA libcompute package 
ii  libnvidia-decode-390:amd64                           390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA Video Decoding runtime libraries 
ii  libnvidia-decode-390:i386                            390.42-0ubuntu1+gpu18.04.1                     i386         NVIDIA Video Decoding runtime libraries 
ii  libnvidia-encode-390:amd64                           390.42-0ubuntu1+gpu18.04.1                     amd64        NVENC Video Encoding runtime library 
ii  libnvidia-encode-390:i386                            390.42-0ubuntu1+gpu18.04.1                     i386         NVENC Video Encoding runtime library 
ii  libnvidia-fbc1-390:amd64                             390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA OpenGL-based Framebuffer Capture runtime library 
ii  libnvidia-fbc1-390:i386                              390.42-0ubuntu1+gpu18.04.1                     i386         NVIDIA OpenGL-based Framebuffer Capture runtime library 
ii  libnvidia-gl-390:amd64                               390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA OpenGL/GLX/EGL/GLES GLVND libraries and Vulkan ICD 
ii  libnvidia-gl-390:i386                                390.42-0ubuntu1+gpu18.04.1                     i386         NVIDIA OpenGL/GLX/EGL/GLES GLVND libraries and Vulkan ICD 
ii  libnvidia-ifr1-390:amd64                             390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA OpenGL-based Inband Frame Readback runtime library 
ii  libnvidia-ifr1-390:i386                              390.42-0ubuntu1+gpu18.04.1                     i386         NVIDIA OpenGL-based Inband Frame Readback runtime library 
ii  xserver-xorg-video-nvidia-390                        390.42-0ubuntu1+gpu18.04.1                     amd64        NVIDIA binary Xorg driver

答案1

根据dpkg -l | grep nvidia输出,nvidia 的一些库未被删除。

因此运行此命令来清除它们:

sudo apt purge libnvidia* xserver-xorg-video-nvidia-390

并且运行以下命令autoremove删除不必要的包:

sudo apt autoremove

相关内容