我想使用 Alien 从 rpm 转换而来的 deb 文件来安装 Java Development Kit 8。
QApt 表示安装已完成,但软件包jdk1.8.0-111
只安装了一半。它阻止使用 apt 和 dpkg 进行的所有安装,甚至强制安装。
这是我使用 apt 执行命令安装某些东西后得到的结果:
matj1@matj1-Lenovo-G565:~$ sudo apt upgrade
Načítají se seznamy balíků… Hotovo
Vytváří se strom závislostí
Načítají se stavové informace… Hotovo
E: Balík jdk1.8.0-111 je potřeba přeinstalovat, ale nemohu pro něj nalézt archiv.
输出的最后一行意味着jdk1.8.0-111
需要重新安装包,但找不到它的存档。
执行后sudo dpkg --remove --force-remove-reinstreq --dry-run jdk1.8.0-111
,输出为,dpkg: warning: package is in a very bad inconsistent state; you should reinstall it before attempting a removal
从 deb 文件重新安装没有帮助。使用 apt 或 dpkg 重新安装不起作用,正如我上面所写。
这是来自 apt-cache 的软件包的信息:
matj1@matj1-Lenovo-G565:~$ apt-cache show jdk1.8.0-111
Package: jdk1.8.0-111
Status: install reinstreq half-installed
Priority: extra
Section: alien
Installed-Size: 265842
Maintainer: matj1 <matj1@matj1-Lenovo-G565>
Architecture: amd64
Version: 1.8.0111-1
Conffiles:
/usr/java/jdk1.8.0_111/.java/.systemPrefs/.system.lock d41d8cd98f00b204e9800998ecf8427e
/usr/java/jdk1.8.0_111/.java/.systemPrefs/.systemRootModFile d41d8cd98f00b204e9800998ecf8427e
/usr/java/jdk1.8.0_111/.java/init.d/jexec 3a4104cd0a34b5e7e55433a78d9f7721
/usr/java/jdk1.8.0_111/jre/lib/charsets.pack 43fd4018caf9d70b0156ba71a2deddc1
/usr/java/jdk1.8.0_111/jre/lib/deploy.pack 2c41ec5bcbb2ca944b748903b39a45cc
/usr/java/jdk1.8.0_111/jre/lib/ext/localedata.pack 035979fc8d9e3ab801fe4cc13ee564d9
/usr/java/jdk1.8.0_111/jre/lib/javaws.pack fca11febf27a7452e4d22cd554a7a4a9
/usr/java/jdk1.8.0_111/jre/lib/jsse.pack dde297bd14714a7f82f6cdd5edea5707
/usr/java/jdk1.8.0_111/jre/lib/plugin.pack c209a7a71c58567555d10fb0bd6c47b6
/usr/java/jdk1.8.0_111/jre/lib/rt.pack 54d085990029980b87e18198690e6fe0
/usr/java/jdk1.8.0_111/lib/tools.pack 52266ea5d70810bcbdeaeb41f7e526e2
Description: Java Platform Standard Edition Development Kit
The Java Platform Standard Edition Development Kit (JDK) includes both
the runtime environment (Java virtual machine, the Java platform classes
and supporting files) and development tools (compilers, debuggers,
tool libraries and other tools).
.
The JDK is a development environment for building applications, applets
and components that can be deployed with the Java Platform Standard
Edition Runtime Environment.
.
(Converted from a rpm package by alien version 8.95.)
Description-md5: ae0ab6b38ab278a40ff85d4bdaf97ceb
答案1
解决:我重装了系统。
还有其他问题需要修复,而且它不在我的主 PC 上。所以我不介意。