Bug #84368 | Failed to install MySQL 5.7.17 on Ubuntu 16.04 using APT repo | ||
---|---|---|---|
Submitted: | 29 Dec 2016 11:06 | Modified: | 2 Jan 2017 8:32 |
Reporter: | Shahriyar Rzayev | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | MySQL Server: Packaging | Severity: | S1 (Critical) |
Version: | 5.7.17 | OS: | Ubuntu (16.04) |
Assigned to: | CPU Architecture: | Any |
[29 Dec 2016 11:06]
Shahriyar Rzayev
[29 Dec 2016 11:07]
Shahriyar Rzayev
root@sh-ubuntu:~# 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. 5 not fully installed or removed. After this operation, 0 B of additional disk space will be used. Setting up mysql-common (5.7.17-1ubuntu16.04) ... update-alternatives: error: alternative path /etc/mysql/my.cnf.fallback doesn't exist dpkg: error processing package mysql-common (--configure): subprocess installed post-installation script returned error exit status 2 dpkg: dependency problems prevent configuration of mysql-community-client: mysql-community-client depends on mysql-common (>= 5.7.17-1ubuntu16.04); however: Package mysql-common is not configured yet. Version of mysql-common on system, provided by mysql-common:amd64, is <none>. dpkg: error processing package mysql-community-client (--configure): dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of mysql-client: mysql-client depends on mysql-community-client (= 5.7.17-1ubuntu16.04); however: Package mysql-community-client is not configured yet. dpkg: error processing package mysql-client (--configure): dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of mysql-community-server: mysql-community-server depends on mysql-common (>= 5.7.17-1ubuntu16.04); however: Package mysql-common is not configured yet. Version of mysql-common on system, provided by mysql-common:amd64, is <none>. mysql-community-sNo apport report written because the error message indicates its a followup error from a previous failure. No apport report written because the error message indicates its a followup error from a previous failure. No apport report written because MaxReports is reached already No apport report written because MaxReports is reached already erver depends on mysql-client (= 5.7.17-1ubuntu16.04); however: Package mysql-client is not configured yet. dpkg: error processing package mysql-community-server (--configure): dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of mysql-server: mysql-server depends on mysql-community-server (= 5.7.17-1ubuntu16.04); however: Package mysql-community-server is not configured yet. dpkg: error processing package mysql-server (--configure): dependency problems - leaving unconfigured Errors were encountered while processing: mysql-common mysql-community-client mysql-client mysql-community-server mysql-server E: Sub-process /usr/bin/dpkg returned an error code (1)
[29 Dec 2016 14:19]
MySQL Verification Team
Thank you for the bug report. miguel@miguel:~/Downlolsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 16.04.1 LTS Release: 16.04 Codename: xenial miguel@miguel:~/Downloads$ mysql -uroot -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 3 Server version: 5.7.17 MySQL Community Server (GPL) Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> miguel@miguel:~/Downloads$ sudo dpkg -i mysql-apt-config_0.8.1-1_all.deb Selecting previously unselected package mysql-apt-config. (Reading database ... 241807 files and directories currently installed.) Preparing to unpack mysql-apt-config_0.8.1-1_all.deb ... Unpacking mysql-apt-config (0.8.1-1) ... Setting up mysql-apt-config (0.8.1-1) ... OK miguel@miguel:~/Downloads$ sudo apt-get update Hit:1 http://br.archive.ubuntu.com/ubuntu xenial InRelease Hit:2 http://br.archive.ubuntu.com/ubuntu xenial-updates InRelease Hit:3 http://br.archive.ubuntu.com/ubuntu xenial-backports InRelease Get:4 http://security.ubuntu.com/ubuntu xenial-security InRelease [102 kB] Hit:5 http://repo.mysql.com/apt/ubuntu xenial InRelease Get:6 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 Sources [886 B] Get:7 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 amd64 Packages [2.709 B] Get:8 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 i386 Packages [2.712 B] Fetched 108 kB in 2s (46,2 kB/s) Reading package lists... Done miguel@miguel:~/Downloads$ sudo apt-get install mysql-server Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: libaec0 libarmadillo6 libarpack2 libblas-common libblas3 libctemplate2v5 libdap17v5 libdapclient6v5 libepsilon1 libevent-core-2.0-5 libfreexl1 libgeos-3.5.0 libgeos-c1v5 libgfortran3 libgif7 libgtkmm-2.4-1v5 libhdf4-0-alt libhdf5-10 libkmlbase1 libkmldom1 libkmlengine1 liblapack3 libminizip1 libnetcdf11 libodbc1 libogdi3.2 libopenjp2-7 libpcrecpp0v5 libpq5 libproj9 libspatialite7 libsuperlu4 libsz2 libtinyxml2.6.2v5 liburiparser1 libvsqlitepp3v5 libxerces-c3.1 libzip4 linux-headers-4.4.0-45 linux-headers-4.4.0-45-generic linux-image-4.4.0-45-generic linux-image-extra-4.4.0-45-generic odbcinst odbcinst1debian2 proj-bin proj-data python-crypto python-ecdsa python-paramiko python-pexpect python-ptyprocess python-pyodbc python-pysqlite2 python-six Use 'sudo apt autoremove' to remove them. The following additional packages will be installed: libmecab2 mysql-client mysql-common mysql-community-client mysql-community-server The following NEW packages will be installed: libmecab2 mysql-client mysql-common mysql-community-client mysql-community-server mysql-server 0 upgraded, 6 newly installed, 0 to remove and 9 not upgraded. Need to get 32,4 MB of archives. After this operation, 240 MB of additional disk space will be used. Do you want to continue? [Y/n] Get:1 http://br.archive.ubuntu.com/ubuntu xenial/universe amd64 libmecab2 amd64 0.996-1.2ubuntu1 [264 kB] Get:2 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 amd64 mysql-common amd64 5.7.17-1ubuntu16.04 [71,3 kB] Get:3 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 amd64 mysql-community-client amd64 5.7.17-1ubuntu16.04 [7.357 kB] Get:4 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 amd64 mysql-client amd64 5.7.17-1ubuntu16.04 [12,6 kB] Get:5 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 amd64 mysql-community-server amd64 5.7.17-1ubuntu16.04 [24,7 MB] Get:6 http://repo.mysql.com/apt/ubuntu xenial/mysql-5.7 amd64 mysql-server amd64 5.7.17-1ubuntu16.04 [12,6 kB] Fetched 32,4 MB in 2s (10,9 MB/s) Preconfiguring packages ... Selecting previously unselected package mysql-common. (Reading database ... 241812 files and directories currently installed.) Preparing to unpack .../mysql-common_5.7.17-1ubuntu16.04_amd64.deb ... Unpacking mysql-common (5.7.17-1ubuntu16.04) ... dpkg: warning: mysql-common: conffile '/etc/mysql/conf.d/mysql.cnf' is not a plain file or symlink (= '/etc/mysql/conf.d/mysql.cnf') Selecting previously unselected package mysql-community-client. Preparing to unpack .../mysql-community-client_5.7.17-1ubuntu16.04_amd64.deb ... Unpacking mysql-community-client (5.7.17-1ubuntu16.04) ... Selecting previously unselected package mysql-client. Preparing to unpack .../mysql-client_5.7.17-1ubuntu16.04_amd64.deb ... Unpacking mysql-client (5.7.17-1ubuntu16.04) ... Selecting previously unselected package libmecab2. Preparing to unpack .../libmecab2_0.996-1.2ubuntu1_amd64.deb ... Unpacking libmecab2 (0.996-1.2ubuntu1) ... Selecting previously unselected package mysql-community-server. Preparing to unpack .../mysql-community-server_5.7.17-1ubuntu16.04_amd64.deb ... Unpacking mysql-community-server (5.7.17-1ubuntu16.04) ... Selecting previously unselected package mysql-server. Preparing to unpack .../mysql-server_5.7.17-1ubuntu16.04_amd64.deb ... Unpacking mysql-server (5.7.17-1ubuntu16.04) ... Processing triggers for man-db (2.7.5-1) ... Processing triggers for libc-bin (2.23-0ubuntu5) ... Processing triggers for systemd (229-4ubuntu13) ... Processing triggers for ureadahead (0.100.0-19) ... Setting up mysql-common (5.7.17-1ubuntu16.04) ... dpkg: warning: mysql-common: conffile '/etc/mysql/conf.d/mysql.cnf' is not a plain file or symlink (= '/etc/mysql/conf.d/mysql.cnf') update-alternatives: using /etc/mysql/my.cnf.fallback to provide /etc/mysql/my.cnf (my.cnf) in auto mode Setting up mysql-community-client (5.7.17-1ubuntu16.04) ... Setting up mysql-client (5.7.17-1ubuntu16.04) ... Setting up libmecab2 (0.996-1.2ubuntu1) ... Setting up mysql-community-server (5.7.17-1ubuntu16.04) ... update-alternatives: using /etc/mysql/mysql.cnf to provide /etc/mysql/my.cnf (my.cnf) in auto mode Setting up mysql-server (5.7.17-1ubuntu16.04) ... Processing triggers for libc-bin (2.23-0ubuntu5) ... Processing triggers for systemd (229-4ubuntu13) ... Processing triggers for ureadahead (0.100.0-19) ...
[2 Jan 2017 8:09]
Lars Tangvald
Hi, This looks like it's caused by a previous package being partially removed. Deleting files in /etc/mysql is seen by apt as a config customization, so it won't put those files (which the package requires) back on a new install. The installation failing if that file is missing isn't good, though, so we can try to fix that. In the meantime, can you try purging mysql-common (apt-get purge mysql-common), then reinstalling?
[2 Jan 2017 8:32]
Shahriyar Rzayev
Hi, The result of mentioned command: sh@sh-ubuntu:~$ sudo apt-get remove --purge mysql-common Reading package lists... Done Building dependency tree Reading state information... Done The following package was automatically installed and is no longer required: libmecab2 Use 'sudo apt autoremove' to remove it. The following packages will be REMOVED: mysql-common* 0 upgraded, 0 newly installed, 1 to remove and 14 not upgraded. After this operation, 0 B of additional disk space will be used. Do you want to continue? [Y/n] Y (Reading database ... 352481 files and directories currently installed.) Removing mysql-common (5.7.17-1ubuntu16.04) ... Purging configuration files for mysql-common (5.7.17-1ubuntu16.04) ... update-alternatives: error: no alternatives for my.cnf dpkg: error processing package mysql-common (--purge): subprocess installed post-removal script returned error exit status 2 Errors were encountered while processing: mysql-common E: Sub-process /usr/bin/dpkg returned an error code (1)