Last active
January 29, 2016 19:51
-
-
Save mrsweaters/817dc0a0bf9dde7662ff to your computer and use it in GitHub Desktop.
create and grant mysql permissions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mysql> CREATE USER '<user>'@'%' IDENTIFIED BY '<password>'; | |
| mysql> CREATE DATABASE <database_name>; | |
| mysql> GRANT ALL PRIVILEGES on <database_name>.* To <user>@'%'; | |
| mysql> FLUSH PRIVILEGES; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| GRANT ALL PRIVILEGES ON dbName.* To 'username'@'host' IDENTIFIED BY 'password'; |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
dump database without insert so we can rename the database in aws:
mysqldump -u username -ppassword -h host --opt --skip-extended-insert old_db_name > ~/dump.sql