我有libapache2-mod-php7.0的未满足的依赖项。在我试图解决这个问题时,我一直在玩我的资源并进行了各种升级。我开始时就在Stretch上,我知道我可能走错路了,但我想先问一下。
lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux stable-updates (sid)
Release: stable-updates
Codename: sid
cat /etc/issue.net
Debian GNU/Linux buster/sid
cat / proc / version
Linux version 3.2.0-4-amd64 (debian-kernel@lists.debian.org) (gcc version 4.6.3 (Debian 4.6.3-14) ) #1 SMP Debian 3.2.93-1
apt-get update apt-get updgrade
...
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
libapache2-mod-php7.0 : Depends: apache2-api-20120211
Depends: apache2-bin (>= 2.4.16) but it is not installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
apt --fix-broken install
...
dpkg: error processing archive /var/cache/apt/archives/apache2-bin_2.4.29-1_amd64.deb (--unpack):
trying to overwrite '/usr/lib/apache2/modules/httpd.exp', which is also in package apache2.2-bin 2.2.22-13+deb7u12
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/apache2-bin_2.4.29-1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
apt-get clean apt-get autoclean apt-get -f install
...
Unpacking apache2-bin (2.4.25-3+deb9u3) ...
dpkg: error processing archive /var/cache/apt/archives/apache2-bin_2.4.25-3+deb9u3_amd64.deb (--unpack):
trying to overwrite '/usr/lib/apache2/modules/httpd.exp', which is also in package apache2.2-bin 2.2.22-13+deb7u12
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/apache2-bin_2.4.25-3+deb9u3_amd64.deb
W: http: aptMethod::Configuration: could not load seccomp policy: Invalid argument
E: Sub-process /usr/bin/dpkg returned an error code (1)
dpkg --configure -a
dpkg: dependency problems prevent configuration of libapache2-mod-php7.0:
libapache2-mod-php7.0 depends on apache2-api-20120211; however:
Package apache2-api-20120211 is not installed.
libapache2-mod-php7.0 depends on apache2-bin (>= 2.4.16); however:
Package apache2-bin is not installed.
dpkg: error processing package libapache2-mod-php7.0 (--configure):
dependency problems - leaving unconfigured
Setting up linux-image-4.14.0-1-amd64 (4.14.2-1) ...
/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-4.14.0-1-amd64
/etc/kernel/postinst.d/zz-update-grub:
/usr/sbin/grub-probe: error: failed to get canonical path of `/dev/disk/by-uuid/1cd988f1-4ed7-4bb1-81a5-15f7dc900a47'.
run-parts: /etc/kernel/postinst.d/zz-update-grub exited with return code 1
dpkg: error processing package linux-image-4.14.0-1-amd64 (--configure):
installed linux-image-4.14.0-1-amd64 package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of linux-image-amd64:
linux-image-amd64 depends on linux-image-4.14.0-1-amd64; however:
Package linux-image-4.14.0-1-amd64 is not configured yet.
dpkg: error processing package linux-image-amd64 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of php7.0:
php7.0 depends on libapache2-mod-php7.0 | php7.0-fpm | php7.0-cgi; however:
Package libapache2-mod-php7.0 is not configured yet.
Package php7.0-fpm is not installed.
Package php7.0-cgi is not installed.
dpkg: error processing package php7.0 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of php:
php depends on php7.0; however:
Package php7.0 is not configured yet.
dpkg: error processing package php (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of phpmyadmin:
phpmyadmin depends on php; however:
Package php is not configured yet.
Package php7.0 which provides php is not configured yet.
dpkg: error processing package phpmyadmin (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
libapache2-mod-php7.0
linux-image-4.14.0-1-amd64
linux-image-amd64
php7.0
php
phpmyadmin
apt-get -u dist-upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
libapache2-mod-php7.0 : Depends: apache2-api-20120211
Depends: apache2-bin (>= 2.4.16) but it is not installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
我还可以尝试解决此问题吗?
答案 0 :(得分:1)
你需要删除apache
datalab create --disk-size-gb 10 --idle-timeout "30m" --machine-type f1-micro practice
你可以强制安装apache2-bin:
apt-get remove apache2.2-bin
然后尝试
dpkg -i --force-overwrite /var/cache/apt/archives/apache2-bin_2.4.20-2_amd64.deb
对我来说它有效;)
答案 1 :(得分:1)
尝试这些步骤
1. sudo apt-get update
2. sudo apt-get dist-upgrade
3. apt-get install -f --reinstall apache2
-f修复未满足的依赖性。