How to create additional super user in RDS MySQL
RDS have only one super user by default when the instance is created. But we can create users the same permissions as the master user.
This article explains the steps to create additional master user in RDS MySQL.
Step1: Login to the RDS MySQL instance as super user.
#myql -h <host> -u <username> -p
Here we need to replace host, username with the required values and it will ask for the password as stdin.
Step2: Create the new user.
>CREATE USER 'name'@'%' IDENTIFIED BY 'password';
Here we need to replace name, password with the required values.
Step3: Assign super user privileges to the new user.
>GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, PROCESS, REFERENCES, INDEX, ALTER, SHOW DATABASES, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, REPLICATION SLAVE, REPLICATION CLIENT, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER ON *.* TO 'name'@'%' WITH GRANT OPTION;
Where replace name with the with new username that created.