问题就在这里。我尝试为 epson 扫描仪安装 .deb (http://download.ebz.epson.net/dsc/search/01/search/searchModule) 并且确实意外安装了 i386 而不是 amd64 版本。
现在我遇到了以下问题。如果我尝试使用 dpkg 卸载或清除,也会出现同样的问题!
sudo apt-get autoremove
[sudo] password for ***:
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:
iscan-plugin-gt-x770 : Depends: iscan (>= 2.16.1) but it is not installable
iscan-plugin-gt-x820 : Depends: iscan (>= 2.22.0) but it is not installable
E: Unmet dependencies. Try using -f.
➜ ~ sudo apt-get install -f
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:
... libreoffice-java-common...linux-image-extra-3.11.0-13-generic linux-image-extra-3.11.0-14-generic
linux-image-extra-3.11.0-15-generic lp-solve openjdk-7-jre-lib swig swig2.0
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
iscan-plugin-gt-x770 iscan-plugin-gt-x820
0 upgraded, 0 newly installed, 2 to remove and 3 not upgraded.
After this operation, 926 kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 693386 files and directories currently installed.)
Removing iscan-plugin-gt-x770 ...
/var/lib/dpkg/info/iscan-plugin-gt-x770.prerm: 4: /var/lib/dpkg/info/iscan-plugin-gt-x770.prerm: iscan-registry: not found
dpkg: error processing iscan-plugin-gt-x770 (--remove):
subprocess installed pre-removal script returned error exit status 127
No apport report written because MaxReports is reached already
/var/lib/dpkg/info/iscan-plugin-gt-x770.postinst: 4: /var/lib/dpkg/info/iscan-plugin-gt-x770.postinst: iscan- registry: not found
Removing iscan-plugin-gt-x820 ...
/var/lib/dpkg/info/iscan-plugin-gt-x820.prerm: 4: /var/lib/dpkg/info/iscan-plugin- gt-x820.prerm: iscan-registry: not found
dpkg: error processing iscan-plugin-gt-x820 (--remove):
subprocess installed pre-removal script returned error exit status 127
No apport report written because MaxReports is reached already
/var/lib/dpkg/info/iscan-plugin-gt-x820.postinst: 4: /var/lib/dpkg/info/iscan-plugin-gt-x820.postinst: iscan- registry: not found
Errors were encountered while processing:
iscan-plugin-gt-x770
iscan-plugin-gt-x820
E: Sub-process /usr/bin/dpkg returned an error code (1)
答案1
尝试:
echo | sudo tee /var/lib/dpkg/info/iscan-plugin-gt-x770.prerm
echo | sudo tee /var/lib/dpkg/info/iscan-plugin-gt-x820.prerm
进而:
sudo apt-get install -f
上述命令将清空软件包上的预删除脚本,从而使卸载程序正确完成。