我在安装时遇到问题网页管理为了Debian Wheezy。
事实证明,在安装这些说明中提到的依赖项时Webmin 网站,安装时出现以下错误apt-show-versions:
$ apt-get install apt-show-versions
Reading package lists... Done
Building dependency tree
Reading state information... Done
apt-show-versions is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 15 not upgraded.
2 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 apt-show-versions (0.20) ...
** initializing cache. This may take a while **
Error: No information about packages! (Maybe no deb entries?)
dpkg: error processing apt-show-versions (--configure):
subprocess installed post-installation script returned error exit status 255
dpkg: dependency problems prevent configuration of webmin:
webmin depends on apt-show-versions; however:
Package apt-show-versions is not configured yet.
dpkg: error processing webmin (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
apt-show-versions
webmin
E: Sub-process /usr/bin/dpkg returned an error code (1)
看起来 APT 在处理该包的配置时遇到了问题。
根据“男人适合”:
--配置包...|-a|--待定
配置已解压但尚未配置的软件包。如果给出 -a 或 --pending 而不是 package,则将配置所有已解压但尚未配置的软件包。
要重新配置已配置的包,请尝试 dpkg-reconfigure(8) 命令。
配置包括以下步骤:
解压conffile,同时备份旧的conffile,以便在出现问题时可以恢复。
如果包提供了,则运行 postinst 脚本。
我尝试过了...
- 卸载 webmin 然后安装 apt-show-versions
- 清理 APT 缓存
...但这些选项都不能解决我的问题。
我可以采用什么样的解决方案/解决方法来解决这个问题?
答案1
rm /etc/apt/apt.conf.d/docker-gzip-indexes
apt-get purge apt-show-versions
rm /var/lib/apt/lists/*lz4
apt-get -o Acquire::GzipIndexes=false update
apt-get install apt-show-versions
答案2
我发现此解决方案来自这个家伙比格犬板论坛页面Google 群组。
这是我选择遵循此程序的方式(这里是Webmin 软件包):
清除 apt-show-versions
apt-get purge apt-show-versions
设置 apt 的动态选项
apt-get -o Acquire::GzipIndexes=false update
apt-show-versions
$ apt-get install apt-show-versions
Reading package lists... Done
Building dependency tree
Reading state information... Done
apt-show-versions is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 15 not upgraded.
1 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 apt-show-versions (0.20) ...
** initializing cache. This may take a while **
网页管理工具
$ dpkg -i webmin_1.831_all.deb
Selecting previously unselected package webmin.
(Reading database ... 13818 files and directories currently installed.)
Unpacking webmin (from webmin_1.831_all.deb) ...
Setting up webmin (1.831) ...
Webmin install complete.
You can now login to https://e93cd8ed670b:10000/ as root with your root password,
or as any user who can use sudo to run commands as root.
$ /etc/init.d/webmin start
$ /etc/init.d/webmin status
Webmin (pid 4713) is running
[解释]
符合apt.conf 手册页:
...
收购集团
Acquire 选项组控制包的下载以及负责下载本身的各种“获取方法”(另请参阅 sources.list(5))。......
Gzip索引
下载 gzip 压缩索引(软件包、源代码或翻译)时,请将其保留在本地进行 gzip 压缩,而不是解压。这可以节省大量磁盘空间,但会在构建本地软件包缓存时增加 CPU 需求。
默认为 False(对于这种情况似乎并非如此)。
可能是这个版本apt-show-versions (0.20),在处理 GZIP 压缩索引时有不同的行为,因此需要配置“获取::GzipIndexes=false”即时更新(apt-get update),或者通过/etc/apt/apt.conf,以便跟进安装apt-show-versions..
答案3
以下对我有用:
dpkg --configure -D 777 apt-show-versions
结果:
root@odroidserver:~# dpkg --configure -D 777 apt-show-versions
D000001: ensure_diversions: new, (re)loading
D000001: process queue pkg apt-show-versions:all queue.len 0 progress 1, try 1
D000040: checking dependencies of apt-show-versions:all (- <none>)
D000400: checking group ...
D000400: checking possibility -> perl
D000400: checking non-provided pkg perl:armhf
D000400: is installed, ok and found
D000400: found 3
D000400: found 3 matched 0 possfixbytrig -
D000400: checking group ...
D000400: checking possibility -> apt
D000400: checking non-provided pkg apt:armhf
D000400: is installed, ok and found
D000400: found 3
D000400: found 3 matched 0 possfixbytrig -
D000400: checking group ...
D000400: checking possibility -> libapt-pkg-perl
D000400: checking non-provided pkg libapt-pkg-perl:armhf
D000400: is installed, ok and found
D000400: found 3
D000400: found 3 matched 0 possfixbytrig -
D000400: checking group ...
D000400: checking possibility -> libstorable-perl
D000400: not installed
D000400: returning 0
D000400: checking provider libperl5.26:armhf
D000400: checking package libstorable-perl provided by pkg libperl5.26:armhf
D000400: is installed, ok and found
D000400: found 3
D000400: found 3 matched 0 possfixbytrig -
D000040: ok 2 msgs >><<
D000040: checking Breaks
Setting up apt-show-versions (0.22.7ubuntu1) ...
D000002: fork/exec /var/lib/dpkg/info/apt-show-versions.postinst ( configure )
** initializing cache. This may take a while **
Error: No information about packages! (Maybe no deb entries?)
dpkg: error processing package apt-show-versions (--configure):
installed apt-show-versions package post-installation script subprocess returned error exit status 255
D000001: ensure_diversions: same, skipping
Errors were encountered while processing:
apt-show-versions
就我的情况来说,它指出了 libstorable-perl 软件包存在问题。因此我执行了以下操作:
apt-get purge apt-show-versions
apt-get update
apt-get install libstorable-perl
apt-get install apt-show-versions
瞧