nvidia存档
解决火狐不能打开网页问题
方法一
输入sudo gedit /etc/resolv.conf
将nameserver x.x.x.x部分改成nameserver 8.8.8.8保存
原文件
# This is /run/systemd/resolve/stub-resolv.conf managed by man:systemd-resolved(8).
# Do not edit.
#
# This file might be symlinked as /etc/resolv.conf. If you're looking at
# /etc/resolv.conf and seeing this text, you have followed the symlink.
#
# This is a dynamic resolv.conf file for connecting local clients to the
# internal DNS stub resolver of systemd-resolved. This file lists all
# configured search domains.
#
# Run "resolvectl status" to see details about the uplink DNS servers
# currently in use.
#
# Third party programs should typically not access this file directly, but only
# through the symlink at /etc/resolv.conf. To manage man:resolv.conf(5) in a
# different way, replace this symlink by a static file or a different symlink.
#
# See man:systemd-resolved.service(8) for details about the supported modes of
# operation for /etc/resolv.conf.
nameserver 127.0.0.53
options edns0 trust-ad
search .
已修改
未解决
方法二
sudo apt-get install firefox
报了很多错,跟之前安装cucnn一样
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
firefox is already the newest version (1:1snap1-0ubuntu2).
firefox set to manually installed.
The following packages were automatically installed and are no longer required:
libaccinj64-11.5 libcub-dev libcublas11 libcublaslt11
libcudart11.0 libcufft10 libcufftw10 libcupti-dev
libcupti-doc libcupti11.5 libcurand10 libcusolver11
libcusolvermg11 libcusparse11 libnppc11 libnppial11
libnppicc11 libnppidei11 libnppif11 libnppig11 libnppim11
libnppist11 libnppisu11 libnppitc11 libnpps11 libnvblas11
libnvidia-egl-wayland1 libnvidia-egl-wayland1:i386
libnvjpeg11 libnvrtc-builtins11.5 libnvrtc11.2
libnvtoolsext1 libnvvm4 libthrust-dev libvdpau-dev
linux-headers-6.8.0-45-generic
linux-hwe-6.8-headers-6.8.0-45 linux-hwe-6.8-tools-6.8.0-45
linux-image-6.8.0-45-generic linux-modules-6.8.0-45-generic
linux-modules-extra-6.8.0-45-generic
linux-tools-6.8.0-45-generic node-html5shiv nsight-compute
nsight-compute-target nvidia-cuda-gdb
nvidia-cuda-toolkit-doc nvidia-firmware-550-550.120
nvidia-opencl-dev ocl-icd-opencl-dev opencl-c-headers
opencl-clhpp-headers
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.
8 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up nvidia-dkms-515 (515.43.04-0ubuntu1) ...
update-initramfs: deferring update (trigger activated)
A modprobe blacklist file has been created at /etc/modprobe.d to prevent Nouveau
from loading. This can be reverted by deleting the following file:
/etc/modprobe.d/nvidia-graphics-drivers.conf
A new initrd image has also been created. To revert, please regenerate your
initrd by running the following command after deleting the modprobe.d file:
`/usr/sbin/initramfs -u`
*****************************************************************************
*** Reboot your computer and verify that the NVIDIA graphics driver can ***
*** be loaded. ***
*****************************************************************************
INFO:Enable nvidia
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/dell_latitude
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/put_your_quirks_here
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/lenovo_thinkpad
Removing old nvidia-515.43.04 DKMS files...
Deleting module nvidia-515.43.04 completely from the DKMS tree.
Loading new nvidia-515.43.04 DKMS files...
Building for 6.8.0-48-generic
Building for architecture x86_64
Building initial module for 6.8.0-48-generic
ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/nvidia-kernel-source-515.0.crash'
Error! Bad return status for module build on kernel: 6.8.0-48-generic (x86_64)
Consult /var/lib/dkms/nvidia/515.43.04/build/make.log for more information.
dpkg: error processing package nvidia-dkms-515 (--configure):
installed nvidia-dkms-515 package post-installation script subprocess returned error exit status 10
dpkg: dependency problems prevent configuration of cuda-drivers-515:
cuda-drivers-515 depends on nvidia-dkms-515 (>= 515.43.04); however:
Package nvidia-dkms-515 is not configured yet.
dpkg: error processing package cuda-drivers-515 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-drivers:
cuda-drivers depends on cuda-drivers-515 (= 515.43.04-1); however:
Package cuda-drivers-515 is not configured yet.
dpkg: error processing package cuda-drivers (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of nvidia-driver-515:
nvidia-driver-515 depends on nvidia-dkms-515 (= 515.43.04-0ubuntu1); however:
Package nvidia-dkms-515 is not configured yet.
dpkg: error processing package nvidia-driver-515 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-runtime-11-7:
cuda-runtime-11-7 depends on cuda-drivers (>No apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
= 515.43.04); however:
Package cuda-drivers is not configured yet.
dpkg: error processing package cuda-runtime-11-7 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-demo-suite-11-7:
cuda-demo-suite-11-7 depends on cuda-runtime-11-7; however:
Package cuda-runtime-11-7 is not configured yet.
dpkg: error processing package cuda-demo-suite-11-7 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-11-7:
cuda-11-7 depends on cuda-runtime-11-7 (>= 11.7.0); however:
Package cuda-runtime-11-7 is not configured yet.
cuda-11-7 depends on cuda-demo-suite-11-7 (>= 11.7.50); however:
Package cuda-demo-suite-11-7 is not configured yet.
dpkg: error processing package cuda-11-7 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda:
cuda depends on cuda-11-7 (>= 11.7.0); however:
Package cuda-11-7 is not configured yet.
dpkg: error processing package cuda (--configure):
dependency problems - leaving unconfigured
Processing triggers for initramfs-tools (0.140ubuntu13.5) ...
update-initramfs: Generating /boot/initrd.img-6.8.0-48-generic
I: The initramfs will attempt to resume from /dev/nvme0n1p8
I: (UUID=eeb86b14-3bb0-4b33-93ab-ea9d396c228c)
I: Set the RESUME variable to override this.
Errors were encountered while processing:
nvidia-dkms-515
cuda-drivers-515
cuda-drivers
nvidia-driver-515
cuda-runtime-11-7
cuda-demo-suite-11-7
cuda-11-7
cuda
E: Sub-process /usr/bin/dpkg returned an error code (1)
您遇到的错误表明在安装或配置NVIDIA驱动和CUDA相关包时出现了问题。nvidia-dkms-515包的配置脚本失败,并返回了错误状态10,这导致了后续依赖它的包(如cuda-drivers-515、cuda-drivers、nvidia-driver-515等)都无法正确配置。
这里有几个可能的解决步骤:
查看日志:
查看/var/log/dpkg.log或/var/log/syslog中的相关错误信息,可能会提供更多关于为什么nvidia-dkms-515配置失败的线索。
清理和修复:
使用dpkg的--configure -a选项尝试修复所有未配置的包:
bash复制代码sudo dpkg --configure -a
如果这不起作用,尝试使用apt的--fix-broken选项:
bash复制代码sudo apt install --fix-broken
重新安装NVIDIA驱动:
如果上述步骤仍然无法解决问题,您可能需要完全卸载NVIDIA驱动和CUDA相关包,然后重新安装它们。这可以通过以下命令完成:
bash复制代码sudo apt remove --purge '^nvidia-' '^cuda-' sudo apt autoremove sudo apt install nvidia-driver-515
注意:在卸载之前,请确保您有适当的备份,并了解如何在没有图形界面的情况下恢复系统(例如,通过SSH连接或使用恢复模式)。
检查内核版本:
确保您的内核版本与NVIDIA驱动兼容。有时,新内核的发布可能尚未被NVIDIA驱动支持。
查看NVIDIA官方文档:
NVIDIA官方可能提供了关于特定驱动版本和Linux发行版兼容性的信息。
禁用Nouveau驱动:
确保Nouveau驱动(开源NVIDIA驱动)已被禁用。这通常通过在引导加载器(如GRUB)中添加nouveau.modeset=0参数来完成。
使用DKMS:
nvidia-dkms包使用DKMS(动态内核模块支持)来构建和安装与当前运行的内核匹配的驱动模块。如果DKMS配置失败,可能是因为缺少构建环境或内核头文件。
查看硬件兼容性:
确保您的GPU与尝试安装的驱动版本兼容。
如果问题仍然存在,您可能需要考虑在NVIDIA的官方论坛或Linux发行版的社区论坛上寻求帮助,那里可能有其他用户遇到了类似的问题并找到了解决方案。
要重新装驱动咯