mysql> create database test; ERROR 1006 (HY000): Can't create database 'test' (errno: 2)

后端 未结 4 2155
迷失自我
迷失自我 2021-01-05 14:32

I can\'t create a database after logging in mysql under my root account. Do I have to make an admin account to do so? Also, for some reason, my StartUp file didn\'t install

4条回答
  •  迷失自我
    2021-01-05 15:06

    As an additional resource, you can try two other things:

    1. Find out the data folder for your MySQL and 'chown' it so that mysql can write properly to it. For example, if your MySQL's data folder is /usr/local/mysql/data/, you can 'chown' it by typing up the command chown -R mysql:mysql /usr/local/mysql/data/

    2. If you have just installed your MySQL server, try restarting your computer. Sometimes the installer fails on giving proper file access to the program

    I hope that helps!

提交回复
热议问题