(Home >> SQL Services >> Setup Remote MySQL Server)
This feature allows you to place your MySQL databases on a remote cPanel & WHM server that runs MySQL. A separate server for MySQL can be useful for busy servers or servers with large databases. You can offload MySQL-related work to the remote MySQL server.
This feature does not automatically transfer your MySQL data. Instead, it configures the remote server to work with your MySQL setup. After you configure the remote server, you will need to manually transfer your existing MySQL data, but any new databases that you create will reside on the remote MySQL server.
To determine whether the
openssh-clients package is installed on your server, run the following command:
rpm -q openssh-clients
If the package is installed, the output will resemble the following:
openssh-clients package is not installed, the output will resemble the following example:
package openssh-clients is not installed.
To install the
openssh-clients package, run the following command as the
yum install openssh-clients
Before you set up a remote MySQL server, ensure that the remote server resolves your local server's IP address to its hostname. You also need to ensure that the local server resolves your remote server's IP address to its hostname.
To confirm this, run the
host command on the remote server through the command line.
root@server [~]# host 192.168.0.20 22.214.171.124.in-addr.arpa domain name pointer host.example.com.
This command resolves the hostname from the IP address.
If you have not set up a reverse DNS entry for the local server, edit
/etc/hosts on the remote MySQL server and add an entry for your local server, with the IP address and hostname. This will perform the hostname lookup manually, rather than through the DNS.
To set up a remote MySQL server, perform the following steps:
rootpassword for the
mysqluser to the
Select whether to log in as
root or with a specific username.
You must specify FQDNs in lowercase letters.
rootpassword in the Root Password text box.
If your server currently uses a remote MySQL server, and you wish to return to a local MySQL server, perform the following steps:
localhostin the Remote server address text box.