OS: Debian stretch
linux kernel: 4.7.0-1-amd64
我的一些 nvidia 软件包之间存在未满足的依赖关系。它们似乎是由apt/dpkg/aptitudelibnvidia-glcore
强制libnvidia-eglcore
它们似乎不起作用。apt-get install -f
给我这个输出:
root@debdesk:~# apt-get upgrade -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
Calculating upgrade... Done
The following packages have been kept back:
libslang2 libslang2-dev linux-headers-4.7.0-1-amd64
linux-headers-4.7.0-1-common linux-image-4.7.0-1-amd64
The following packages will be upgraded:
libnvidia-eglcore libnvidia-glcore
2 upgraded, 0 newly installed, 0 to remove and 5 not upgraded.
13 not fully installed or removed.
Need to get 0 B/12.5 MB of archives.
After this operation, 28.0 MB disk space will be freed.
Do you want to continue? [Y/n] y
Reading changelogs... Done
(Reading database ... 251496 files and directories currently installed.)
Preparing to unpack .../0-libnvidia-glcore_367.44-2_amd64.deb ...
Unpacking libnvidia-glcore:amd64 (367.44-2) over (352.79-10~bpo8+2) ...
dpkg: error processing archive /tmp/apt-dpkg-install-sOf2cJ/0-libnvidia-glcore_367.44-2_amd64.deb (--unpack):
trying to overwrite shared '/usr/share/bug/libnvidia-glcore/script', which is different from other instances of package libnvidia-glcore:amd64
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../1-libnvidia-eglcore_367.44-2_amd64.deb ...
Unpacking libnvidia-eglcore:amd64 (367.44-2) over (352.79-10~bpo8+2) ...
dpkg: error processing archive /tmp/apt-dpkg-install-sOf2cJ/1-libnvidia-eglcore_367.44-2_amd64.deb (--unpack):
trying to overwrite shared '/usr/share/doc/libnvidia-eglcore/changelog.Debian.gz', which is different from other instances of package libnvidia-eglcore:amd64
Errors were encountered while processing:
/tmp/apt-dpkg-install-sOf2cJ/0-libnvidia-glcore_367.44-2_amd64.deb
/tmp/apt-dpkg-install-sOf2cJ/1-libnvidia-eglcore_367.44-2_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
apt-cache policy libnvidia-glcore libnvidia-glcore:i386
打印以下内容:
libnvidia-glcore:
Installed: 352.79-10~bpo8+2
Candidate: 367.44-2
Version table:
367.44-2 500
500 http://ftp.de.debian.org/debian stretch/non-free amd64 Packages
500 http://httpredir.debian.org/debian stretch/non-free amd64 Packages
*** 352.79-10~bpo8+2 100
100 http://httpredir.debian.org/debian jessie-backports/non-free amd64 Packages
100 /var/lib/dpkg/status
libnvidia-glcore:i386:
Installed: 367.44-2
Candidate: 367.44-2
Version table:
*** 367.44-2 500
500 http://ftp.de.debian.org/debian stretch/non-free i386 Packages
500 http://httpredir.debian.org/debian stretch/non-free i386 Packages
100 /var/lib/dpkg/status
352.79-10~bpo8+2 100
100 http://httpredir.debian.org/debian jessie-backports/non-free i386 Packages
前段时间,我尝试从实验分支安装一些软件包,并将源代码保存在源文件中。我一直在使用从 jessie-backports 获取的 nvidia-driver 版本。看起来/etc/apt/sources.list
像这样:
# deb cdrom:[Debian GNU/Linux stretch-DI-alpha7 _Stretch_ - Official Snapshot amd64 NETINST Binary-1 20160630-14:29]/ stretch main
#deb cdrom:[Debian GNU/Linux stretch-DI-alpha7 _Stretch_ - Official Snapshot amd64 NETINST Binary-1 20160630-14:29]/ stretch main
deb http://ftp.es.debian.org/debian/ stretch main
deb-src http://ftp.es.debian.org/debian/ stretch main
deb http://ftp.de.debian.org/debian experimental main
deb http://security.debian.org/debian-security stretch/updates main
deb-src http://security.debian.org/debian-security stretch/updates main
deb http://ftp.de.debian.org/debian stretch main non-free
deb http://httpredir.debian.org/debian/ stretch main contrib non-free
deb http://httpredir.debian.org/debian jessie-backports main contrib non-free
由于这些依赖项,我无法清除或重新安装安装。
我能做些什么?
编辑:
的输出apt-get purge libnvidia-eglcore libnvidia-glcore
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
libegl-nvidia0 : Depends: libnvidia-eglcore (= 367.44-2) but it is not going to be installed
libgl1-nvidia-glx : Depends: libnvidia-glcore (= 367.44-2) but it is not going to be installed
libgles-nvidia1 : Depends: libnvidia-eglcore (= 367.44-2) but it is not going to be installed
libgles-nvidia2 : Depends: libnvidia-eglcore (= 367.44-2) but it is not going to be installed
libglx-nvidia0 : Depends: libnvidia-glcore (= 367.44-2) but it is not going to be installed
nvidia-driver-libs : Depends: libnvidia-glcore (= 367.44-2) but it is not going to be installed
Recommends: nvidia-driver-libs-i386
xserver-xorg-video-nvidia : Depends: libnvidia-glcore (= 367.44-2) but it is not going to be installed
Recommends: nvidia-settings (>= 367) but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
答案1
所以我想我终于清除了整个 nvidia 的东西并设法安装了一组全新的软件包。
我必须手动清除给我带来错误依赖项的软件包,然后我遇到了一些残留库和配置的问题,这些库和配置在清除后仍然安装nvidia-*
,apt-get
所以我还确保删除了libnvidia-*
正则表达式下的所有内容,这并没有看起来在阅读完要卸载的内容后它会破坏任何东西。
之后,我重新启动并确保清除了所有临时或残留的软件包和文件,使用我拥有的 jessie-backports deb 安装了 nvidia 驱动程序/etc/apt/sourceslist
(自己手动修复依赖项并避免处理它们),现在一切都正常了。谢谢绿拇指博士,你就是个混蛋