TablePlus / DBngin

DB Engine
https://dbngin.com
1.01k stars 19 forks source link

Can't start mysql: Failed to find valid data directory #18

Closed someok closed 4 years ago

someok commented 5 years ago

Please fill out the detail below, it helps me investigate the bug:

  1. Driver (Ex: PostgreSQL 10.0):

    MySQL 8.0.12 MySQL 5.7.23

  2. DBngin build number:

    1.0 (14)

  3. macOS version:

    10.14.1

  4. The steps to reproduce this issue: 2018-12-20T19:15:09.929856Z 0 [System] [MY-010910] [Server] /Users/Shared/DBngin/mysql/8.0.12/bin/mysqld: Shutdown complete (mysqld 8.0.12) MySQL Community Server - GPL. 2018-12-20T19:15:20.400289Z 0 [System] [MY-010116] [Server] /Users/Shared/DBngin/mysql/8.0.12/bin/mysqld (mysqld 8.0.12) starting as process 71450 2018-12-20T19:15:20.404050Z 0 [Warning] [MY-010159] [Server] Setting lower_case_table_names=2 because file system for /Users/wjx/Library/Application Support/com.tinyapp.DBngin/Engines/mysql/6F549A55-2948-4458-8AB3-22567F862EFD/ is case insensitive 2018-12-20T19:15:20.404415Z 0 [Warning] [MY-010122] [Server] One can only use the --user switch if running as root 2018-12-20T19:15:20.409312Z 1 [ERROR] [MY-011011] [Server] Failed to find valid data directory. 2018-12-20T19:15:20.409503Z 0 [ERROR] [MY-010020] [Server] Data Dictionary initialization failed. 2018-12-20T19:15:20.409529Z 0 [ERROR] [MY-010119] [Server] Aborting

ghost commented 4 years ago

https://dev.mysql.com/doc/refman/8.0/en/data-directory-initialization.html

for windows: mysqld --initialize --console

huyphams commented 4 years ago

It's fixed on the build 30. Thanks.

amir-afarin commented 2 years ago

in ubuntu >>>> ' sudo mysqld --initialize --console ' worked