我今天早些时候尝试制作 LEMP Stack,但在安装 MySQL 或 MariaDB 时遇到了问题。它们都遇到了问题
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libdbd-mysql-perl libmariadbclient18 libmysqlclient18 libmysqlclient20 mariadb-client-10.0 mariadb-client-core-10.0 mariadb-common
mariadb-server-10.0 mariadb-server-core-10.0 mysql-common
Suggested packages:
libterm-readkey-perl mailx mariadb-test tinyca
The following NEW packages will be installed:
libdbd-mysql-perl libmariadbclient18 libmysqlclient18 libmysqlclient20 mariadb-client-10.0 mariadb-client-core-10.0 mariadb-common mariadb-server
mariadb-server-10.0 mariadb-server-core-10.0 mysql-common
0 upgraded, 11 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/13.5 MB of archives.
After this operation, 138 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Preconfiguring packages ...
Selecting previously unselected package mysql-common.
(Reading database ... 145130 files and directories currently installed.)
Preparing to unpack .../mysql-common_10.0.28+maria-1~trusty_all.deb ...
Unpacking mysql-common (10.0.28+maria-1~trusty) ...
Selecting previously unselected package mariadb-common.
Preparing to unpack .../mariadb-common_10.0.28+maria-1~trusty_all.deb ...
Unpacking mariadb-common (10.0.28+maria-1~trusty) ...
Selecting previously unselected package libmysqlclient20:amd64.
Preparing to unpack .../libmysqlclient20_5.7.16-0ubuntu0.16.04.1_amd64.deb ...
Unpacking libmysqlclient20:amd64 (5.7.16-0ubuntu0.16.04.1) ...
Selecting previously unselected package libdbd-mysql-perl.
Preparing to unpack .../libdbd-mysql-perl_4.033-1ubuntu0.1_amd64.deb ...
Unpacking libdbd-mysql-perl (4.033-1ubuntu0.1) ...
Selecting previously unselected package libmysqlclient18.
Preparing to unpack .../libmysqlclient18_10.0.28+maria-1~trusty_amd64.deb ...
Unpacking libmysqlclient18 (10.0.28+maria-1~trusty) ...
Selecting previously unselected package libmariadbclient18.
Preparing to unpack .../libmariadbclient18_10.0.28+maria-1~trusty_amd64.deb ...
Unpacking libmariadbclient18 (10.0.28+maria-1~trusty) ...
Selecting previously unselected package mariadb-client-core-10.0.
Preparing to unpack .../mariadb-client-core-10.0_10.0.28+maria-1~trusty_amd64.deb ...
Unpacking mariadb-client-core-10.0 (10.0.28+maria-1~trusty) ...
Selecting previously unselected package mariadb-client-10.0.
Preparing to unpack .../mariadb-client-10.0_10.0.28+maria-1~trusty_amd64.deb ...
Unpacking mariadb-client-10.0 (10.0.28+maria-1~trusty) ...
Selecting previously unselected package mariadb-server-core-10.0.
Preparing to unpack .../mariadb-server-core-10.0_10.0.28+maria-1~trusty_amd64.deb ...
Unpacking mariadb-server-core-10.0 (10.0.28+maria-1~trusty) ...
Processing triggers for libc-bin (2.23-0ubuntu4) ...
Processing triggers for man-db (2.7.5-1) ...
Setting up mysql-common (10.0.28+maria-1~trusty) ...
Setting up mariadb-common (10.0.28+maria-1~trusty) ...
Selecting previously unselected package mariadb-server-10.0.
(Reading database ... 145321 files and directories currently installed.)
Preparing to unpack .../mariadb-server-10.0_10.0.28+maria-1~trusty_amd64.deb ...
Unpacking mariadb-server-10.0 (10.0.28+maria-1~trusty) ...
Selecting previously unselected package mariadb-server.
Preparing to unpack .../mariadb-server_10.0.28+maria-1~trusty_all.deb ...
Unpacking mariadb-server (10.0.28+maria-1~trusty) ...
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for systemd (229-4ubuntu12) ...
Processing triggers for ureadahead (0.100.0-19) ...
ureadahead will be reprofiled on next reboot
Setting up libmysqlclient20:amd64 (5.7.16-0ubuntu0.16.04.1) ...
Setting up libdbd-mysql-perl (4.033-1ubuntu0.1) ...
Setting up libmysqlclient18 (10.0.28+maria-1~trusty) ...
Setting up libmariadbclient18 (10.0.28+maria-1~trusty) ...
Setting up mariadb-client-core-10.0 (10.0.28+maria-1~trusty) ...
Setting up mariadb-client-10.0 (10.0.28+maria-1~trusty) ...
Setting up mariadb-server-core-10.0 (10.0.28+maria-1~trusty) ...
Setting up mariadb-server-10.0 (10.0.28+maria-1~trusty) ...
dpkg: error processing package mariadb-server-10.0 (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of mariadb-server:
mariadb-server depends on mariadb-server-10.0 (= 10.0.28+maria-1~trusty); however:
Package mariadb-server-10.0 is not configured yet.
dpkg: error processing package mariadb-server (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
Processing triggers for libc bin (2.23-0ubuntu4) ...
Processing triggers for systemd (229-4ubuntu12) ...
Processing triggers for ureadahead (0.100.0-19) ...
Errors were encountered while processing:
mariadb-server-10.0
mariadb-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
user@UbuntuServerBM ~>
我尝试过彻底清除 mariaDB/mySQL、重新安装 apparmor、禁用 apparmor,甚至尝试安装 MariaDB 5.5
user@UbuntuServerBM /v/l/mysql> sudo apt install mariadb-server-5.5
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
tinyca mailx mariadb-test
The following NEW packages will be installed:
mariadb-server-5.5
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
7 not fully installed or removed.
Need to get 0 B/4,256 kB of archives.
After this operation, 68.2 MB of additional disk space will be used.
Preconfiguring packages ...
(Reading database ... 145321 files and directories currently installed.)
Preparing to unpack .../mariadb-server-5.5_5.5.53+maria-1~trusty_amd64.deb ...
Unpacking mariadb-server-5.5 (5.5.53+maria-1~trusty) ...
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for systemd (229-4ubuntu12) ...
Processing triggers for ureadahead (0.100.0-19) ...
Setting up libmysqlclient20:amd64 (5.7.16-0ubuntu0.16.04.1) ...
Setting up libdbd-mysql-perl (4.033-1ubuntu0.1) ...
Setting up libmysqlclient18 (10.0.28+maria-1~trusty) ...
Setting up libmariadbclient18 (10.0.28+maria-1~trusty) ...
Setting up mariadb-client-core-5.5 (5.5.53+maria-1~trusty) ...
Setting up mariadb-client-5.5 (5.5.53+maria-1~trusty) ...
Setting up mariadb-server-core-5.5 (5.5.53+maria-1~trusty) ...
Setting up mariadb-server-5.5 (5.5.53+maria-1~trusty) ...
dpkg: error processing package mariadb-server-5.5 (--configure):
subprocess installed post-installation script returned error exit status 1
Processing triggers for libc-bin (2.23-0ubuntu4) ...
Processing triggers for systemd (229-4ubuntu12) ...
Processing triggers for ureadahead (0.100.0-19) ...
Errors were encountered while processing:
mariadb-server-5.5
E: Sub-process /usr/bin/dpkg returned an error code (1)
我和一个朋友尝试过解决这个问题,但没有进展。