How to convert a user to superuser
Make sure you are connected with root/admin user:
mysql configurationintermediate
by MYSQL
13 views
Make sure you are connected with root/admin user:
12345678910111213141516171819202122232425
mysql>
select current_user();
+----------------+
| current_user() |
+----------------+
| root@localhost |
+----------------+
1 row in set (0.00 sec)
mysql>
CREATE user 'super'@'%' IDENTIFIED BY 'super';
Query OK, 0 rows affected (0.02 sec)
mysql>
CREATE user 'super'@'localhost' IDENTIFIED BY 'super';
Query OK, 0 rows affected (0.02 sec)
mysql>
GRANT ALL PRIVILEGES ON *.* TO 'super'@'%' WITH GRANT OPTION;
Query OK, 0 rows affected (0.03 sec)
mysql>
GRANT ALL PRIVILEGES ON *.* TO 'super'@'localhost' WITH GRANT OPTION;
Query OK, 0 rows affected (0.03 sec)
mysql>
FLUSH PRIVILEGES;
Query OK, 0 rows affected (0.02 sec)
mysql>
show grants for super;Please to add comments
No comments yet. Be the first to comment!