Yesterday, when upgrading a client VMs running Xenial and moving to Bionic, I noticed Apache's mod_php was disabled. I later reproduced this in a container:
# create a Xenial container
$ lxc launch images:ubuntu/xenial xa
Creating xa
Starting xa
root@xa:~# apt-get install libapache2-mod-php
Reading package lists... Done
Building dependency tree
Reading state information... Done
...
Unpacking libapache2-mod-php7.0 (7.0.33-0ubuntu0.16.04.12) ...
...
apache2_switch_mpm Switch to prefork
apache2_invoke: Enable module php7.0
# Upgrade to Bionic
root@xa:~# apt-get install ubuntu-release-upgrader-core
...
root@xa:~# do-release-upgrade
...
Creating config file /etc/php/7.2/cli/php.ini with new version
Setting up libapache2-mod-php7.2 (7.2.24-0ubuntu0.18.04.3) ...
Creating config file /etc/php/7.2/apache2/php.ini with new version
libapache2-mod-php7.2: php7.0 module already enabled, not enabling PHP 7.2
Setting up libapache2-mod-php (1:7.2+60ubuntu1) ...
...
Removing libapache2-mod-php7.0 (7.0.33-0ubuntu0.16.04.12) ...
Module php7.0 disabled.
apache2_invoke prerm: Disable module php7.0
Purging configuration files for libapache2-mod-php7.0 (7.0.33-0ubuntu0.16.04.12) ...
apache2_invoke postrm: Purging state for php7.0
dpkg: warning: while removing libapache2-mod-php7.0, directory '/etc/php/7.0/apache2/conf.d' not empty so not removed
...
System upgrade is complete.
Restart required
To finish the upgrade, a restart is required.
If you select 'y' the system will be restarted.
Yesterday, when upgrading a client VMs running Xenial and moving to Bionic, I noticed Apache's mod_php was disabled. I later reproduced this in a container:
# create a Xenial container ubuntu/ xenial xa
$ lxc launch images:
Creating xa
Starting xa
# Install Apache mod_php
$ lxc shell xa
mesg: ttyname failed: Success
root@xa:~# apt-get install libapache2-mod-php mod-php7. 0 (7.0.33- 0ubuntu0. 16.04.12) ...
Reading package lists... Done
Building dependency tree
Reading state information... Done
...
Unpacking libapache2-
...
apache2_switch_mpm Switch to prefork
apache2_invoke: Enable module php7.0
# Upgrade to Bionic release- upgrader- core
root@xa:~# apt-get install ubuntu-
...
root@xa:~# do-release-upgrade 7.2/cli/ php.ini with new version mod-php7. 2 (7.2.24- 0ubuntu0. 18.04.3) ...
...
Creating config file /etc/php/
Setting up libapache2-
Creating config file /etc/php/ 7.2/apache2/ php.ini with new version mod-php7. 2: php7.0 module already enabled, not enabling PHP 7.2 mod-php7. 0 (7.0.33- 0ubuntu0. 16.04.12) ... mod-php7. 0 (7.0.33- 0ubuntu0. 16.04.12) ... mod-php7. 0, directory '/etc/php/ 7.0/apache2/ conf.d' not empty so not removed
libapache2-
Setting up libapache2-mod-php (1:7.2+60ubuntu1) ...
...
Removing libapache2-
Module php7.0 disabled.
apache2_invoke prerm: Disable module php7.0
Purging configuration files for libapache2-
apache2_invoke postrm: Purging state for php7.0
dpkg: warning: while removing libapache2-
...
System upgrade is complete.
Restart required
To finish the upgrade, a restart is required.
If you select 'y' the system will be restarted.
Continue [yN] y
Additional information on the upgraded container:
root@xa:~# lsb_release -rd mod-php7. 2 mod-php7. 2: 0ubuntu0. 18.04.3 0ubuntu0. 18.04.3 0ubuntu0. 18.04.3 500 archive. ubuntu. com/ubuntu bionic-updates/main amd64 Packages security. ubuntu. com/ubuntu bionic- security/ main amd64 Packages dpkg/status archive. ubuntu. com/ubuntu bionic/main amd64 Packages
Description: Ubuntu 18.04.4 LTS
Release: 18.04
root@xa:~# apt-cache policy libapache2-
libapache2-
Installed: 7.2.24-
Candidate: 7.2.24-
Version table:
*** 7.2.24-
500 http://
500 http://
100 /var/lib/
7.2.3-1ubuntu1 500
500 http://