Debianにnvidiaドライバをインストールした後、dpkg、Xが破損する

Debianにnvidiaドライバをインストールした後、dpkg、Xが破損する

Debianに続きDebian 8 "Jessie" 用 NVidia ドライバのインストール手順、未知の障害物にぶつかりました...

# apt-get install linux-headers-$(uname -r|sed 's,[^-]*-[^-]*-,,')
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:
 glx-alternative-mesa : Depends: glx-diversions (= 0.7.2) but 0.5.1 is to be installed
 linux-headers-amd64 : Depends: linux-headers-4.5.0-1-amd64 but it is not going to be installed
 update-glx : Depends: glx-diversions (= 0.7.2) but 0.5.1 is to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
# apt-get -f install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  libjansson4 libxnvctrl0 nvidia-settings
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  glx-alternative-nvidia glx-diversions libegl1-nvidia libgl1-nvidia-glx libnvidia-eglcore
  nvidia-alternative nvidia-driver nvidia-driver-bin nvidia-kernel-common nvidia-kernel-dkms
  nvidia-kernel-support nvidia-legacy-check nvidia-vdpau-driver xserver-xorg-video-nvidia
Recommended packages:
  libgl1-nvidia-glx-i386 libgles1-nvidia libgles2-nvidia nvidia-persistenced
The following NEW packages will be installed:
  nvidia-kernel-support nvidia-legacy-check
The following packages will be upgraded:
  glx-alternative-nvidia glx-diversions libegl1-nvidia libgl1-nvidia-glx libnvidia-eglcore
  nvidia-alternative nvidia-driver nvidia-driver-bin nvidia-kernel-common nvidia-kernel-dkms
  nvidia-vdpau-driver xserver-xorg-video-nvidia
12 upgraded, 2 newly installed, 0 to remove and 1090 not upgraded.
2 not fully installed or removed.
Need to get 0 B/23.3 MB of archives.
After this operation, 4,727 kB disk space will be freed.
Do you want to continue? [Y/n] 
Reading changelogs... Done
Preconfiguring packages ...
(Reading database ... 249357 files and directories currently installed.)
Preparing to unpack .../nvidia-legacy-check_352.79-6_amd64.deb ...
dpkg: error processing archive /var/cache/apt/archives/nvidia-legacy-check_352.79-6_amd64.deb (--unpack):
 subprocess new pre-installation script returned error exit status 128
Errors were encountered while processing:
 /var/cache/apt/archives/nvidia-legacy-check_352.79-6_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

[OK]...では、「エラー終了状態128」とはどういう意味ですか?

# dpkg -Dh
dpkg debugging option, --debug=<octal> or -D<octal>:

 Number  Ref. in source   Description
      1  general          Generally helpful progress information
      2  scripts          Invocation and status of maintainer scripts
     10  eachfile         Output for each file processed
    100  eachfiledetail   Lots of output for each file processed
     20  conff            Output for each configuration file
    200  conffdetail      Lots of output for each configuration file
     40  depcon           Dependencies and conflicts
    400  depcondetail     Lots of dependencies/conflicts output
  10000  triggers         Trigger activation and processing
  20000  triggersdetail   Lots of output regarding triggers
  40000  triggersstupid   Silly amounts of output regarding triggers
   1000  veryverbose      Lots of drivel about eg the dpkg/info directory
   2000  stupidlyverbose  Insane amounts of drivel

Debugging options can be mixed using bitwise-or.
Note that the meanings and values are subject to change.
# dpkg -D2000 --install /var/cache/apt/archives/nvidia-legacy-check_352.79-6_amd64.deb
(Reading database ... 249357 files and directories currently installed.)
Preparing to unpack .../nvidia-legacy-check_352.79-6_amd64.deb ...
dpkg: error processing archive /var/cache/apt/archives/nvidia-legacy-check_352.79-6_amd64.deb (--install):
 subprocess new pre-installation script returned error exit status 128
Errors were encountered while processing:
 /var/cache/apt/archives/nvidia-legacy-check_352.79-6_amd64.deb
#

うーん…だから情報がないですね。

誰でもアドバイスできますか?問題が解決するまで何もインストールできず、常に「-f install」を実行するように求められますので、apt-get は使用できません。

私ができることを「消して」再開したいのですが、そこまで行く方法がわかりません。 glx-diversionsとの依存関係の衝突は克服できないようです...

# apt-get -f install glx-diversions=0.5.1
Reading package lists... Done
Building dependency tree       
Reading state information... Done
glx-diversions is already the newest version.
glx-diversions set to manually installed.
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 glx-alternative-mesa : Depends: glx-diversions (= 0.7.2) but 0.5.1 is to be installed
 update-glx : Depends: glx-diversions (= 0.7.2) but 0.5.1 is to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

# apt-get remove glx-alternative-mesa update-glx
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:
 glx-alternative-nvidia : Depends: glx-alternative-mesa but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

助ける?

修正する: データソースは次のとおりです。

# cat sources.list
deb http://ftp.us.debian.org/debian testing main contrib non-free

deb http://ftp.debian.org/debian/ jessie-updates main contrib non-free

deb http://security.debian.org/ jessie/updates main contrib non-free

# jessie-backports
deb http://httpredir.debian.org/debian jessie-backports main contrib non-free

……ああそうですね。 「試験」! = "提示"。 「testing」を「jessie」に変更しました。これでapt-get -f installを実行すると、多くの新しくて良いことが起こり、エラーなしで完了します。ありがとうございます。

ベストアンサー1

同じパッケージの2つの異なるアーキテクチャまたはバージョンをインストールすると、このエラーが発生します。apt-get -f installアプリを使用しようとしてもエラーsynaptic(壊れたパッケージの左側の列)が発生する場合は、問題を解決できます。

おすすめ記事