gpt4 book ai didi

mysqld : Can't change dir to data. 服务器没有启动

转载 作者:IT老高 更新时间:2023-10-28 12:54:36 24 4
gpt4 key购买 nike

我用安装程序安装了一个 MySQL 服务器并启动了。重新启动后,我尝试再次启动它并收到错误:

D:\Program Files\MySQL\MySQL Server 5.7\bin>mysqld -u root -p
mysqld: Can't change dir to 'D:\Program Files\MySQL\MySQL Server 5.7\data\' (Errcode: 2 - No such file or directory)
2015-11-17T08:30:18.822962Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2015-11-17T08:30:18.822962Z 0 [Warning] Insecure configuration for --secure- file -priv: Current value does not restrict location of generated files. Consider setting it to a valid, non-empty path.
2015-11-17T08:30:18.822962Z 0 [Note] mysqld (mysqld 5.7.9) starting as process 1108 ...
2015-11-17T08:30:18.838586Z 0 [Warning] Can't create test file D:\Program Files\MySQL\MySQL Server 5.7\data\DESKTOP-RNBR3E8.lower-test
2015-11-17T08:30:18.838586Z 0 [Warning] Can't create test file D:\Program Files\MySQL\MySQL Server 5.7\data\DESKTOP-RNBR3E8.lower-test
2015-11-17T08:30:18.838586Z 0 [ERROR] failed to set datadir to D:\Program Files\MySQL\MySQL Server 5.7\data\
2015-11-17T08:30:18.838586Z 0 [ERROR] Aborting


2015-11-17T08:30:18.838586Z 0 [Note] Binlog end
2015-11-17T08:30:18.838586Z 0 [Note] mysqld: Shutdown complete

我尝试重新安装 MySQL。
更新:
当我以管理员身份运行 mysqld -u root -p 时,什么也没有发生。

最佳答案

我遇到了同样的问题。就我而言,我没有 ..\data目录在我的C:\mysql\所以我刚刚执行了mysqld --initialize来自 c:\mysql\bin\ 的命令目录,我得到了 c:\mysql\data 中的数据目录.之后我可以使用 mysqld.exe --console命令来测试服务器启动。

关于mysqld : Can't change dir to data. 服务器没有启动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33752407/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com