我最近在 Kubuntu 20.10 中安装了 MySQL。由于 Akonadi 和 Kmail 无法与 MySQL 配合使用,我最终删除了 MySQL 并安装了 MariaDB。安装 MariaDB 后,我似乎无法启动或启用数据库的 systemd 服务。当我运行systemctl start mariadb
命令时,它挂起了。
● mariadb.service - MariaDB 10.3.25 database server
Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; vendor preset: enabled)
Active: failed (Result: timeout) since Sat 2020-10-31 00:40:52 EDT; 2 days ago
Docs: man:mysqld(8)
https://mariadb.com/kb/en/library/systemd/
Process: 1208 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root -d /var/run/mysqld (code=exited, status=0/SUCCESS)
Process: 1232 ExecStartPre=/bin/sh -c systemctl unset-environment _WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Process: 1247 ExecStartPre=/bin/sh -c [ ! -e /usr/bin/galera_recovery ] && VAR= || VAR=`cd /usr/bin/..; /usr/bin/galera_recovery`; [ >
Process: 1322 ExecStart=/usr/sbin/mysqld $MYSQLD_OPTS $_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=0/SUCCESS)
Main PID: 1322 (code=exited, status=0/SUCCESS)
Oct 31 00:25:50 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 31 00:25:50 brian-pc mysqld[1322]: 2020-10-31 0:25:50 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process >
Oct 31 00:25:50 brian-pc mysqld[1322]: 2020-10-31 0:25:50 0 [Warning] Could not increase number of max_open_files to more than 16384 (requ>
Oct 31 00:40:50 brian-pc systemd[1]: mariadb.service: start operation timed out. Terminating.
Oct 31 00:40:52 brian-pc systemd[1]: mariadb.service: Failed with result 'timeout'.
Oct 31 00:40:52 brian-pc systemd[1]: Failed to start MariaDB 10.3.25 database server.
输出mariadb --version
mariadb Ver 15.1 Distrib 10.3.25-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2
这些是显示的日志journalctl -u mariadb
-- Logs begin at Tue 2020-10-27 14:45:24 EDT, end at Mon 2020-11-02 12:10:17 EST. --
Oct 28 17:06:02 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 28 17:06:02 brian-pc mysqld[37262]: 2020-10-28 17:06:02 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 37262 ...
Oct 28 17:06:02 brian-pc mysqld[37262]: 2020-10-28 17:06:02 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 28 17:06:02 brian-pc systemd[1]: Started MariaDB 10.3.25 database server.
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Looking for 'mysql' as: /usr/bin/mysql
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Looking for 'mysqlcheck' as: /usr/bin/mysqlcheck
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 1/7: Checking and upgrading mysql database
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Processing databases
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.column_stats OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.columns_priv OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.db OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.event OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.func OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.gtid_slave_pos OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.help_category OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.help_keyword OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.help_relation OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.help_topic OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.host OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.index_stats OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.innodb_index_stats OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.innodb_table_stats OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.plugin OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.proc OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.procs_priv OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.proxies_priv OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.roles_mapping OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.servers OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.table_stats OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.tables_priv OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.time_zone OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.time_zone_leap_second OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.time_zone_name OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.time_zone_transition OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.time_zone_transition_type OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.transaction_registry OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql.user OK
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 2/7: Installing used storage engines... Skipped
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 3/7: Fixing views
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Processing databases
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: information_schema
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: performance_schema
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 4/7: Running 'mysql_fix_privilege_tables'
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 5/7: Fixing table and database names
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Processing databases
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: information_schema
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: mysql
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: performance_schema
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 6/7: Checking and upgrading tables
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Processing databases
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: information_schema
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: performance_schema
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: Phase 7/7: Running 'FLUSH PRIVILEGES'
Oct 28 17:06:03 brian-pc /etc/mysql/debian-start[37300]: OK
Oct 28 17:06:03 brian-pc debian-start[37460]: WARNING: tempfile is deprecated; consider using mktemp instead.
Oct 28 17:10:43 brian-pc systemd[1]: Stopping MariaDB 10.3.25 database server...
Oct 28 17:10:45 brian-pc systemd[1]: mariadb.service: Succeeded.
Oct 28 17:10:45 brian-pc systemd[1]: Stopped MariaDB 10.3.25 database server.
Oct 28 17:10:45 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 28 17:10:45 brian-pc mysqld[48722]: 2020-10-28 17:10:45 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 48722 ...
Oct 28 17:10:45 brian-pc mysqld[48722]: 2020-10-28 17:10:45 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 28 17:10:45 brian-pc systemd[1]: Started MariaDB 10.3.25 database server.
Oct 28 17:10:45 brian-pc debian-start[48791]: ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
-- Reboot --
Oct 29 11:35:05 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 11:35:05 brian-pc mysqld[1191]: 2020-10-29 11:35:05 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 1191 ...
Oct 29 11:35:05 brian-pc mysqld[1191]: 2020-10-29 11:35:05 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 11:50:05 brian-pc systemd[1]: mariadb.service: start operation timed out. Terminating.
Oct 29 11:50:07 brian-pc systemd[1]: mariadb.service: Failed with result 'timeout'.
Oct 29 11:50:07 brian-pc systemd[1]: Failed to start MariaDB 10.3.25 database server.
Oct 29 17:53:41 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 17:53:41 brian-pc mysqld[18581]: 2020-10-29 17:53:41 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 18581 ...
Oct 29 17:53:41 brian-pc mysqld[18581]: 2020-10-29 17:53:41 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 17:57:12 brian-pc systemd[1]: mariadb.service: Succeeded.
Oct 29 17:57:12 brian-pc systemd[1]: Stopped MariaDB 10.3.25 database server.
Oct 29 17:58:09 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 17:58:09 brian-pc mysqld[19222]: 2020-10-29 17:58:09 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 19222 ...
Oct 29 17:58:09 brian-pc mysqld[19222]: 2020-10-29 17:58:09 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 17:59:03 brian-pc systemd[1]: mariadb.service: Succeeded.
Oct 29 17:59:03 brian-pc systemd[1]: Stopped MariaDB 10.3.25 database server.
Oct 29 17:59:08 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 17:59:08 brian-pc mysqld[19581]: 2020-10-29 17:59:08 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 19581 ...
Oct 29 17:59:08 brian-pc mysqld[19581]: 2020-10-29 17:59:08 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 17:59:23 brian-pc systemd[1]: mariadb.service: Succeeded.
Oct 29 17:59:23 brian-pc systemd[1]: Stopped MariaDB 10.3.25 database server.
-- Reboot --
Oct 29 18:03:28 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 18:03:29 brian-pc mysqld[1200]: 2020-10-29 18:03:29 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 1200 ...
Oct 29 18:03:29 brian-pc mysqld[1200]: 2020-10-29 18:03:29 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 18:07:01 brian-pc systemd[1]: mariadb.service: Succeeded.
Oct 29 18:07:01 brian-pc systemd[1]: Stopped MariaDB 10.3.25 database server.
Oct 29 18:07:10 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 18:07:10 brian-pc mysqld[4379]: 2020-10-29 18:07:10 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 4379 ...
Oct 29 18:07:10 brian-pc mysqld[4379]: 2020-10-29 18:07:10 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 18:22:10 brian-pc systemd[1]: mariadb.service: start operation timed out. Terminating.
Oct 29 18:22:12 brian-pc systemd[1]: mariadb.service: Failed with result 'timeout'.
Oct 29 18:22:12 brian-pc systemd[1]: Failed to start MariaDB 10.3.25 database server.
Oct 29 18:34:44 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 18:34:44 brian-pc mysqld[10365]: 2020-10-29 18:34:44 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 10365 ...
Oct 29 18:34:44 brian-pc mysqld[10365]: 2020-10-29 18:34:44 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 18:49:44 brian-pc systemd[1]: mariadb.service: start operation timed out. Terminating.
Oct 29 18:49:45 brian-pc systemd[1]: mariadb.service: Failed with result 'timeout'.
Oct 29 18:49:45 brian-pc systemd[1]: Failed to start MariaDB 10.3.25 database server.
Oct 29 18:58:15 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 29 18:58:15 brian-pc mysqld[16847]: 2020-10-29 18:58:15 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 16847 ...
Oct 29 18:58:15 brian-pc mysqld[16847]: 2020-10-29 18:58:15 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 29 18:58:15 brian-pc systemd[1]: Started MariaDB 10.3.25 database server.
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Looking for 'mysql' as: /usr/bin/mysql
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Looking for 'mysqlcheck' as: /usr/bin/mysqlcheck
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 1/7: Checking and upgrading mysql database
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Processing databases
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.column_stats OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.columns_priv OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.db OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.event OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.func OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.gtid_slave_pos OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.help_category OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.help_keyword OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.help_relation OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.help_topic OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.host OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.index_stats OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.innodb_index_stats OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.innodb_table_stats OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.plugin OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.proc OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.procs_priv OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.proxies_priv OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.roles_mapping OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.servers OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.table_stats OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.tables_priv OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.time_zone OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.time_zone_leap_second OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.time_zone_name OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.time_zone_transition OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.time_zone_transition_type OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.transaction_registry OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql.user OK
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 2/7: Installing used storage engines... Skipped
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 3/7: Fixing views
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Processing databases
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: information_schema
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: performance_schema
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 4/7: Running 'mysql_fix_privilege_tables'
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 5/7: Fixing table and database names
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Processing databases
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: information_schema
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: mysql
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: performance_schema
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 6/7: Checking and upgrading tables
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Processing databases
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: information_schema
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: performance_schema
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: Phase 7/7: Running 'FLUSH PRIVILEGES'
Oct 29 18:58:16 brian-pc /etc/mysql/debian-start[16885]: OK
Oct 29 18:58:16 brian-pc debian-start[16992]: WARNING: tempfile is deprecated; consider using mktemp instead.
Oct 31 00:06:06 brian-pc systemd[1]: Stopping MariaDB 10.3.25 database server...
Oct 31 00:06:09 brian-pc systemd[1]: mariadb.service: Succeeded.
Oct 31 00:06:09 brian-pc systemd[1]: Stopped MariaDB 10.3.25 database server.
-- Reboot --
Oct 31 00:06:50 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 31 00:06:51 brian-pc mysqld[1207]: 2020-10-31 0:06:51 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 1207 ...
Oct 31 00:06:51 brian-pc mysqld[1207]: 2020-10-31 0:06:51 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 31 00:21:51 brian-pc systemd[1]: mariadb.service: start operation timed out. Terminating.
Oct 31 00:21:52 brian-pc systemd[1]: mariadb.service: Failed with result 'timeout'.
Oct 31 00:21:52 brian-pc systemd[1]: Failed to start MariaDB 10.3.25 database server.
-- Reboot --
Oct 31 00:23:10 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 31 00:23:10 brian-pc mysqld[1180]: 2020-10-31 0:23:10 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 1180 ...
Oct 31 00:23:10 brian-pc mysqld[1180]: 2020-10-31 0:23:10 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
-- Reboot --
Oct 31 00:25:50 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Oct 31 00:25:50 brian-pc mysqld[1322]: 2020-10-31 0:25:50 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 1322 ...
Oct 31 00:25:50 brian-pc mysqld[1322]: 2020-10-31 0:25:50 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
Oct 31 00:40:50 brian-pc systemd[1]: mariadb.service: start operation timed out. Terminating.
Oct 31 00:40:52 brian-pc systemd[1]: mariadb.service: Failed with result 'timeout'.
Oct 31 00:40:52 brian-pc systemd[1]: Failed to start MariaDB 10.3.25 database server.
Nov 02 11:58:48 brian-pc systemd[1]: Starting MariaDB 10.3.25 database server...
Nov 02 11:58:48 brian-pc mysqld[25967]: 2020-11-02 11:58:48 0 [Note] /usr/sbin/mysqld (mysqld 10.3.25-MariaDB-0ubuntu1) starting as process 25967 ...
Nov 02 11:58:48 brian-pc mysqld[25967]: 2020-11-02 11:58:48 0 [Warning] Could not increase number of max_open_files to more than 16384 (request: 32194)
答案1
这很可能是由于 MySQL 的 AppArmor 配置文件无法正确删除造成的。请参阅:https://mariadb.com/kb/en/the-community-mariadb-troubles-only-running-after-reboot-times-out-when-try/
由于 MariaDB 没有 Apparmor 配置文件(已被注释掉),您可以禁用有问题的配置文件:
sudo ln -s /etc/apparmor.d/usr.sbin.mysqld /etc/apparmor.d/disable/
sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
您可以使用以下方法进行验证:
sudo aa-status
如果安装或升级失败,您可以通过以下方式完成:
sudo dpkg --configure mariadb-server
否则