Will Restoring an Account Backup Delete Other Databases?


Sep 19, 2010
Long story short: I have many accounts in WHM, many domains. However, most of the MySQL databases were created under one user, "admin" (let's say it's admin.com). I recently moved the admin.com account to another web server , and now I need to move it back. I would like to restore this account from a backup made by that web server. However, it only has 3 databases attached to that domain, while the server I'm moving it to has those 3 databases (old dbs that need to be replaced), PLUS all the other databases which are used by other accounts on the server.

My question: if I restore the admin.com account, will it delete all the other databases on the account, or will it only replace the 3 DBs it has? I can't take any chances here to delete all those other DBs...

If it WOULD delete all those other accounts, how would I go about restoring this account without losing the other data? An easy to way to resolve this situation would be to move the mysql owners to the proper accounts, but alas it doesn't seem that there is a way to do that via WHM.

Any advice? Thanks.


Quality Assurance Analyst
Staff member
Oct 2, 2010
somewhere over the rainbow
cPanel Access Level
Root Administrator

Because the databases would be associated with the admin account, the account will fail to restore to the server due to the duplication. You'll have to drop the databases and account anyway on that old machine. You would want to make a backup of the databases before doing so:

mysqldump --add-drop-table dbname > /home/dbname.sql
Please replace dbname with the name of the database being backed up.

To restore the database afterward, you could do:

mysql dbname < /home/dbname.sql
Again, please replace dbname with the name of the database.