Проблема с запуском mariadb (mysqld 10.1.37-MariaDB-0+deb9u1) поверх systemd в Debian Stretch после последнего обновления.
Linux 4.9.0-8-amd64 #1 SMP Debian 4.9.130-2 (2018-10-27) x86_64 GNU/Linux
: # tail -n 10 /var/log/syslog
Jan 10 10:40:45 fsrv mysqld[24116]: 2019-01-10 10:40:45 140402857677248 [Warning] Can't create test file /home/mysql/fsrv.lower-test
Jan 10 10:40:45 fsrv mysqld[24116]: #007/usr/sbin/mysqld: Can't change dir to '/home/mysql/' (Errcode: 13 "Permission denied")
Jan 10 10:40:45 fsrv mysqld[24116]: 2019-01-10 10:40:45 140402857677248 [ERROR] Aborting
Jan 10 10:40:45 fsrv systemd[1]: mariadb.service: Main process exited, code=exited, status=1/FAILURE
Jan 10 10:40:45 fsrv systemd[1]: Failed to start MariaDB 10.1.37 database server.
Jan 10 10:40:45 fsrv systemd[1]: mariadb.service: Unit entered failed state.
Jan 10 10:40:45 fsrv systemd[1]: mariadb.service: Failed with result 'exit-code'.
После этого я проверяю разрешение на рабочем каталоге mysqld # ls -lh /home/mysql
total 227M
drwxr-xr-x 2 mysql mysql 4.0K Feb 19 2016 access
-rwxr-xr-x 1 mysql mysql 16K Jan 10 10:39 aria_log.00000001
-rwxr-xr-x 1 mysql mysql 52 Jan 10 10:39 aria_log_control
drwxr-xr-x 2 mysql mysql 4.0K Mar 3 2016 auto
-rwxr-xr-x 1 mysql mysql 0 Feb 18 2016 debian-5.5.flag
drwxr-xr-x 2 mysql mysql 4.0K Nov 28 2017 glove
drwxr-xr-x 2 mysql mysql 4.0K Aug 3 15:49 Guard
-rwxr-xr-x 1 mysql mysql 130M Jan 10 10:40 ibdata1
-rwxr-xr-x 1 mysql mysql 48M Jan 10 10:40 ib_logfile0
-rwxr-xr-x 1 mysql mysql 48M Feb 15 2018 ib_logfile1
-rwxr-xr-x 1 mysql mysql 0 Feb 15 2018 multi-master.info
drwxr-xr-x 2 mysql mysql 4.0K Jan 9 15:17 mysql
-rwxr-xr-x 1 mysql mysql 6 Dec 15 2017 mysql_upgrade_info
drwxr-xr-x 2 mysql mysql 4.0K Feb 15 2018 old_guard
drwxr-xr-x 2 mysql mysql 4.0K Jan 9 15:17 performance_schema
drwxr-xr-x 2 mysql mysql 4.0K Feb 15 2018 phpmyadmin
-rwxr-xr-x 1 mysql mysql 24K Jan 10 10:40 tc.log
drwxr-xr-x 2 mysql mysql 4.0K Nov 19 14:47 TempGuard
drwxr-xr-x 2 mysql mysql 4.0K Feb 14 2018 test
У пользователя mysql есть разрешение на запись, но он не может запуститься.
Из консоли запускается mysqld: /usr/sbin/mysqld
2019-01-10 11:04:52 140460271694272 [Note] Using unique option prefix 'key_buffer' is error-prone and can break in the future. Please use the full name 'key_buffer_size' instead.
2019-01-10 11:04:52 140460271694272 [Note] /usr/sbin/mysqld (mysqld 10.1.37-MariaDB-0+deb9u1) starting as process 25616 ...