-1
我一直在使用zip文件安裝的MySQL在C:\web\mysql
無法打開MySQL的控制檯窗口10
的my.cnf
文件的內容有以下線
[mysqld]
basedir="C:/web/mysql"
datadir="C:/web/data"
explicit_defaults_for_timestamp = 1
innodb_data_home_dir="C:/data"
我無法打開MySQL的控制檯,我得到這些
2017-04-20T04:40:10.568049Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2017-04-20T04:40:10.599302Z 0 [Warning] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
2017-04-20T04:40:10.617473Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2017-04-20T04:40:10.621449Z 0 [Note] IPv6 is available.
2017-04-20T04:40:10.637103Z 0 [Note] - '::' resolves to '::';
2017-04-20T04:40:10.637103Z 0 [Note] Server socket created on IP: '::'.
2017-04-20T04:40:10.668373Z 0 [Warning] Failed to open optimizer cost constant tables
2017-04-20T04:40:10.668373Z 0 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.user' doesn't exist
2017-04-20T04:40:10.715453Z 0 [ERROR] Aborting
請參閱並提出任何可能的解決方法。
感謝
編輯我通過運行
"C:\web\mysql\bin\mysqld" --initialize --console
解決這些錯誤,但現在我得到錯誤的
ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)
請看看是什麼問題。
感謝