WHM MySQL query for adding multiple CPanel MySQL users at once

jamesbond

Well-Known Member
Oct 9, 2002
737
1
168
After restoring backups to a new server the cpanel mysql users are not showing up in WHM's PHPMyAdmin

I have a list of all the usernames/passwords, but recreating them one by one through each site's CPanel will take a long time.

If there is a way to just execute the SQL queries directly in WHM's PHPMyAdmin that would save my lot of time.

Does anyone know what the query would like look for creating a new cpanel user and giving them ALL PRIVILEGES to a database?
 

ravindradhainwa

Well-Known Member
Jan 24, 2008
45
1
56
Hi,

You can try to restore following DB Table from old server to new server.

/var/lib/mysql/mysql/user*