MacOS Can't start MySQL Server

后端 未结 9 922
甜味超标
甜味超标 2021-02-13 03:58

I have MacOS Sierra. I have installed MySQL Server which has been working, however, after a reboot of the Mac Book, I cannot start the MySQL Server.

I have trie

9条回答
  •  南笙
    南笙 (楼主)
    2021-02-13 04:32

    After a discussion with Richard, the following solves the issue:

    my.cnf:

    [client]
    
    port = 3306
    socket = /tmp/mysql.sock
    
    
    [mysqld]
    
    port = 3306
    socket = /tmp/mysql.sock
    datadir = /usr/local/mysql-5.7.17-macos10.12-x86_64/data
    tmpdir = /tmp
    

    Essentially, although we'd added the relevant stanza's to the my.cnf file, we'd still missed the section heading. Adding the [mysqld] section allowed mysql to start.

提交回复
热议问题