安装 libapache2-mod-fcgid,但无法通过配置

安装 libapache2-mod-fcgid,但无法通过配置

我今天用 vmware 模板设置了两台服务器。一台成功了,另一台失败了。唯一的区别是,在失败的那台上,我apt-get distupgrades在命令执行前几天运行了它,而另一台上没有运行。除此之外,它们功能相同。只是在不同的子网上,名称不同。

当我运行时,sudo apt-get install libapache2-mod-fcgid我收到以下错误。我尝试运行 apt-get clean、purge 和 autoremove。我仍然收到此错误。

Selecting previously unselected package libapache2-mod-fcgid.
(Reading database ... 155482 files and directories currently installed.)
Preparing to unpack .../libapache2-mod-fcgid_1%3a2.3.9-1_amd64.deb ...
Unpacking libapache2-mod-fcgid (1:2.3.9-1) ...
Setting up libapache2-mod-fcgid (1:2.3.9-1) ...
dpkg: error processing package libapache2-mod-fcgid (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 libapache2-mod-fcgid
E: Sub-process /usr/bin/dpkg returned an error code (1)

我试过了apt-get install -f

$ sudo apt-get install -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up libapache2-mod-fcgid (1:2.3.9-1) ...
dpkg: error processing package libapache2-mod-fcgid (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 libapache2-mod-fcgid
E: Sub-process /usr/bin/dpkg returned an error code (1)

我试过了dpkg-reconfigure libapache2-mod-fcgid

$ sudo dpkg-reconfigure libapache2-mod-fcgid
/usr/sbin/dpkg-reconfigure: libapache2-mod-fcgid is broken or not fully installed

您知道如何找出导致错误的原因或解决这个问题吗?

答案1

我今天也遇到了同样的软件包错误libapache2-mod-dnssd。我打开这个帖子寻求解决方案。找不到解决办法,我尝试按照错误消息重新安装。

sudo apt reinstall libapache2-mod-dnssd

它在我的场景中有效。希望它对你也有效 ;)

答案2

我通过禁用 webmin (virtualmin) 和 apache 服务并尝试重新安装解决了我的问题。停止这两个服务后,它运行良好。安装后我能够重新启动它们。

如果有人能解释为什么会这样,我很乐意给你功劳。我猜是内存使用问题,但两台机器的内存是一样的。也许与配置顺序或其他原因有关。

相关内容