Last active
August 29, 2015 14:06
-
-
Save thomasfr/d1e4fde76b2585380752 to your computer and use it in GitHub Desktop.
Create Mysql user, password and grant rights on database
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 [type of permission] ON [database name].[table name] TO ‘[username]’@'localhost’ IDENTIFIED BY 'some_pass' WITH GRANT OPTION; **/ | |
GRANT ALL PRIVILEGES ON DATABASE.* TO 'newuser'@'localhost' IDENTIFIED BY 'some_pass'; | |
FLUSH PRIVILEGES; | |
/** BACKUP USER **/ | |
GRANT SELECT,LOCK TABLES ON *.* TO 'backup'@'localhost' IDENTIFIED BY 'PASS'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment