Commonly used permission set in MySQL

Here is some MySQL permission set that I am normally used, I am now sharing them to you.

1. Standard step to create database and grant all permission to mickgenie_wordpress.

mysql>create database mickgenie_wordpress;
Query OK,1 row affected (0.00 sec)
mysql>grant all on mickgenie_wordpress.* to [email protected] identified by 'password';
Query OK,0 rows affected (0.00 sec)

2. Grant create view on mickgenie_user to database mickgenie_wordpress.

mysql>grant select,insert,update,delete,create,drop,index,alter,create temporary tables,lock tables ,CREATE VIEW,CREATE ROUTINE,REFERENCES,EXECUTE,ALTER ROUTINE  on mickgenie_wordpress.* to [email protected] identified by 'password';
Query OK,0 rows affected (0.00 sec)

3. Grant remote access to mickgenie_wordpress.

mysql>grant all on mickgenie_wordpress.* to [email protected] identified by 'password';
Query OK,0 rows affected (0.00 sec)

4. Grant read only user to mickgenie_wordpress.

mysql>grant select on mickgenie_wordpress.* to [email protected] identified by 'password';
Query OK,0 rows affected (0.00 sec)

Published by

Mick Genie

Mick Genie is the founder of MickGenie.com and working at ExaBytes Network Sdn Bhd and WPWebHost web host company. He is expertise in Windows and Linux environment especially web hosting related information, tips and trick as well as the IT Information.