[SOLVED] ERROR: mysql failed to start
Helloo 19 Августа, 2019 - 09:34
Сразу после установки mysql -- она работала. Настроил конфиги по хендбуку.
Вроде бы ничего я не делал потом, кроме того, что захотелось мне установить к mysql графический веб-интерфейс.
И не знаю, может с этим что-то связано, но mysql перестала стартовать.
Пишет вот такое:
saturn ~ # rc-service mysql start * Checking mysqld configuration for mysql ... [ ok ] * Starting mysql ... * You don't appear to have a server package installed yet. * ERROR: mysql failed to start saturn ~ #
Да, еще когда mysql работала, я удалил из нее стандартные базы данных. Может, с этим связано?
Гуглил, но особыми успехами не увенчалось это дело.
Подскажите, пожалуйста, с чего начать решение проблемы.
Флаги, с которыми установлена СУБД:
Calculating dependencies... done! [ebuild R ] dev-db/mysql-5.7.26:0/18::gentoo USE="perl server -cjk (-client-libs) -cracklib -debug -experimental -jemalloc -latin1 -libressl -numa -profiling (-selinux) -static -static-libs -systemtap -tcmalloc -test -yassl" ABI_X86="32 (64) (-x32)" 0 KiB
И суть этого: You don't appear to have a server package installed yet.?
Не понял этого сообщения, по-русски это же так: похоже, у вас еще не установлен серверный пакет.
Как же, если флаг server включен у меня?
»
- Для комментирования войдите или зарегистрируйтесь

Выполнил снова команду emerge --config dev-db/mysql
Получил:
saturn ~ # emerge --config dev-db/mysql Configuring pkg... * Trying to get password for mysql 'root' user from 'mysql' section ... * Trying to get password for mysql 'root' user from 'client' section ... * Please provide a password for the mysql 'root' user now * or through the /root/.my.cnf file. * Avoid ["'\_%] characters in the password > * Retype the password > * Creating the mysql database and setting proper permissions on it ... * Command: /usr/sbin/mysqld --initialize-insecure --init-file='/var/tmp/portage/dev-db/mysql-5.7.26/temp/tmp.EjyJ64qx0q' --basedir=/usr --loose-skip-host-cache --loose-skip-name-resolve --loose-skip-networking --loose-skip-slave-start --loose-skip-federated --loose-skip-ssl --loose-skip-log-bin --loose-skip-relay-log --loose-skip-slow-query-log --loose-skip-external-locking --loose-skip-log-slave-updates --datadir=/var/lib/mysql --tmpdir=/tmp/ 2019-08-19T08:36:41.076074Z 0 [Warning] Changed limits: max_open_files: 1024 (requested 5000) 2019-08-19T08:36:41.110622Z 0 [Warning] Changed limits: table_open_cache: 431 (requested 2000) 2019-08-19T08:36:41.110973Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). 2019-08-19T08:36:41.113382Z 0 [ERROR] --initialize specified but the data directory has files in it. Aborting. 2019-08-19T08:36:41.113455Z 0 [ERROR] Aborting * ERROR: dev-db/mysql-5.7.26::gentoo failed (config phase): * Failed to initialize mysqld. Please review /var/log/mysql/mysqld.err AND /var/tmp/portage/dev-db/mysql-5.7.26/temp/mysql_install_db.log * * Call stack: * ebuild.sh, line 125: Called pkg_config * environment, line 4629: Called die * The specific snippet of code: * die "Failed to initialize mysqld. Please review ${EPREFIX%/}/var/log/mysql/mysqld.err AND ${TMPDIR%/}/mysql_install_db.log"; * * If you need support, post the output of `emerge --info '=dev-db/mysql-5.7.26::gentoo'`, * the complete build log and the output of `emerge -pqv '=dev-db/mysql-5.7.26::gentoo'`. * The complete build log is located at '/var/tmp/portage/dev-db/mysql-5.7.26/temp/build.log'. * The ebuild environment file is located at '/var/tmp/portage/dev-db/mysql-5.7.26/temp/environment'. * Working directory: '/var/tmp/portage/dev-db/mysql-5.7.26/temp' * S: '/var/tmp/portage/dev-db/mysql-5.7.26/work/mysql-5.7.26' saturn ~ #Обратил внимание на:
--datadir=/var/lib/mysql
2019-08-19T08:36:41.113382Z 0 [ERROR] --initialize specified but the data directory has files in it. Aborting.
Переименовал --datadir=/var/lib/mysql в --datadir=/var/lib/mysql_оld
Снова выполнил emerge --config dev-db/mysql
И все отконфигурировалось заново без ошибок.
Сервер запустился, слава Иисусу.
Люди говорят, что проходит время.
Время говорит, что проходят люди.