Use a separate Server for MySQL in clustering with cPanel/WHM Server

chrisnagios

Member
Feb 4, 2010
19
0
51
Hello,


I currently have some dedicated servers for shared hosting clients,
and most of them are hosting 500+ accounts, but my issue in all
servers, is the Database overload...


Is there any way to have completely disabled the MySQL in a cPanel/WHM Server
and configure it to use another standalone server that has just MySQL installed,
but still work automated, like for dbs and users creation etc ???


Thanks for any suggestions!
 

chrisnagios

Member
Feb 4, 2010
19
0
51
dalem, thanks a lot for pointing this out !

some questions though:

does the remote mysql server have to be also cPanel/WHM server or it can be just a clean linux with mysql ?

also, this link above does not show how to migrate existing users/dbs, any info on this ?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
Hello :)

cPanel is not required on the remote MySQL server. You must manually import your existing databases/users into the remote MySQL server. The "mysqldump" utility is a good tool for backing up and importing databases.

Thank you.
 

chrisnagios

Member
Feb 4, 2010
19
0
51
Can I use the "system_backup.tar" to get the full DB restored on the MySQL server ???

Also, will this work only with MySQL server or it can also work with MariaDB on the other end ???


Thanks !!!
 

chrisnagios

Member
Feb 4, 2010
19
0
51
Finally, I decided that, maybe the best way to get this running, would be to setup a new clean server,
make it using remote MySQL and then, transfer / copy all accounts from the old server to the new,
so that when accounts get restored / recreated, they automatically get relocated the MySQL into the
remote server...

Please, let me know if this is possible and accurate or if restores would still be using the local DB ???

Finally, on the new server, will I be able to have disabled in service manager the local mysql service or even completely disabled,
or cPanel still uses the local db for internal things, like information schema for quotas and user settings, exim stats etc ???


Thanks on advance for your response and help with this !
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
Hello :)

You will still need to backup and restore the databases manually to the remote MySQL server, as that's not a transfer process facilitated by the cPanel software. The "mysqldump" utility will allow you to backup the databases, and the "mysql" utility will allow you to restore them on the destination server. You can disable MySQL on the cPanel server, but remember to transfer the existing databases created during the cPanel installation to the remote MySQL server.

Thank you.
 

chrisnagios

Member
Feb 4, 2010
19
0
51
what about maria db ???


can the remote server be maria db ?

- - - Updated - - -

also, it is not clear if the remote server does require manual maintainance for backups or not

will cpanel backups work with remote mysql or this does not work ???

based on your earlier post, it seems that restoration would not work either ???????
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
Hello :)

The remote MySQL feature is designed to allow you to remotely manage the MySQL server. You should implement manual backup methods on that server. MariaDB is not yet supported (it's scheduled for version 11.48), but you can follow it's progress here:

MariaDB support | cPanel Feature Requests

Thank you.
 

chrisnagios

Member
Feb 4, 2010
19
0
51
so with remote mysql, both backups and restores will not work ???

- - - Updated - - -

so for example, if an account gets hacked or broken by user error (common),
if we click restore, the db will not be restored ?

the nightly backups will not include the per account DB ???
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
Options such as backups/restores should work as they normally would after you have setup the remote MySQL server. So for instance, if you restore a database through the cPanel UI, that database is restored on the remote MySQL server. The account backups and transfers will consider the remote MySQL server as "local" and backup the databases the same way they are locally. Feel free to test this and let us know if it's not functioning as expected.

Thank you.
 

chrisnagios

Member
Feb 4, 2010
19
0
51
is it possible to define a preinstallation file for remote mysql server, so even cPanel core tables are initially popullated remotely before install and to even completely skip mysql installation during setup ???


thanks !
 

chrisnagios

Member
Feb 4, 2010
19
0
51
i've posted a feature request for this, its in moderation,
can you plz get it approved and get involved to help me
shape/rewrite it properly if needed ?

also, plz post here the url so others can vote for it,
it would be very cool to have this option !!!
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
You should have been provided with a URL to the request upon submissions. Feel free to post it here for others to review.

Thank you.
 

double_t

Member
Dec 2, 2007
19
2
53
If using remote server, apart that there are no backups, I guess that quota won't be supported also, right ?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,909
2,228
463
If using remote server, apart that there are no backups, I guess that quota won't be supported also, right ?
No, disk space usage is calculated for databases on remote MySQL servers as long as you configured the remote MySQL server through WHM.

Thank you.