我无法从我的Ubuntu15.04中完全删除tomcat7。我错误地从文件管理器中删除了它的var/lib/dpkg/info/tomcat7配置文件。但是现在,当我试图使用apt-get remove删除这个包时,甚至通过synaptic管理器,我得到了这个错误:
(synaptic:9062): GLib-CRITICAL **: g_child_watch_add_full: assertion 'pid > 0' failed
(Reading database ... 399913 files and directories currently installed.)
Removing tomcat7 (7.0.56-2ubuntu0.1) ...
/var/lib/dpkg/info/tomcat7.prerm: 1: /etc/default/tomcat7: Run: not found
dpkg: error processing package tomcat7 (--purge):
subprocess installed pre-removal script returned error exit status 127
dpkg: tomcat7-common: dependency problems, but removing anyway as you requested:
tomcat7 depends on tomcat7-common (>= 7.0.56-2ubuntu0.1).
Removing tomcat7-common (7.0.56-2ubuntu0.1) ...
Errors were encountered while processing:
tomcat7
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install. Trying to recover:发布于 2016-12-08 19:35:35
您混淆了包管理系统。您应该重新安装tomcat7,使用:
sudo apt-get install --reinstall tomcat7然后,当文件系统内容和包管理系统达成一致时,
sudo apt-get remove tomcat7https://askubuntu.com/questions/858471
复制相似问题