I\'ve tried multiple solutions from StackOverflow but haven\'t had any success. I\'m on Mac OSX (Sierra 10.12.3) trying to create a new database and user. From terminal I
Is it possible the root password is not what you think it is? Have you checked the file /root/.mysql_secret for the password? That is the default location for the automated root password that is generated from starting from version 5.7.
cat /root/.mysql_secret
just use:
$ sudo mysql
without the "-u root" parameter.
Try this (on Windows, i don't know how in others), if you have changed password a now don't work.
1) kill mysql 2) back up /mysql/data folder 3) go to folder /mysql/backup 4) copy files from /mysql/backup/mysql folder to /mysql/data/mysql (rewrite) 5) run mysql
In my XAMPP on Win7 it works.