package libapache2-mod-php7.4 7.4.3-4ubuntu2.2 failed to install/upgrade: »installiertes libapache2-mod-php7.4-Skript des Paketes post-installation«-Unterprozess gab den Fehlerwert 1 zurück
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
php7.4 (Ubuntu) |
Expired
|
Undecided
|
Unassigned |
Bug Description
after
apache2 + php7.4 are installed
i did someting wrong with the apache2 config files and want get back the default config.
sudo apt purge apache2
sudo apt install apache2
was the php extension nomore available.
so i tryed:
sudo apt install libapache2-
-> error occours
after that i
sudo apt purge libapache2-
sudo apt install libapache2-
look good now :-)
ProblemType: Package
DistroRelease: Ubuntu 20.04
Package: libapache2-
ProcVersionSign
Uname: Linux 5.4.0-42-generic x86_64
ApportVersion: 2.20.11-0ubuntu27.8
AptOrdering:
libapache2-
NULL: ConfigurePending
Architecture: amd64
CasperMD5CheckR
Date: Sun Aug 30 15:16:38 2020
ErrorMessage: »installiertes libapache2-
Python3Details: /usr/bin/python3.8, Python 3.8.2, python3-minimal, 3.8.2-0ubuntu2
PythonDetails: /usr/bin/python2.7, Python 2.7.18rc1, python-is-python2, 2.7.17-4
RelatedPackageV
dpkg 1.19.7ubuntu3
apt 2.0.2ubuntu0.1
SourcePackage: php7.4
Title: package libapache2-
UpgradeStatus: No upgrade log present (probably fresh install)
modified.
modified.
## DpkgTerminalLog ##
Preparing to unzip .../libapache2-
Extract from libapache2-
libapache2-
Module mpm_event disabled.
Enabling module mpm_prefork.
apache2_switch_mpm Switch to prefork
[1mdpkg:[0m Error while configuring the package libapache2-
»installed libapache2-
description: | updated |
Changed in php7.4 (Ubuntu): | |
status: | Incomplete → New |
status: | New → Incomplete |
Hi Michael,
We've seen some idiosyncratic corner cases like this with mod_php, however I'm not able to replicate this particular one you've seen, so need some additional information on how to trigger it.
In a 20.04 LXD container, I tested:
$ sudo apt-get install apache2 dbd-sqlite3 libaprutil1-ldap libjansson4 liblua5.2-0
The following NEW packages will be installed:
apache2 apache2-bin apache2-data apache2-utils libaprutil1-
0 upgraded, 8 newly installed, 0 to remove and 58 not upgraded.
...
$ sudo apt-get install libapache2- mod-php7. 4 mod-php7. 4 php-common php7.4-cli php7.4-common php7.4-json php7.4-opcache php7.4-readline
The following NEW packages will be installed:
libapache2-
0 upgraded, 7 newly installed, 0 to remove and 58 not upgraded.
...
# Verify php module is enabled: mods-enabled/ php* mods-enabled/ php7.4. conf -> ../mods- available/ php7.4. conf mods-enabled/ php7.4. load -> ../mods- available/ php7.4. load
$ ls -l /etc/apache2/
lrwxrwxrwx 1 root root 29 Aug 31 17:52 /etc/apache2/
lrwxrwxrwx 1 root root 29 Aug 31 17:52 /etc/apache2/
# Purge apache2:
$ sudo apt purge apache2
The following packages will be REMOVED:
apache2*
# No modules enabled at this point: mods-enabled mods-enabled' : No such file or directory
$ ls -ld /etc/apache2/
ls: cannot access '/etc/apache2/
# Install apache2 again:
$ sudo apt install apache2
# Some modules are enabled, but not php*: mods-enabled | wc -l mods-enabled/ php* mods-enabled/ php*': No such file or directory
$ ls -l /etc/apache2/
30
$ ls -l /etc/apache2/
ls: cannot access '/etc/apache2/
# Now try to reinstall the php mod: mod-php7. 4 --reinstall
$ sudo apt install libapache2-
Reading state information... Done
0 upgraded, 0 newly installed, 1 reinstalled, 0 to remove and 58 not upgraded.
...
apache2_switch_mpm Switch to prefork
apache2_invoke: Enable module php7.4
This is with: mod-php7. 4 7.4.3-4ubuntu2.2
apache2 2.4.41-4ubuntu3.1
libapache2-
Can you see if you can reproduce the failure in a clean LXD container? I'm guessing there are some additional missing steps like adjustments to the apache or mod_php config files, or perhaps something else needing installed in addition to those two?
The error message refers to a "packaging script" returning an error code 1. A question to figure out is which script that is, and what is causing it to emit that particular error code. For LP: #1865218 (similar but not same as this), the script in question was libapache2- mod-php. postinst. extra, so that script would probably be the first thing I'd look at, but at this point I don't think we know what to look for. However, if you can help us in reproducing the issue synthetically then we can narrow down and isolate it.