package mysql-server-5.7 5.7.16-0ubuntu0.16.04.1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 1

Bug #1647028 reported by Pushp on 2016-12-03
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
mysql-5.7 (Ubuntu)
Undecided
Unassigned

Bug Description

I was trying to install LAMP with the following command.
sudo apt-get install lamp-server^
thats basically php, mysql, apache
And this ends up with the following message :
<code>
Creating config file /etc/php/7.0/cli/php.ini with new version
Setting up libapache2-mod-php7.0 (7.0.8-0ubuntu0.16.04.3) ...

Creating config file /etc/php/7.0/apache2/php.ini with new version
Module mpm_event disabled.
Enabling module mpm_prefork.
apache2_switch_mpm Switch to prefork
apache2_invoke: Enable module php7.0
Setting up libapache2-mod-php (1:7.0+35ubuntu6) ...
Setting up libhtml-template-perl (2.95-2) ...
dpkg: dependency problems prevent configuration of mysql-server:
 mysql-server depends on mysql-server-5.7; however:
  Package mysql-server-5.7 is not configured yet.

dpkg: error processing package mysql-server (--configure):
 dependency problems - leaving unconfigured
Setting up php7.0-mysql (7.0.8-0ubuntu0.16.04.3) ...
No apport report written because the error message indicates its a followup error from a previous failure.

Creating config file /etc/php/7.0/mods-available/mysqlnd.ini with new version

Creating config file /etc/php/7.0/mods-available/mysqli.ini with new version

Creating config file /etc/php/7.0/mods-available/pdo_mysql.ini with new version
Setting up php-mysql (1:7.0+35ubuntu6) ...
Processing triggers for libc-bin (2.23-0ubuntu3) ...
Processing triggers for systemd (229-4ubuntu7) ...
Processing triggers for ureadahead (0.100.0-19) ...
Processing triggers for ufw (0.35-0ubuntu2) ...
Processing triggers for libapache2-mod-php7.0 (7.0.8-0ubuntu0.16.04.3) ...
Errors were encountered while processing:
 mysql-server-5.7
 mysql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)

<code>

ProblemType: Package
DistroRelease: Ubuntu 16.04
Package: mysql-server-5.7 5.7.16-0ubuntu0.16.04.1
ProcVersionSignature: Ubuntu 4.4.0-31.50-generic 4.4.13
Uname: Linux 4.4.0-31-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.1
Architecture: amd64
Date: Sat Dec 3 14:49:49 2016
ErrorMessage: subprocess installed post-installation script returned error exit status 1
InstallationDate: Installed on 2016-12-03 (0 days ago)
InstallationMedia: Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64 (20160719)
Logs.var.log.daemon.log:

MySQLConf.etc.mysql.conf.d.mysql.cnf: [mysql]
MySQLConf.etc.mysql.conf.d.mysqldump.cnf:
 [mysqldump]
 quick
 quote-names
 max_allowed_packet = 16M
MySQLConf.etc.mysql.mysql.conf.d.mysqld_safe_syslog.cnf:
 [mysqld_safe]
 syslog
MySQLVarLibDirListing: ['healing_arts', 'canvas', 'ib_buffer_pool', 'airmail', 'moodle222', 'apsn', 'ib_logfile0', 'joomla', 'rudra', 'srm', 'manumaya_metafab', 'colormode', 'test', 'auto.cnf', 'coal', 'management_tool', 'magento', 'debian-5.1.flag', 'watchtower', 'moodle26', 'tags', 'metis', 'social', 'ibdata1', 'bank_sct', 'debian-5.7.flag', 'moodle202', 'mysql', 'magic', 'ib_logfile1', 'moodle', 'quantum', 'mysql_upgrade_info']
ProcCmdline: BOOT_IMAGE=/boot/vmlinuz-4.4.0-31-generic root=UUID=ddc87879-b200-4d7e-a1ca-a47c721bf78e ro quiet splash vt.handoff=7
RelatedPackageVersions:
 dpkg 1.18.4ubuntu1.1
 apt 1.2.12~ubuntu16.04.1
SourcePackage: mysql-5.7
Title: package mysql-server-5.7 5.7.16-0ubuntu0.16.04.1 failed to install/upgrade: subprocess installed post-installation script returned error exit status 1
UpgradeStatus: No upgrade log present (probably fresh install)

Pushp (pushp2) wrote :
tags: removed: need-duplicate-check

From the log:
2016-12-03T09:19:21.069388Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2016-12-03T09:19:21.069453Z 0 [ERROR] InnoDB: Cannot open '/var/lib/mysql/ib_buffer_pool' for reading: No such file or directory

From that and all around it it appers to me that on upgrade it has to upgrade the database to be compatible with the new version.
That seemed to have failed for your custom installation/configuration/database, but I failed to find a particular reason in the logs that were submitted.

I happened to find https://bugs.mysql.com/bug.php?id=73952 - a 5.6 to 5.7 change causing that depending on your ocnfig.
Which might hold a workaround to fix up your system to get into a working state again.
From there everything should be fine again.

Changed in mysql-5.7 (Ubuntu):
status: New → Incomplete
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.