MySQL: creating a user with root privileges

I want to create a user with all privileges that the root user has, the user must have access to all databases, create databases and be able to grant privileges to other users.

+47
mysql
May 25 '13 at 6:24
source share
1 answer
% mysql --user=root mysql CREATE USER 'monty'@'localhost' IDENTIFIED BY 'some_pass'; GRANT ALL PRIVILEGES ON *.* TO 'monty'@'localhost' WITH GRANT OPTION; CREATE USER 'monty'@'%' IDENTIFIED BY 'some_pass'; GRANT ALL PRIVILEGES ON *.* TO 'monty'@'%' WITH GRANT OPTION; CREATE USER 'admin'@'localhost'; GRANT RELOAD,PROCESS ON *.* TO 'admin'@'localhost'; CREATE USER 'dummy'@'localhost'; FLUSH PRIVILEGES; 
+77
May 25 '13 at 7:07
source share



All Articles