There are times when it’s advantageous to create a new user for an existing database. This can be particularly helpful in a site compromise, where the database credentials should be changed in order to ensure that the criminals no longer have access to the database. I’ll be using CPanel for this tutorial, but it should be fairly straightforward to determine similar functions on other control panels as well.
To create the new user, add the desired username in the edit field, Then type & confirm the password in the 2 boxes provided. Once finished, click the ‘Create User’ button. Remember that the part that ends w/an _ is part of the username.
Once finished, return to the same screen & scroll down to ‘Add User’. Pick your newly created user from the dropdown list, pick the database you wish to add the user to, & click the ‘Add’ button.
That’s it. You’ve now added a new user to a database.